File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
chebai/preprocessing/datasets Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -435,13 +435,13 @@ def setup(self, **kwargs):
435435
436436 def _set_processed_data_props (self ):
437437
438- single_data_instance = torch .load (
438+ data_pt = torch .load (
439439 os .path .join (self .processed_dir , self .processed_file_names_dict ["data" ]),
440440 weights_only = False ,
441- )[ 0 ]
441+ )
442442
443- self ._num_of_labels = len (single_data_instance ["labels" ])
444- self ._feature_vector_size = len (single_data_instance ["features" ])
443+ self ._num_of_labels = len (data_pt [ 0 ] ["labels" ])
444+ self ._feature_vector_size = max ( len (d ["features" ]) for d in data_pt )
445445
446446 print (f"Number of labels for loaded data: { self ._num_of_labels } " )
447447 print (f"Feature vector size: { self ._feature_vector_size } " )
You can’t perform that action at this time.
0 commit comments