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

Resurrect Insertion Workflow #787

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 0 additions & 1 deletion atomate/utils/database.py
Expand Up @@ -57,7 +57,6 @@ def __init__(
"compress" : Whether compression is used
"endpoint_url" : the url used to access the S3 store
maggma_store_prefix: when using maggma stores, you can set the prefix string.

**kwargs:
"""
if maggma_store_kwargs is None:
Expand Down
17 changes: 4 additions & 13 deletions atomate/vasp/firetasks/electrode_tasks.py
Expand Up @@ -98,21 +98,12 @@ def run_task(self, fw_spec):
chgcar = chgcar["aeccar0"] + chgcar["aeccar2"]

cia = ChargeInsertionAnalyzer(chgcar, **cia_kwargs)
cia.get_labels()
avg_chg_groups = list(cia.filter_and_group())

insert_sites = []
seent = set()

cia._extrema_df.sort_values(by=["avg_charge_den"], inplace=True)
for itr, li_site in cia._extrema_df.iterrows():
if len(insert_sites) >= attempt_insertions:
break
li_site = cia._extrema_df.iloc[itr]
lab = li_site["site_label"]
if lab not in seent:
insert_sites.append([li_site["a"], li_site["b"], li_site["c"]])
seent.add(lab)

for _, g in avg_chg_groups[:attempt_insertions]:
insert_sites.append(g[ 0])

logger.info(
f"Found {len(insert_sites)} insertion sites for task : {base_task_id}"
)
Expand Down
1 change: 1 addition & 0 deletions setup.py
Expand Up @@ -56,6 +56,7 @@
"moto>=4.1.14",
"pytest-cov>=4.1.0",
"pytest>=7.4.0",
"pymatgen-analysis-defects>=2022.8.18",
],
},
classifiers=[
Expand Down