from pyiron import Project
pr = Project('demonstration')
pr.remove_jobs(recursive=True) # to have a fresh start every time we execute the notebook
pr.path
'/Users/jan/pyiron/projects/2019/2019-12-11-lanl-tutorial/demonstration/'
structure = pr.create_structure('Al', 'fcc', 4.05) # compatible to the ASE structure object
structure
Al: [0. 0. 0.] Al: [2.025 2.025 0. ] Al: [2.02500000e+00 1.23995488e-16 2.02500000e+00] Al: [2.47990977e-16 2.02500000e+00 2.02500000e+00] pbc: [ True True True] cell: [[4.05000000e+00 0.00000000e+00 0.00000000e+00] [2.47990977e-16 4.05000000e+00 0.00000000e+00] [2.47990977e-16 2.47990977e-16 4.05000000e+00]]
structure.plot3d()
_ColormakerRegistry()
NGLWidget()
job_lammps = pr.create_job(pr.job_type.Lammps, 'job_lammps_1')
job_lammps.structure = structure
job_lammps.view_potentials()
Config | Filename | Model | Name | Species | |
---|---|---|---|---|---|
0 | [pair_style eam/fs \n, pair_coeff * * Al-Mg.eam.fs Al Mg\n] | [NISTiprpy/2009--Mendelev-M-I--Al-Mg--LAMMPS--ipr1/Al-Mg.eam.fs] | EAM | Al_Mg_Mendelev_eam | [Al, Mg] |
1 | [pair_style eam/alloy \n, pair_coeff * * Zope-Ti-Al-2003.eam.alloy Ti Al\n] | [NISTiprpy/2003--Zope-R-R--Ti-Al--LAMMPS--ipr1/Zope-Ti-Al-2003.eam.alloy] | EAM | Zope_Ti_Al_2003_eam | [Ti, Al] |
2 | [pair_style eam/alloy \n, pair_coeff * * NiAlH_jea.eam.alloy Ni Al H\n] | [NISTiprpy/1995--Angelo-J-E--Ni-Al-H--LAMMPS--ipr1/NiAlH_jea.eam.alloy] | EAM | Al_H_Ni_Angelo_eam | [Ni, Al, H] |
13 | [pair_style meam/c\n, pair_coeff * * MgAlZn.library.meam Mg Al MgAlZn.parameter.meam Mg Al Zn\n] | [NISTiprpy/2018--Dickel-D-E--Mg-Al-Zn--LAMMPS--ipr1/MgAlZn.parameter.meam, NISTiprpy/2018--Dickel-D-E--Mg-Al-Zn--LAMMPS--ipr1/MgAlZn.library.meam] | NISTiprpy | 2018--Dickel-D-E--Mg-Al-Zn--LAMMPS--ipr1 | [Mg, Al, Zn] |
34 | [pair_style eam/alloy\n, pair_coeff * * alpb-setfl.eam.alloy Al Pb\n] | [NISTiprpy/2000--Landa-A--Al-Pb--LAMMPS--ipr1/alpb-setfl.eam.alloy] | NISTiprpy | 2000--Landa-A--Al-Pb--LAMMPS--ipr1 | [Al, Pb] |
... | ... | ... | ... | ... | ... |
649 | [pair_style kim Sim_LAMMPS_MEAM_JelinekGrohHorstemeyer_2012_AlSiMgCuFe__SM_656517352485_000\n, pair_coeff * * Al Si Mg Cu Fe\n] | [] | OpenKIM | Sim_LAMMPS_MEAM_JelinekGrohHorstemeyer_2012_AlSiMgCuFe__SM_656517352485_000 | [Al, Si, Mg, Cu, Fe] |
659 | [pair_style kim Sim_LAMMPS_MEAM_PascuetFernandez_2015_AlU__SM_721930391003_000\n, pair_coeff * * Al U\n] | [] | OpenKIM | Sim_LAMMPS_MEAM_PascuetFernandez_2015_AlU__SM_721930391003_000 | [Al, U] |
660 | [pair_style kim Sim_LAMMPS_MEAM_PascuetFernandez_2015_Al__SM_811588957187_000\n, pair_coeff * * Al\n] | [] | OpenKIM | Sim_LAMMPS_MEAM_PascuetFernandez_2015_Al__SM_811588957187_000 | [Al] |
679 | [pair_style kim Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_AlO__SM_853967355976_000\n, pair_coeff * * Al O\n] | [] | OpenKIM | Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_AlO__SM_853967355976_000 | [Al, O] |
680 | [pair_style kim Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_Al__SM_404097633924_000\n, pair_coeff * * Al\n] | [] | OpenKIM | Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_Al__SM_404097633924_000 | [Al] |
93 rows × 5 columns
job_lammps.list_potentials()
['Al_Mg_Mendelev_eam', 'Zope_Ti_Al_2003_eam', 'Al_H_Ni_Angelo_eam', '2018--Dickel-D-E--Mg-Al-Zn--LAMMPS--ipr1', '2000--Landa-A--Al-Pb--LAMMPS--ipr1', '2004--Zhou-X-W--Al--LAMMPS--ipr2', '2003--Zope-R-R--Al--LAMMPS--ipr1', '2015--Mendelev-M-I--Al-Sm--LAMMPS--ipr1', '1997--Liu-X-Y--Al-Mg--LAMMPS--ipr1', '2004--Zhou-X-W--Al--LAMMPS--ipr1', '1995--Angelo-J-E--Ni-Al-H--LAMMPS--ipr1', '2015--Pascuet-M-I--Al-U--LAMMPS--ipr2', '1999--Liu-X-Y--Al-Cu--LAMMPS--ipr1', '2015--Pascuet-M-I--Al--LAMMPS--ipr1', '1998--Liu-X-Y--Al-Mg--LAMMPS--ipr1', '2015--Purja-Pun-G-P--Ni-Al-Co--LAMMPS--ipr2', '2009--Mendelev-M-I--Al-Mg--LAMMPS--ipr1', '2002--Mishin-Y--Ni-Al--LAMMPS--ipr1', '2012--Schopf-D--Al-Mn-Pd--LAMMPS--ipr1', '2000--Sturgeon-J-B--Al--LAMMPS--ipr1', '2003--Zope-R-R--Ti-Al--LAMMPS--ipr1', '2009--Zhakhovskii-V-V--Al--LAMMPS--ipr1', '2015--Purja-Pun-G-P--Ni-Al-Co--LAMMPS--ipr1', '1996--Farkas-D--Nb-Ti-Al--LAMMPS--ipr1', '2015--Purja-Pun-G-P--Al-Co--LAMMPS--ipr1', '2015--Purja-Pun-G-P--Al-Co--LAMMPS--ipr2', '2015--Pascuet-M-I--Al-U--LAMMPS--ipr1', '2010--Winey-J-M--Al--LAMMPS--ipr1', '2005--Mendelev-M-I--Al-Fe--LAMMPS--ipr1', '1999--Mishin-Y--Al--LAMMPS--ipr1', '2008--Mendelev-M-I--Al--LAMMPS--ipr1', '2009--Purja-Pun-G-P--Ni-Al--LAMMPS--ipr1', '2004--Mishin-Y--Ni-Al--LAMMPS--ipr1', '2004--Liu-X-Y--Al--LAMMPS--ipr1', '2016--Zhou-X-W--Al-Cu--LAMMPS--ipr1', '2017--Botu-V--Al--LAMMPS--ipr1', '2011--Apostol-F--Al-Cu--LAMMPS--ipr1', '2015--Botu-V--Al--LAMMPS--ipr1', '2015--Choudhary-K--Al--LAMMPS--ipr1', '2018--Zhou-X-W--Al-Cu-H--LAMMPS--ipr1', '2015--Kumar-A--Al-Ni-O--LAMMPS--ipr1', '2015--Kumar-A--Al-Ni--LAMMPS--ipr1', 'EAM_CubicNaturalSpline_ErcolessiAdams_1994_Al__MO_800509458712_002', 'EAM_Dynamo_AngeloMoodyBaskes_1995_NiAlH__MO_418978237058_005', 'EAM_Dynamo_CaiYe_1996_AlCu__MO_942551040047_005', 'EAM_Dynamo_ErcolessiAdams_1994_Al__MO_123629422045_005', 'EAM_Dynamo_FarkasJones_1996_NbTiAl__MO_042691367780_000', 'EAM_Dynamo_JacobsenNorskovPuska_1987_Al__MO_411692133366_000', 'EAM_Dynamo_LandaWynblattSiegel_2000_AlPb__MO_699137396381_005', 'EAM_Dynamo_LiuAdams_1998_AlMg__MO_019873715786_000', 'EAM_Dynamo_LiuErcolessiAdams_2004_Al__MO_051157671505_000', 'EAM_Dynamo_LiuLiuBorucki_1999_AlCu__MO_020851069572_000', 'EAM_Dynamo_LiuOhotnickyAdams_1997_AlMg__MO_559870613549_000', 'EAM_Dynamo_MendelevAstaRahman_2009_AlMg__MO_658278549784_005', 'EAM_Dynamo_MendelevFangYe_2015_AlSm__MO_338600200739_000', 'EAM_Dynamo_MendelevKramerBecker_2008_Al__MO_106969701023_005', 'EAM_Dynamo_MendelevSrolovitzAckland_2005_AlFe__MO_577453891941_005', 'EAM_Dynamo_MishinFarkasMehl_1999_Al__MO_651801486679_005', 'EAM_Dynamo_MishinMehlPapaconstantopoulos_2002_NiAl__MO_109933561507_005', 'EAM_Dynamo_Mishin_2004_NiAl__MO_101214310689_005', 'EAM_Dynamo_PunMishin_2009_NiAl__MO_751354403791_005', 'EAM_Dynamo_PunYamakovMishin_2013_AlCo__MO_678952612413_000', 'EAM_Dynamo_PunYamakovMishin_2013_NiAlCo__MO_826591359508_000', 'EAM_Dynamo_SchopfBrommerFrigan_2012_AlMnPd__MO_137572817842_000', 'EAM_Dynamo_SturgeonLaird_2000_Al__MO_120808805541_005', 'EAM_Dynamo_VailheFarkas_1997_CoAl__MO_284963179498_005', 'EAM_Dynamo_WineyKubotaGupta_2010_Al__MO_149316865608_005', 'EAM_Dynamo_Zhakhovsky_2009_Al__MO_519613893196_000', 'EAM_Dynamo_ZhouJohnsonWadley_2004_Al__MO_131650261510_005', 'EAM_Dynamo_ZhouWadleyJohnson_2001NISTretabulation_Al__MO_060567868558_000', 'EAM_Dynamo_ZhouWadleyJohnson_2001_Al__MO_049243498555_000', 'EAM_Dynamo_ZopeMishin_2003_Al__MO_664470114311_005', 'EAM_Dynamo_ZopeMishin_2003_TiAl__MO_117656786760_005', 'EAM_ErcolessiAdams_1994_Al__MO_324507536345_002', 'EAM_IMD_BrommerGaehler_2006A_AlNiCo__MO_122703700223_003', 'EAM_IMD_BrommerGaehler_2006B_AlNiCo__MO_128037485276_003', 'EAM_IMD_SchopfBrommerFrigan_2012_AlMnPd__MO_878712978062_003', 'EAM_QuinticClampedSpline_ErcolessiAdams_1994_Al__MO_450093727396_002', 'EAM_QuinticHermiteSpline_ErcolessiAdams_1994_Al__MO_781138671863_002', 'EMT_Asap_Standard_JacobsenStoltzeNorskov_1996_AlAgAuCuNiPdPt__MO_115316750986_001', 'EMT_Asap_Standard_JacobsenStoltzeNorskov_1996_Al__MO_623376124862_001', 'Morse_Shifted_GirifalcoWeizer_1959HighCutoff_Al__MO_140175748626_003', 'Morse_Shifted_GirifalcoWeizer_1959LowCutoff_Al__MO_411898953661_003', 'Morse_Shifted_GirifalcoWeizer_1959MedCutoff_Al__MO_279544746097_003', 'Sim_LAMMPS_ADP_ApostolMishin_2011_AlCu__SM_667696763561_000', 'Sim_LAMMPS_AGNI_BotuBatraChapman_2017_Al__SM_666183636896_000', 'Sim_LAMMPS_BOP_ZhouWardFoster_2016_AlCu__SM_566399258279_000', 'Sim_LAMMPS_MEAM_AlmyrasSangiovanniSarakinos_2019_NAlTi__SM_871795249052_000', 'Sim_LAMMPS_MEAM_JelinekGrohHorstemeyer_2012_AlSiMgCuFe__SM_656517352485_000', 'Sim_LAMMPS_MEAM_PascuetFernandez_2015_AlU__SM_721930391003_000', 'Sim_LAMMPS_MEAM_PascuetFernandez_2015_Al__SM_811588957187_000', 'Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_AlO__SM_853967355976_000', 'Sim_LAMMPS_SMTBQ_SallesPolitanoAmzallag_2016_Al__SM_404097633924_000']
job_lammps.potential = 'Al_Mg_Mendelev_eam'
job_lammps.input.control
Parameter | Value | Comment | |
---|---|---|---|
0 | units | metal | |
1 | dimension | 3 | |
2 | boundary | p p p | |
3 | atom_style | atomic | |
4 | read_data | structure.inp | |
5 | include | potential.inp | |
6 | fix___ensemble | all nve | |
7 | variable___dumptime | equal 100 | |
8 | dump___1 | all custom ${dumptime} dump.out id type xsu ysu zsu fx fy fz | |
9 | dump_modify___1 | sort id format line "%d %d %20.15g %20.15g %20.15g %20.15g %20.15g %20.15g" | |
10 | thermo_style | custom step temp pe etotal pxx pxy pxz pyy pyz pzz vol | |
11 | thermo_modify | format float %20.15g | |
12 | thermo | 100 | |
13 | run | 0 |
job_lammps.calc_md(temperature=500.0)
job_lammps.input.control
Parameter | Value | Comment | |
---|---|---|---|
0 | units | metal | |
1 | dimension | 3 | |
2 | boundary | p p p | |
3 | atom_style | atomic | |
4 | read_data | structure.inp | |
5 | include | potential.inp | |
6 | fix___ensemble | all nvt temp 500.0 500.0 0.1 | |
7 | variable___dumptime | equal 100 | |
8 | dump___1 | all custom ${dumptime} dump.out id type xsu ysu zsu fx fy fz | |
9 | dump_modify___1 | sort id format line "%d %d %20.15g %20.15g %20.15g %20.15g %20.15g %20.15g" | |
10 | thermo_style | custom step temp pe etotal pxx pxy pxz pyy pyz pzz vol | |
11 | thermo_modify | format float %20.15g | |
12 | thermo | 100 | |
13 | timestep | 0.001 | |
14 | velocity | all create 1000.0 69850 dist gaussian | |
15 | run | 1000 |
job_lammps.run()
The job job_lammps_1 was saved and received the ID: 1
pr.job_table()
id | status | chemicalformula | job | subjob | projectpath | project | timestart | timestop | totalcputime | computer | hamilton | hamversion | parentid | masterid | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 1 | finished | Al4 | job_lammps_1 | /job_lammps_1 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:45:41.117157 | 2019-12-10 16:45:42.227282 | 1.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | None |
job_lammps['output']
{'groups': ['generic', 'structure'], 'nodes': []}
job_lammps['output/generic']
{'groups': [], 'nodes': ['cells', 'energy_pot', 'energy_tot', 'forces', 'indices', 'positions', 'pressures', 'steps', 'temperature', 'time', 'unwrapped_positions', 'volume']}
job_lammps['output/generic/energy_tot']
array([-13.25465158, -13.26236025, -13.28059441, -13.32368955, -13.34831865, -13.29381065, -13.12583368, -13.04368461, -13.31347524, -13.40208388, -13.35984575])
import matplotlib.pyplot as plt
plt.plot(job_lammps['output/generic/energy_tot'])
[<matplotlib.lines.Line2D at 0x181d656160>]
pr['job_lammps_1/output/generic/energy_tot'] # access from the project level
array([-13.25465158, -13.26236025, -13.28059441, -13.32368955, -13.34831865, -13.29381065, -13.12583368, -13.04368461, -13.31347524, -13.40208388, -13.35984575])
job_lammps.executable.list_executables()
['2018.03.13', '2018.03.13_mpi', '2019.06.05', '2019.06.05_default', '2019.06.05_default_mpi', '2019.06.05_mpi']
job_lammps.server.list_queues()
job_lammps.server.view_queues()
job_lammps.server.cores
1
job_lammps.working_directory
'/Users/jan/pyiron/projects/2019/2019-12-11-lanl-tutorial/demonstration/job_lammps_1_hdf5/job_lammps_1'
import os
os.listdir(job_lammps.working_directory)
['job_lammps_1.tar.bz2']
job_lammps.decompress()
job_lammps['log.lammps'] # Add you own parser for additional output
['LAMMPS (12 Dec 2018)\n', 'units metal\n', 'dimension 3\n', 'boundary p p p\n', 'atom_style atomic\n', 'read_data structure.inp\n', ' orthogonal box = (0 0 0) to (4.05 4.05 4.05)\n', ' 1 by 1 by 1 MPI processor grid\n', ' reading atoms ...\n', ' 4 atoms\n', 'include potential.inp\n', 'pair_style eam/fs\n', 'pair_coeff * * Al-Mg.eam.fs Al Mg\n', 'fix ensemble all nvt temp 500.0 500.0 0.1\n', 'variable dumptime equal 100\n', 'dump 1 all custom ${dumptime} dump.out id type xsu ysu zsu fx fy fz\n', 'dump 1 all custom 100 dump.out id type xsu ysu zsu fx fy fz\n', 'dump_modify 1 sort id format line "%d %d %20.15g %20.15g %20.15g %20.15g %20.15g %20.15g"\n', 'thermo_style custom step temp pe etotal pxx pxy pxz pyy pyz pzz vol\n', 'thermo_modify format float %20.15g\n', 'thermo 100\n', 'timestep 0.001\n', 'velocity all create 1000.0 69850 dist gaussian\n', 'run 1000\n', 'Neighbor list info ...\n', ' update every 1 steps, delay 10 steps, check yes\n', ' max neighbors/atom: 2000, page size: 100000\n', ' master list distance cutoff = 9.5\n', ' ghost atom cutoff = 9.5\n', ' binsize = 4.75, bins = 1 1 1\n', ' 1 neighbor lists, perpetual/occasional/extra = 1 0 0\n', ' (1) pair eam/fs, perpetual\n', ' attributes: half, newton on\n', ' pair build: half/bin/atomonly/newton\n', ' stencil: half/bin/3d/newton\n', ' bin: standard\n', 'Per MPI rank memory allocation (min/avg/max) = 4.239 | 4.239 | 4.239 Mbytes\n', 'Step Temp PotEng TotEng Pxx Pxy Pxz Pyy Pyz Pzz Volume \n', ' 0 1000 -13.6424320128801 -13.2546515778801 5811.33462729831 -3854.45323119228 4356.39016846107 -621.038748887569 -3077.46758636693 5449.79641578524 66.430125 \n', ' 100 582.702306216562 -13.488320803082 -13.2623602493018 19272.5377390592 -390.766475669868 2757.48338360488 9211.21496855956 -1233.24087106805 20576.512738308 66.430125 \n', ' 200 229.499909382055 -13.3695899865347 -13.280594411842 25943.6408840172 4620.70985553081 -8607.5938021931 18185.1604277357 6698.31327794928 26575.2066462819 66.430125 \n', ' 300 381.825966704387 -13.4717541868408 -13.3236895473779 17597.3621704412 -2743.39182369787 1385.28892745806 13390.2979126485 -4754.40391555897 13684.2202362752 66.430125 \n', ' 400 336.258885851182 -13.4787132640351 -13.3483186470071 17870.8695466749 -2504.70721458531 8843.16879976338 9944.51929893634 -2623.19083524125 14930.8267228197 66.430125 \n', ' 500 287.501175962573 -13.4052979855416 -13.2938106544638 25259.7112976147 4724.84954980852 -8900.40051839842 13595.1592660193 6226.00430337782 24550.1515923481 66.430125 \n', ' 600 865.064860239937 -13.4612889069809 -13.1258336791739 24343.5962942228 -1305.18067771662 794.753669567708 13963.5152002367 -3413.9118731816 22673.6060830145 66.430125 \n', ' 700 1315.51010517474 -13.5538136878024 -13.0436846069708 16210.5856085173 -4189.01790374302 3662.53956623732 6468.86899554838 -3776.44149636939 19954.3359727284 66.430125 \n', ' 800 477.09117767078 -13.4984818611194 -13.3134752367076 15747.1976916114 -1146.62076630565 3304.31002208207 7208.19322475629 303.296003552599 20358.8715618705 66.430125 \n', ' 900 243.647362387788 -13.496565562211 -13.4020838820376 14738.1319281338 3751.97995779621 -2581.61806526022 9943.92404767703 3478.19973832365 14550.996643728 66.430125 \n', ' 1000 341.965008370376 -13.4924530913355 -13.3598457516349 15276.6481344145 -3114.46187560016 -3090.62935058231 10951.0986282076 -3697.02333680484 12857.9925810629 66.430125 \n', 'Loop time of 0.0341671 on 1 procs for 1000 steps with 4 atoms\n', '\n', 'Performance: 2528.752 ns/day, 0.009 hours/ns, 29267.963 timesteps/s\n', '86.7% CPU use with 1 MPI tasks x no OpenMP threads\n', '\n', 'MPI task timing breakdown:\n', 'Section | min time | avg time | max time |%varavg| %total\n', '---------------------------------------------------------------\n', 'Pair | 0.024069 | 0.024069 | 0.024069 | 0.0 | 70.44\n', 'Neigh | 0 | 0 | 0 | 0.0 | 0.00\n', 'Comm | 0.0072689 | 0.0072689 | 0.0072689 | 0.0 | 21.27\n', 'Output | 0.0011375 | 0.0011375 | 0.0011375 | 0.0 | 3.33\n', 'Modify | 0.00082731 | 0.00082731 | 0.00082731 | 0.0 | 2.42\n', 'Other | | 0.0008647 | | | 2.53\n', '\n', 'Nlocal: 4 ave 4 max 4 min\n', 'Histogram: 1 0 0 0 0 0 0 0 0 0\n', 'Nghost: 662 ave 662 max 662 min\n', 'Histogram: 1 0 0 0 0 0 0 0 0 0\n', 'Neighs: 448 ave 448 max 448 min\n', 'Histogram: 1 0 0 0 0 0 0 0 0 0\n', '\n', 'Total # of neighbors = 448\n', 'Ave neighs/atom = 112\n', 'Neighbor list builds = 0\n', 'Dangerous builds = 0\n', 'Total wall time: 0:00:00\n']
job_lammps_template = pr.create_job(pr.job_type.Lammps, 'job_lammps_template')
job_lammps_template.structure = structure
job_lammps_template.potential = 'Al_Mg_Mendelev_eam'
murn = job_lammps_template.create_job(pr.job_type.Murnaghan, 'murn')
murn.input
Parameter | Value | Comment | |
---|---|---|---|
0 | num_points | 11 | number of sample points |
1 | fit_type | polynomial | ['polynomial', 'birch', 'birchmurnaghan', 'murnaghan', 'pouriertarantola', 'vinet'] |
2 | fit_order | 3 | order of the fit polynom |
3 | vol_range | 0.1 | relative volume variation around volume defined by ref_ham |
murn.run()
The job murn was saved and received the ID: 2 The job strain_0_9 was saved and received the ID: 3 The job strain_0_92 was saved and received the ID: 4 The job strain_0_94 was saved and received the ID: 5 The job strain_0_96 was saved and received the ID: 6 The job strain_0_98 was saved and received the ID: 7 The job strain_1_0 was saved and received the ID: 8 The job strain_1_02 was saved and received the ID: 9 The job strain_1_04 was saved and received the ID: 10 The job strain_1_06 was saved and received the ID: 11 The job strain_1_08 was saved and received the ID: 12 The job strain_1_1 was saved and received the ID: 13 job_id: 3 finished job_id: 4 finished job_id: 5 finished job_id: 6 finished job_id: 7 finished job_id: 8 finished job_id: 9 finished job_id: 10 finished job_id: 11 finished job_id: 12 finished job_id: 13 finished
murn.plot()
murn['output']
{'groups': ['structure'], 'nodes': ['energy', 'equilibrium_b_prime', 'equilibrium_bulk_modulus', 'equilibrium_energy', 'equilibrium_volume', 'error', 'id', 'volume']}
plt.plot(murn['output/volume'], murn['output/energy'])
[<matplotlib.lines.Line2D at 0x181d228e10>]
pr.job_table()
id | status | chemicalformula | job | subjob | projectpath | project | timestart | timestop | totalcputime | computer | hamilton | hamversion | parentid | masterid | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 1 | finished | Al4 | job_lammps_1 | /job_lammps_1 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:45:41.117157 | 2019-12-10 16:45:42.227282 | 1.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | NaN |
1 | 2 | finished | Al4 | murn | /murn | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:45:44.863248 | 2019-12-10 16:46:06.707634 | 21.0 | pyiron@MacBook-Pro.local#1#11/11 | Murnaghan | 0.3.0 | None | NaN |
2 | 3 | finished | Al4 | strain_0_9 | /strain_0_9 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:46.793676 | 2019-12-10 16:45:47.391474 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
3 | 4 | finished | Al4 | strain_0_92 | /strain_0_92 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:48.755689 | 2019-12-10 16:45:49.608306 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
4 | 5 | finished | Al4 | strain_0_94 | /strain_0_94 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:50.988969 | 2019-12-10 16:45:51.454903 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
5 | 6 | finished | Al4 | strain_0_96 | /strain_0_96 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:52.878985 | 2019-12-10 16:45:53.487162 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
6 | 7 | finished | Al4 | strain_0_98 | /strain_0_98 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:54.925316 | 2019-12-10 16:45:55.340213 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
7 | 8 | finished | Al4 | strain_1_0 | /strain_1_0 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:56.551747 | 2019-12-10 16:45:56.977871 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
8 | 9 | finished | Al4 | strain_1_02 | /strain_1_02 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:58.426541 | 2019-12-10 16:45:58.915650 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
9 | 10 | finished | Al4 | strain_1_04 | /strain_1_04 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:00.400515 | 2019-12-10 16:46:01.180575 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
10 | 11 | finished | Al4 | strain_1_06 | /strain_1_06 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:02.470651 | 2019-12-10 16:46:02.930345 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
11 | 12 | finished | Al4 | strain_1_08 | /strain_1_08 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:04.100879 | 2019-12-10 16:46:04.556366 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
12 | 13 | finished | Al4 | strain_1_1 | /strain_1_1 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:05.672669 | 2019-12-10 16:46:06.074122 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
table = pr.create_job(pr.job_type.TableJob, 'table')
def filter_jobs(job):
return 'strain' in job.job_name
table.filter_function = filter_jobs
table.add.get_job_name
table.add.get_energy_tot
table.add.get_volume
True
job_lammps['output/generic/temperature'] # temperature
array([1000. , 582.70230622, 229.49990938, 381.8259667 , 336.25888585, 287.50117596, 865.06486024, 1315.51010517, 477.09117767, 243.64736239, 341.96500837])
def custom_function(job):
return job['output/generic/temperature'][0]
table.add['temperature'] = custom_function
table.run()
100%|██████████| 11/11 [00:00<00:00, 78.96it/s]
The job table was saved and received the ID: 14
table.get_dataframe()
job_name | job_id | energy_tot | volume | temperature | |
---|---|---|---|---|---|
0 | strain_0_9 | 3 | -13.428526 | 59.787112 | 0 |
1 | strain_0_92 | 4 | -13.519023 | 61.115715 | 0 |
2 | strain_0_94 | 5 | -13.580416 | 62.444317 | 0 |
3 | strain_0_96 | 6 | -13.618512 | 63.772920 | 0 |
4 | strain_0_98 | 7 | -13.638014 | 65.101522 | 0 |
5 | strain_1_0 | 8 | -13.642432 | 66.430125 | 0 |
6 | strain_1_02 | 9 | -13.634209 | 67.758727 | 0 |
7 | strain_1_04 | 10 | -13.614879 | 69.087330 | 0 |
8 | strain_1_06 | 11 | -13.585168 | 70.415932 | 0 |
9 | strain_1_08 | 12 | -13.545276 | 71.744535 | 0 |
10 | strain_1_1 | 13 | -13.495408 | 73.073137 | 0 |
plt.plot(table.get_dataframe()['volume'], table.get_dataframe()['energy_tot'])
[<matplotlib.lines.Line2D at 0x116e41710>]
job_lammps.server.run_mode
'modal'
job_lammps.server.run_mode.non_modal # run in background
False
job_interactive = pr.create_job(pr.job_type.Lammps, 'lammps_interactive')
job_interactive.structure = structure
job_interactive.potential = 'Al_Mg_Mendelev_eam'
job_interactive.server.run_mode.interactive = True
job_interactive.run()
The job lammps_interactive was saved and received the ID: 15
pr.job_table()
id | status | chemicalformula | job | subjob | projectpath | project | timestart | timestop | totalcputime | computer | hamilton | hamversion | parentid | masterid | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | 1 | finished | Al4 | job_lammps_1 | /job_lammps_1 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:45:41.117157 | 2019-12-10 16:45:42.227282 | 1.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | NaN |
1 | 2 | finished | Al4 | murn | /murn | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:45:44.863248 | 2019-12-10 16:46:06.707634 | 21.0 | pyiron@MacBook-Pro.local#1#11/11 | Murnaghan | 0.3.0 | None | NaN |
2 | 3 | finished | Al4 | strain_0_9 | /strain_0_9 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:46.793676 | 2019-12-10 16:45:47.391474 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
3 | 4 | finished | Al4 | strain_0_92 | /strain_0_92 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:48.755689 | 2019-12-10 16:45:49.608306 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
4 | 5 | finished | Al4 | strain_0_94 | /strain_0_94 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:50.988969 | 2019-12-10 16:45:51.454903 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
5 | 6 | finished | Al4 | strain_0_96 | /strain_0_96 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:52.878985 | 2019-12-10 16:45:53.487162 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
6 | 7 | finished | Al4 | strain_0_98 | /strain_0_98 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:54.925316 | 2019-12-10 16:45:55.340213 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
7 | 8 | finished | Al4 | strain_1_0 | /strain_1_0 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:56.551747 | 2019-12-10 16:45:56.977871 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
8 | 9 | finished | Al4 | strain_1_02 | /strain_1_02 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:45:58.426541 | 2019-12-10 16:45:58.915650 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
9 | 10 | finished | Al4 | strain_1_04 | /strain_1_04 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:00.400515 | 2019-12-10 16:46:01.180575 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
10 | 11 | finished | Al4 | strain_1_06 | /strain_1_06 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:02.470651 | 2019-12-10 16:46:02.930345 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
11 | 12 | finished | Al4 | strain_1_08 | /strain_1_08 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:04.100879 | 2019-12-10 16:46:04.556366 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
12 | 13 | finished | Al4 | strain_1_1 | /strain_1_1 | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/murn_hdf5/ | 2019-12-10 16:46:05.672669 | 2019-12-10 16:46:06.074122 | 0.0 | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | 2.0 |
13 | 14 | finished | None | table | /table | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:46:07.886290 | 2019-12-10 16:46:08.090257 | 0.0 | pyiron@MacBook-Pro.local#1 | TableJob | 0.1 | None | NaN |
14 | 15 | running | Al4 | lammps_interactive | /lammps_interactive | /Users/jan/pyiron/projects/ | 2019/2019-12-11-lanl-tutorial/demonstration/ | 2019-12-10 16:46:08.593883 | NaT | NaN | pyiron@MacBook-Pro.local#1 | Lammps | 0.1 | None | NaN |
job_interactive.output.forces
array([[[-1.21430643e-17, -8.67361738e-18, 1.38777878e-17], [ 4.02455846e-16, -1.73472348e-17, 3.46944695e-17], [ 4.57966998e-16, -3.12250226e-17, 1.04083409e-17], [-8.50881865e-16, 2.77555756e-17, 1.04083409e-17]]])
structure_displace = structure.copy()
structure_displace.positions
array([[0.00000000e+00, 0.00000000e+00, 0.00000000e+00], [2.02500000e+00, 2.02500000e+00, 0.00000000e+00], [2.02500000e+00, 1.23995488e-16, 2.02500000e+00], [2.47990977e-16, 2.02500000e+00, 2.02500000e+00]])
structure_displace.positions[0] = [0.1, 0.1, 0.1]
job_interactive.structure = structure_displace
job_interactive.run()
job_interactive.output.forces
array([[[-1.21430643e-17, -8.67361738e-18, 1.38777878e-17], [ 4.02455846e-16, -1.73472348e-17, 3.46944695e-17], [ 4.57966998e-16, -3.12250226e-17, 1.04083409e-17], [-8.50881865e-16, 2.77555756e-17, 1.04083409e-17]], [[-4.55030844e-01, -4.55030844e-01, -4.55030844e-01], [ 2.35038075e-01, 2.35038075e-01, -1.50453048e-02], [ 2.35038075e-01, -1.50453048e-02, 2.35038075e-01], [-1.50453048e-02, 2.35038075e-01, 2.35038075e-01]]])
job_interactive.interactive_close()
job_inter_mini = pr.create_job(pr.job_type.Lammps, 'lammps_int_template')
job_inter_mini.structure = structure_displace
job_inter_mini.potential = 'Al_Mg_Mendelev_eam'
job_inter_mini.server.run_mode.interactive = True
mini = pr.create_job(pr.job_type.ScipyMinimizer, 'mini')
mini.ref_job = job_inter_mini
mini.run()
The job mini was saved and received the ID: 16 The job lammps_int_template was saved and received the ID: 17
mini.ref_job.output.energy_tot
array([-13.57796067, -9.43921041, -13.62207552, -13.63559813, -13.54439975, -13.64239149, -13.64071651, -13.64243195, -13.64243082, -13.642432 , -13.64243181, -13.64243201])
plt.plot(mini.ref_job.output.energy_tot)
[<matplotlib.lines.Line2D at 0x116e62c18>]
pr.gui()
VBox(children=(HBox(children=(VBox(children=(Select(description='Groups:', options=('.', '..'), value='.'), Se…