Issue with Fireworks in nersc cori machine

23 views
Skip to first unread message

Janakiraman Balachandran

unread,
Dec 22, 2015, 1:31:09 PM12/22/15
to fireworkflows
Hi,

I'm trying to perform a very simple vasp simulation with Fireworks  in nersc#cori machine. However it throws me an error that I'm unable to resolve. The details are as follows

0. The fireworks, fireworks-vasp, pymatgen and custodian was installed in a local python virtual environment from sourcecode.

1. Structure:  Ba atom in a cubic cell of length 10Angstrom (input file POSCAR_Ba is attached)

2. Yaml File: The python code to create the yaml file is as follows (The output VAPS_Ba.yaml is attached)

from fireworks import Firework
from fireworks_vasp.tasks import WriteVaspInputTask, VaspCustodianTask, VaspAnalyzeTask
from pymatgen.core.structure import Structure

def create_fireworks(structure, keyVal, viset='MPVaspInputSet', params={}, handlers="all", vasp_cmd=["srun","-n","128","/usr/common/software/vasp/5.4.1/hsw/bin/vasp_std"]):
    name
= structure.formula
    wf_name
= name
    t1
= WriteVaspInputTask(structure=structure, vasp_input_set=viset, input_set_params=params)
    t2
= VaspCustodianTask(vasp_cmd=vasp_cmd, handlers=handlers)
    t3
= VaspAnalyzeTask()
    workflow
= Firework([t1, t2, t3], name=name)
   
return workflow

if __name__ == '__main__':
    inFileName
= 'POSCAR_Ba'
    crystalStruc
= Structure.from_file(inFileName)
    keyVal
= 'Ba-Atom'
    workflow
= create_fireworks(crystalStruc,keyVal)
    workflow
.to_file("VASP_Ba.yaml")


3. The yaml file is added to workflow with command
 lpad add VASP_Ba.yaml

4. When I run the fireworks with command qlaunch fireworks, I get the following error

Traceback (most recent call last):
 
File "/global/u1/r/rbala/pythonVirtualEnvs/pymatgenCori_Python2
_7_9_Nov2015/lib/python2.7/site-packages/FireWorks-1.2.1-py2.7.eg
g/fireworks/core/rocket.py"
, line 211, in run
    m_action
= t.run_task(my_spec)
 
File "/global/u1/r/rbala/pythonVirtualEnvs/pymatgenCori_Python2
_7_9_Nov2015/lib/python2.7/site-packages/fireworks_vasp-0.2-py2.7
.egg/fireworks_vasp/tasks.py"
, line 45, in run_task
    s
= Structure.from_dict(self["structure"])
 
File "/global/u1/r/rbala/pythonVirtualEnvs/pymatgenCori_Python2
_7_9_Nov2015/lib/python2.7/site-packages/pymatgen-3.2.7-py2.7-lin
ux-x86_64.egg/pymatgen/core/structure.py"
, line 1246, in from_dic
t
    lattice
= Lattice.from_dict(d["lattice"])
 
File "/global/u1/r/rbala/pythonVirtualEnvs/pymatgenCori_Python2
_7_9_Nov2015/lib/python2.7/site-packages/pymatgen-3.2.7-py2.7-lin
ux-x86_64.egg/pymatgen/core/structure.py"
, line 190, in __getitem
__
   
return self.sites[ind]
TypeError: list indices must be integers, not unicode


Thank you,

Best
Ram
POSCAR_Ba
VASP_Ba.yaml

Janakiraman Balachandran

unread,
Dec 22, 2015, 1:32:15 PM12/22/15
to fireworkflows
The command used to run was
qlaunch singleshot

Anubhav Jain

unread,
Dec 22, 2015, 1:51:23 PM12/22/15
to Janakiraman Balachandran, fireworkflows
Hi Janakiraman,

From your description of the error, it doesn't seem to be an error in the FireWorks code. The  error happens when calling Structure.from_dict(self["structure"]) inside your custom job code. This is unrelated to any FWS issue.

You should spend a little time trying to debug it. First, you can try printing out the value of self["structure"] to make sure that it is indeed a structure dictionary in the correct format, and that your code works independently of running it in FWS.

Best,
Anubhav

--
You received this message because you are subscribed to the Google Groups "fireworkflows" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fireworkflow...@googlegroups.com.
To post to this group, send email to firewo...@googlegroups.com.
Visit this group at https://groups.google.com/group/fireworkflows.
To view this discussion on the web visit https://groups.google.com/d/msgid/fireworkflows/78a9c1f5-b8ba-41da-8209-8ba79a91d1df%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Anubhav Jain

unread,
Dec 22, 2015, 1:53:38 PM12/22/15
to fireworkflows, jan...@umich.edu
Btw, there could be some error in fireworks-vasp, which is custom code to run VASP workflows and separate from FWS. That code is no longer maintained so there can certainly be a problem.

fireworks-vasp is written and maintained by Shyue Ping Ong, although he is not really treating it as an active project. I am no longer contributing to that code either as I am working on my own similar code.

Best,
Anubhav
To unsubscribe from this group and stop receiving emails from it, send an email to fireworkflows+unsubscribe@googlegroups.com.

To post to this group, send email to firewo...@googlegroups.com.
Visit this group at https://groups.google.com/group/fireworkflows.

Janakiraman Balachandran

unread,
Dec 22, 2015, 3:06:48 PM12/22/15
to fireworkflows, jan...@umich.edu
Thanks Anubhav,

Its not a fireworks error. I added the few lines of my custom code in the previous post and all it had to do was to create a yaml file which it creates without any issue. It could be in the fireworks-vasp code since output of the qlaunch is as follows

2015-12-22 10:26:19,327 INFO Hostname/IP lookup (this will take a few seconds)
2015-12-22 10:26:19,342 INFO Launching Rocket
2015-12-22 10:26:29,820 INFO RUNNING fw_id: 1 in directory: /global/project/projectdirs/m2113/rbala/Workflow/queue_testsPython
2015-12-22 10:26:29,837 INFO Task started: {{fireworks_vasp.tasks.WriteVaspInputTask}}.
2015-12-22 10:26:29,958 INFO Rocket finished

I will try to contact
Shyue Ping Ong.  Also is your vasp+fireworks code available to be tested?

Thank you,

Best
Ram
To unsubscribe from this group and stop receiving emails from it, send an email to fireworkflow...@googlegroups.com.

To post to this group, send email to firewo...@googlegroups.com.
Visit this group at https://groups.google.com/group/fireworkflows.

Anubhav Jain

unread,
Dec 22, 2015, 3:55:45 PM12/22/15
to Janakiraman Balachandran, fireworkflows
Hi Ram

The version I am developing is still under development. It is called "MatMethods". The code is available on Github (just search for it), but I would emphasize that it is very much a work in progress. I have not run a single calculation with it yet, and I would likely only provide support for collaborators (i.e., anyone who is actively contributing to the codebase and features) for some time.

Sorry that there is not a better set of examples for using fireworks with VASP at the moment. Materials Project uses the MPWorks code, but that code is getting too complicated and confusing even for me and I decided to start writing MatMethods.

Best,
Anubhav

Janakiraman Balachandran

unread,
Dec 22, 2015, 4:14:34 PM12/22/15
to fireworkflows, jan...@umich.edu
Thanks Anubhav, I found the MatMethods code. I think I will use MPWorks for the moment, since it seems matured enough to run calculations and it has a google groups of its own to resolve issues.

Best
Ram

Anubhav Jain

unread,
Dec 23, 2015, 6:02:06 PM12/23/15
to Janakiraman Balachandran, fireworkflows
Ok, good luck!

Note that my own effort will be focused entirely on MatMethods from now on and I am personally no longer supporting MPWorks (it continues to be the production software for Materials Project, so there are still about a half dozen developers, just not me). I hope that the Google Group for MPWorks allows you to make good progress.

Best,
Anubhav

Reply all
Reply to author
Forward
0 new messages