collection
¶
Module Contents¶
-
class
AutosaveStruct
(dataStruct, filename='', change_filename_if_exists=True)[source]¶ Structure that provides automated save of DataStructures
-
class
ListDataStruct
(compress_save=False)[source]¶ Bases:
optimeed.core.collection.DataStruct_Interface
-
_INFO_STR
= info¶
-
_DATA_STR
= data¶
-
_COMPRESS_SAVE_STR
= module_tree¶
-
save
(self, filename)[source]¶ Save data using json format. The data to be saved are automatically detected, see
obj_to_json()
-
_format_str_save
(self)[source]¶ Save data using json format. The data to be saved are automatically detected, see
obj_to_json()
-
static
load
(filename, theClass=None)[source]¶ Load the file filename.
- Parameters
filename – file to load
theClass – optional. Can be used to fix unpickling errors.
- Returns
self-like object
-
set_attribute_equation
(self, attribute_name, equation_str)[source]¶ Advanced method to set the value of attribute_name from equation_str
- Parameters
attribute_name – string (name of the attribute to set)
equation_str – formatted equation, check
applyEquation()
- Returns
-
get_list_attributes
(self, attributeName)[source]¶ Get the value of attributeName of all the data in the Collection
- Parameters
attributeName – string (name of the attribute to get)
- Returns
list
-
delete_points_at_indices
(self, indices)[source]¶ Delete several elements from the Collection
- Parameters
indices – list of indices to delete
-