Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add mpds app #2

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

add mpds app #2

wants to merge 5 commits into from

Conversation

minhsueh
Copy link
Collaborator

I have created a prototype of Materials Project Data Statistics.

I put the related files at mpships/src/mpships/mp_data_stats.

Please let me know if it is the right place, and any suggestions would be appreciated!

MPDS

@yang-ruoxi
Copy link
Member

@minhsueh thank you so much for your contribution, this looks great! And I can confirm it works in my dev environment.

I have 3 questions/suggestions:

  1. How are the numbers for each endpoint or element generated? They appear to be inside static json files, which is fine. But as time passes, the data counts in MP will change, so it would be helpful to have a python script one can run to update these numbers.

  2. Would it be possible to wrap the app in a class that subclass the html.Div? See the thermo_redox_csp or the materials_graph app as an example.

     class MPDSApp(html.Div):
          class ids: 
              # define layout components here 
          def __init__():
                super().__init__(children=[# your layout])
          # put your layout here 
     
          @callback(... ) # put all your callbacks here  
  1. Would it be possible for you to add some headers and texts below/above the periodic tables, to help people understand what the figures are for? I understood it because we had a meeting. But for our general user it may not be obvious from a first glance.
    Something along the line of "Elemental Distribution for MP structures" for the first figure, and more explanation for the second one.

@minhsueh
Copy link
Collaborator Author

minhsueh commented Oct 3, 2024

Hi @yang-ruoxi, thank you for the feedback and the guidelines for modulizing it. Those items are already on my to-do list! :)

  1. I retrieved the static files using the mp-api and will update the query and storage code to run periodically for distribution updates (possibly on a monthly schedule, which can be automated with GitHub Actions).

As for the timeline, I’m aiming to complete this over the weekend since my current schedule is quite busy.

@yang-ruoxi
Copy link
Member

I should thank you for making this contribution @minhsueh . Yes, having a script to run in GitHub Actions will be awesome.
No worries about the timeline. Please take your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants