tof.utils.var_to_dict#

tof.utils.var_to_dict(var)[source]#

Convert a scipp Variable to a dictionary with ‘value’ and ‘unit’ keys.

Parameters:

var (Variable) – The variable to convert.

Return type:

dict