Code Monkey home page Code Monkey logo

Comments (4)

mkhorton avatar mkhorton commented on June 30, 2024 2

Request the structure and use the Structure.to("POSCAR") method would be my advice.

The structure is the direct output from our calculations, whereas the cif has gone via CifWriter and (depending on the specific CIF requested and symmetry precision) may be in a different crystallographic setting.

from workshop.

755452800 avatar 755452800 commented on June 30, 2024

Thank you for your advice! According to your advice, the code was rewrite as:

with MPRester() as mpr:
    material = mpr.get_data('Ir')
    for item in material:
        if item['formation_energy_per_atom'] == 0.0:
            print(item['material_id'])    # result is 'mp-101'
            struc = mpr.get_structure_by_material_id(item['material_id'])
            struc.to(fmt='poscar', filename='POSCAR')

(I'm not sure how to request the structure from Materials Project, and after reading the api docs I think I may use get_structure_by_material_id )

And it's seems that the method get_structure_by_material_id still got the one single atom Ir structure, which is still different from the POSCAR file downloaded from the Materials Project (four Ir atoms structure) (see pic below)

To summary, the structure I got using MPRester() and get methods is not the same with the POSCAR file from the website (see pic below) for this specific case Ir (mp101). But I want to get the structure that was used by the MP teams, which is the four Ir atoms structure.
image

Any advice? Did I use the wrong way requested the wrong structure ? How could we get the POSCAR file (or the structure that could produce the same POSCAR) that your team used? Any clue would be appreciated!

from workshop.

shyamd avatar shyamd commented on June 30, 2024

I would ask this on matsci.org. This repo gets very little direct views outside of organizing and running the workshop.

from workshop.

755452800 avatar 755452800 commented on June 30, 2024

I would ask this on matsci.org. This repo gets very little direct views outside of organizing and running the workshop.

Thanks for your suggestion.

from workshop.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.