When loading data from presample package paths, data is collected on both matrix resources and parameter resources.
However, when appending extracted information to matrix_data, all data is passed, including parameter-metadata, which is superfluous.
On the other hand, when appending parameter-data to self.parameter_metadata, only parameter resource data is passed along with some other package level data (path, name (renamed to package_name), and indexer (renamed to sample_indexer)), but not all (id, seed, ncols).
There is no need for such asymmetry.
I recommend (untested for now):
1) Removing parameter_metadata from matrix_data, by adding self.matrix_data[-1].pop('parameter_metadata', None)right after appending the loaded section to matrix_data
2) Treating parameter data extraction like matrix_data extraction in load_data, and similarly deleting matrix_data from the returned data before appending to parameter_metadata.
3) Rename parameter_metadata to parameter_data
Steps 2 and 3 will have effects on other parts of the package
When loading data from presample package paths, data is collected on both matrix resources and parameter resources. However, when appending extracted information to
matrix_data
, all data is passed, includingparameter-metadata
, which is superfluous. On the other hand, when appendingparameter-data
to self.parameter_metadata, only parameter resource data is passed along with some other package level data (path, name (renamed to package_name), and indexer (renamed to sample_indexer)), but not all (id, seed, ncols).There is no need for such asymmetry.
I recommend (untested for now):
1) Removing parameter_metadata from matrix_data, by adding
self.matrix_data[-1].pop('parameter_metadata', None)
right after appending the loaded section to matrix_data2) Treating parameter data extraction like matrix_data extraction in
load_data
, and similarly deleting matrix_data from the returned data before appending toparameter_metadata
.3) Rename
parameter_metadata
toparameter_data
Steps 2 and 3 will have effects on other parts of the package