Closed xiaochendu closed 2 months ago
Thanks for reporting! This is implemented in https://github.com/CederGroupHub/chgnet/commit/72f910860869e0595543ad6567503d61dce970ea
tests for disabled shuffling implemented in https://github.com/CederGroupHub/chgnet/commit/9e4bd5e6109c2bf70cc85cea0e5ec2e822c4e42b
Email (Optional)
dux@outlook.sg
Problem
Right now,
StructureData
,CIFData
,GraphData
, andStructureJsonData
shuffle the order of data in the constructor. For example,StructureData
doesrandom.shuffle(self.keys)
in the constructor body. I would like to have an option to disable the shuffling.Proposed Solution
I would like to add a keyword argument in the constructor,
shuffle: bool = True
to enable the user to disable shuffling. The resulting code in the constructor body can look like this, again for the example ofStructureData
:With the default value of
True
, it would not affect the default behavior.Alternatives
No response
Code of Conduct