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

Tidy lobster workflow #260

Merged
merged 7 commits into from
Mar 12, 2023
Merged

Tidy lobster workflow #260

merged 7 commits into from
Mar 12, 2023

Conversation

utf
Copy link
Member

@utf utf commented Mar 12, 2023

I refactored some parts of the lobster workflow to make it cleaner.

  1. Renamed additional_static... to preconverge_static... so that it is consistent throughout all parts of the code.
  2. Renamed bulk_relax to just relax because bulk is only really needed when you're doing defects/strains etc.
  3. Rewrote the delete wavecar functionality as it was wrapping delete_files in a job unnecessarily. There was no need to do the replace at this bit of the code as you were already in a job.
  4. Enable changing the lobster run settings.
  5. Changed the additional_fields option to be consistent to with how additional fields is used in the other schemas. This is mainly a way to store additional information in the schema. I added a new option store_lso_dos for specific storing of the DOS as it seemed that this was the only additional file supported.
  6. Moved some code around in the schema file. Doing this I realised the code would break if the following condition failed:
    icohplist_path.exists() and cohpcar_path.exists() and charge_path.exists() as struct and describe wouldn't be defined.
  7. Some other minor docstring and code optimisations.

@JaGeo please could you have a look over and let me know if this is all ok?

@codecov
Copy link

codecov bot commented Mar 12, 2023

Codecov Report

Merging #260 (bf5dbf1) into main (4668fc3) will increase coverage by 0.51%.
The diff coverage is 82.31%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #260      +/-   ##
==========================================
+ Coverage   76.38%   76.90%   +0.51%     
==========================================
  Files          62       62              
  Lines        5379     5317      -62     
  Branches      773      755      -18     
==========================================
- Hits         4109     4089      -20     
+ Misses       1053     1020      -33     
+ Partials      217      208       -9     
Impacted Files Coverage Δ
src/atomate2/lobster/schemas.py 86.26% <78.21%> (+7.44%) ⬆️
src/atomate2/vasp/jobs/lobster.py 93.54% <84.61%> (+8.76%) ⬆️
src/atomate2/vasp/flows/lobster.py 94.44% <93.10%> (+15.41%) ⬆️
src/atomate2/lobster/jobs.py 94.11% <100.00%> (-0.33%) ⬇️
src/atomate2/lobster/run.py 55.55% <100.00%> (ø)

@utf
Copy link
Member Author

utf commented Mar 12, 2023

Ok, I made that change. I also renamed delete_all_wavecars to delete_wavecars for brevity.

@utf utf merged commit 69f4743 into main Mar 12, 2023
@janosh janosh deleted the lobster_tidying branch July 20, 2023 18:14
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