You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current input file format requires us to maintain our own code for reading/writing those files. As part of #899 we have decided to replace this file with TOML. #1008 will be the initial PR that will cover quite a bit of the serialization (writing to file) part of the process.
In order to cover this process in an appropriate manner, there will be two main issues that will keep track of progress.
@rprospero pointed out in TOML File Format Initial PR #1008 that we could probably improve the serialization of SpeciesAngle, SpeciesBond, SpeciesTorsion and SpeciesImproper by adding a serialize() method to the SpeciesIntra class. This method should handle serializing the parameters for each interaction there rather than doing it in each individual class. This can also be applied to deserializing said items.
@IVlaD17: It might be a good idea to reevaluate how SpeciesBond, SpeciesAngle, SpeciesTorsion, SpeciesImproper declare the Atoms involved in the interaction. Currently, they're stored as different members (i, j, k, l, etc.) but there might be some advantages in storing them in an array/vector/list or something.
@rprospero: The following system test files can be run while only parsing the Species, Master, and PairPotential blocks:
tests/input/benzene.txt
tests/input/py5-ntf2.txt
tests/input/water.txt
@rprospero thinks we should overload the toml::from and the toml::into methods to handle std::string_view and Vec3 at the very least but this should be investigated.
@rprospero suggested we should use std::transform calls wherever we are creating containers from TOML containers.
@rprospero suggested we sort out some sort of algorithm to replace the endless duplicated code (#1008)
Focus
The current input file format requires us to maintain our own code for reading/writing those files. As part of #899 we have decided to replace this file with TOML. #1008 will be the initial PR that will cover quite a bit of the serialization (writing to file) part of the process.
In order to cover this process in an appropriate manner, there will be two main issues that will keep track of progress.
Tasks
Notes
SpeciesAngle,SpeciesBond,SpeciesTorsionandSpeciesImproperby adding aserialize()method to theSpeciesIntraclass. This method should handle serializing the parameters for each interaction there rather than doing it in each individual class. This can also be applied to deserializing said items.SpeciesBond,SpeciesAngle,SpeciesTorsion,SpeciesImproperdeclare the Atoms involved in the interaction. Currently, they're stored as different members (i,j,k,l, etc.) but there might be some advantages in storing them in an array/vector/list or something.Species,Master, andPairPotentialblocks:tests/input/benzene.txttests/input/py5-ntf2.txttests/input/water.txttoml::fromand thetoml::intomethods to handlestd::string_viewandVec3at the very least but this should be investigated.std::transformcalls wherever we are creating containers from TOML containers.