gustaf.helpers.data.make_tracked_array#
- gustaf.helpers.data.make_tracked_array(array, dtype=None, copy=True)[source]#
Motivated by nice implementations of trimesh (see LICENSE.txt). https://github.com/mikedh/trimesh/blob/main/trimesh/caching.py.
Factory-like wrapper function for TrackedArray. If you want to use TrackedArray, it is recommended to use this function.
- Parameters:
array (array- like object) – To be turned into a TrackedArray
dtype (np.dtype) – Which dtype to use for the array
copy (bool) – Default is True. copy if True.
- Returns:
tracked – Contains input array data
- Return type: