• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pyiron / structuretoolkit / 11224862873

07 Oct 2024 10:16PM UTC coverage: 82.876%. Remained the same
11224862873

Pull #264

github

web-flow
Merge a08d47eb8 into 119a584b2
Pull Request #264: [pre-commit.ci] pre-commit autoupdate

1539 of 1857 relevant lines covered (82.88%)

0.83 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

83.33
/structuretoolkit/common/pymatgen.py
1
from ase.atoms import Atoms
1✔
2

3

4
def ase_to_pymatgen(structure: Atoms):
1✔
5
    from pymatgen.io.ase import AseAtomsAdaptor
1✔
6

7
    adapter = AseAtomsAdaptor()
1✔
8
    return adapter.get_structure(atoms=structure)
1✔
9

10

11
def pymatgen_to_ase(structure) -> Atoms:
1✔
12
    from pymatgen.io.ase import AseAtomsAdaptor
1✔
13

14
    adapter = AseAtomsAdaptor()
1✔
15
    return adapter.get_atoms(structure=structure)
1✔
16

17

18
def pymatgen_read_from_file(*args, **kwargs) -> Atoms:
1✔
19
    from pymatgen.core import Structure
×
20

21
    return pymatgen_to_ase(structure=Structure.from_file(*args, **kwargs))
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc