dleshchev / pytrx

toolbox for time resolved x-ray measurements
MIT License
2 stars 2 forks source link

Transform class structure #5

Open dleshchev opened 4 years ago

dleshchev commented 4 years ago

Transform init/prepare functions need to perform all the checks and assertions. Currently, the Transform class performs checks and assertions at the transform step, so the user knows that they did something wrong only after they try to do something with the molecule. We should make it such that invalid transforms cannot be created/added to the Molecule class.

darrenjhsu commented 4 years ago

I think it'll have to be in the prepare function as users can define Transformation without associating that with a Molecule.