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

write jobflow tutorial #18

Merged
merged 19 commits into from
Jul 1, 2024
Merged

write jobflow tutorial #18

merged 19 commits into from
Jul 1, 2024

Conversation

QuantumChemist
Copy link
Collaborator

@QuantumChemist QuantumChemist commented Jun 17, 2024

I started with writing the jobflow tutorial

To-Dos:

  • revise text
  • put hyperlinks for all external packages that are mentioned like atomate2, custodian etc.

@JaGeo
Copy link
Collaborator

JaGeo commented Jun 17, 2024

@QuantumChemist Thank you so much!!

@QuantumChemist QuantumChemist changed the title [WIP] write jobflow tutorial write jobflow tutorial Jun 29, 2024
jobflow.ipynb Outdated
"outputs": [],
"source": [
"graph = to_mermaid(qe_flow, show_flow_boxes=True)\n",
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could someone who has QE set up, run these lines please?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can simply install it via conda. I have done this as well

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh cool, didn't know this 😁

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have a wide range of opensource codes available on conda-forge. You can find the full list here - at least the packages I maintain https://github.com/jan-janssen/conda-forge-contribution . If you are interested to add any other code I am happy to help.

@QuantumChemist
Copy link
Collaborator Author

I have finished the tutorial @JaGeo 😀

@JaGeo
Copy link
Collaborator

JaGeo commented Jun 29, 2024

@QuantumChemist I will check it out next week and will contribute as well!

@QuantumChemist
Copy link
Collaborator Author

I can't get QE to take the right pseudopot path. I will try again on another day ^^

@jan-janssen
Copy link
Member

Somehow my notifications were not up to date and I missed this. To find the pseudo potentials in the Github Continuous integration environment we set the following environment variable

export ESPRESSO_PSEUDO=$(pwd)/espresso/pseudo

Unfortunately the Github Action is not executed in the home directory, so the ESPRESSO_PSEUDO environment variable is used to specify the right path. Does jobflow use the environment variables from the external environment? Or is it necessary to set the environment variables explicitly?

@QuantumChemist
Copy link
Collaborator Author

Somehow my notifications were not up to date and I missed this. To find the pseudo potentials in the Github Continuous integration environment we set the following environment variable

export ESPRESSO_PSEUDO=$(pwd)/espresso/pseudo

Unfortunately the Github Action is not executed in the home directory, so the ESPRESSO_PSEUDO environment variable is used to specify the right path. Does jobflow use the environment variables from the external environment? Or is it necessary to set the environment variables explicitly?

Oohh I might try to specify the QE pp env variable like this next time! And I have to check how jobflow handles env variables in general.

@@ -22,7 +22,7 @@ datecode 220603
<element type="qes:outputType" name="output" minOccurs="0" />
<element type="qes:cpstatusType" name="STATUS" minOccurs="0"/>
<element type="qes:cptimestepsType" name="TIMESTEPS" minOccurs="0"/>
<element type="qes:statusType" name="exit_status" minOccurs="0" maxOccurs="1"/>
<element type="qes:statusType" name="status" minOccurs="0" maxOccurs="1"/>
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to adjust quite a few things with the xml format. Maybe something is different in the xmlschema version I use?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ofc now some tests fail... 🙄

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed the modifications to the parser in #19 and everything works fine. In addition, when I execute the notebook here locally I also get an xml related Reason: Unexpected child with tag 'fcp' at position 18. error, but the notebook execution does not fail. It seems like jobflow is converting the error to a warning and continues executing the remaining cells of the notebook. You can test it with Binder

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you test it locally with a different quantum espresso version? In the repository we currently use qe=7.2.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's the qe version as I used qe 6.7. Thank you for looking into this and fixing this issue 😄
I will merge your commits back into mine to have passing tests in my repo.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also realized that I overlooked the environment.yml file 🙈

@@ -150,8 +150,8 @@ datecode 220603
<element type="double" name="press_conv_thr" default="5e-1"/>
<element type="qes:lowhighType" name="verbosity" default="low"/>
<element type="positiveInteger" name="print_every"/>
<element type="boolean" name="fcp"/>
<element type="boolean" name="rism"/>
<!-- <element type="boolean" name="fcp" default="false"/>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing this line causes the pyiron tests to fail with:

Reason: Unexpected child with tag 'fcp' at position 18.

To me there seems to be an issue with the input files.

Copy link
Member

@jan-janssen jan-janssen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@JaGeo
Copy link
Collaborator

JaGeo commented Jul 1, 2024

@jan-janssen I will give it another read this week. Alternatively, we can merge this for now and I make a potential new pull request with improvements.

(ToDo for tomorrow)

@jan-janssen
Copy link
Member

@jan-janssen I will give it another read this week. Alternatively, we can merge this for now and I make a potential new pull request with improvements.

(ToDo for tomorrow)

Both is fine for me, I still was not able to reach @mbercx so far ...

in https://github.com/materialdigital/ADIS2023/blob/f33ebb84921d1cd907b60d3c66494eddfd2512a4/adis_tools/parsers.py#L15
for `XMLSchema` we have
`Expected type 'str | bytes | Path | IO[str] | IO[bytes] | XMLResource | Element | ElementTree | list[str | bytes | Path | IO[str] | IO[bytes] | XMLResource | Element | ElementTree]', got 'Traversable' instead`
@QuantumChemist
Copy link
Collaborator Author

@jan-janssen I will give it another read this week. Alternatively, we can merge this for now and I make a potential new pull request with improvements.

(ToDo for tomorrow)

I'd say the second option is easier. Then we don't have to merge/fork back and forth 😆

@JaGeo
Copy link
Collaborator

JaGeo commented Jul 1, 2024

Then, I will merge!

@JaGeo JaGeo merged commit 9905f45 into materialdigital:main Jul 1, 2024
4 checks passed
@JaGeo
Copy link
Collaborator

JaGeo commented Jul 1, 2024

@QuantumChemist just saw that there is still old text on the structure in here. We use MSONatoms instead of Structure. I will correct it

@QuantumChemist
Copy link
Collaborator Author

@QuantumChemist just saw that there is still old text on the structure in here. We use MSONatoms instead of Structure. I will correct it

Oh that makes sense. I was a bit confused about it, but somehow didn't further think about it 🙈

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.

3 participants