Skip to content

Change Input File Format #1010

@IVlaD17

Description

@IVlaD17

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

  • @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)

Metadata

Metadata

Assignees

Labels

Priority: MediumIndicates an Epic with medium priorityScope: I/ORelated to file handling and I/O

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions