Error of ferroelectric workflow generation


I am a new user of atomate, I am trying to generate polarization workflows with the following codes:

import numpy as np
from atomate.vasp.workflows.base.ferroelectric import get_wf_ferroelectric

from pymatgen import MPRester, Structure
with MPRester() as mp:
s = mp.get_structure_by_material_id(‘mp-19845’) # TiPbO3

pert_coords =
for site in s.sites:
if site.specie.symbol == ‘Ti’:
pert_coords.append( site.coords + np.array( [0., 0., 0.25])) # add displacement on Ti
pert_coords.append( site.coords)
pert_struct = Structure( s.lattice, s.species, pert_coords, coords_are_cartesian=True)

wf = get_wf_ferroelectric(s, pert_struct, vasp_cmd=“>>vasp_cmd<<”, db_file=‘>>db_file<<’,

from fireworks.core.launchpad import LaunchPad
lpad_file_path = ‘path_to_my_launchpad.yaml’

lp = LaunchPad().from_file(lpad_file_path)

However, I got the following error:
RuntimeError: Invalid keyword argument specified for: <class 'atomate.vasp.firetasks.parse_outputs.PolarizationToDb'>. You specified: name. Allowed values are: ['db_file'].

After I set add_analysis_task=True in function get_wf_ferroelectric, the error is gone, but interpolation workflows are FIZZLED and first two workflows COMPLETED (TiPbO3-_polar_polarization, TiPbO3-_nonpolar_polarization).

My question is why add_analysis_task=True get me that error? Am I doing something wrong?

Many thanks!

I got an update from my post last time. So far, by reinstall and configure atomate from the scratch in another anaconda environment, the get_wf_ferroelectric function is worked with setting
add_analysis_task=True, but interpolation workflows are still FIZZLED with the first two workflows (polar and nonpolar ones) completed.

Hi Yichen,

Are you able to provide more information on the FIZZLED Fireworks? Do you know which FireTask is failing and what the error message is?


Hi Alex,

I am really sorry for the delayed reply.

The error message in FW_job.error file is:

Traceback (most recent call last):
File “/home/yig319/.conda/envs/atomate1/lib/python3.7/site-packages/fireworks/core/”, line 262, in run
m_action = t.run_task(my_spec)
File “/home/yig319/.conda/envs/atomate1/lib/python3.7/site-packages/atomate/vasp/firetasks/”, line 132, in run_task
structure = GetInterpolatedPOSCAR.interpolate_poscar(self, fw_spec)
File “/home/yig319/.conda/envs/atomate1/lib/python3.7/site-packages/atomate/vasp/firetasks/”, line 270, in interpolate_poscar
s1 = Structure.from_file(os.path.join(interpolate_folder, “CONTCAR_0”))
File “/home/yig319/.conda/envs/atomate1/lib/python3.7/site-packages/pymatgen/core/”, line 2326, in from_file
with zopen(filename, “rt”) as f:
File “/home/yig319/.conda/envs/atomate1/lib/python3.7/site-packages/monty/”, line 43, in zopen
return, *args, **kwargs)
FileNotFoundError: [Errno 2] No such file or directory: ‘interpolate/CONTCAR_0’

I am not sure when CONTCAR_0 should be created, and it seems like FireTask should create or pass CONTCAR_O file to the “interpolate” folder for interpolation workflow, but it didn’t.

From the source codes of atomate, I found that the function get_wf_ferroelectric is using a Class LcalcpolFW, which will use parameter start and end to locate output structures (CONTCAR) of previous calculations. And my friend told me the LcalcpolFW uses PassCalcLoc in atomate.common.glue_tasks to keeps track of the location of the current calculation to pass on to the next firework, which needs to use that information.


I ran into the same error and found the solution on this forum page: Ferroelectric job error - #4 by Bikash. Bikash explained that the error went away when he set {‘gzip_output’: False} in inside /atomate/vasp/firetasks at line no. 127. It has something to do with the Firetask not being able to find/pass the file when it is zipped.