Skip to content

Commit

Permalink
🐛 FIX: Examples (aiidaplugins#19)
Browse files Browse the repository at this point in the history
Fixing the examples so that they correspond to the new potential setup.

Co-authored-by: Jonathan Chico <[email protected]>
  • Loading branch information
JPchico and Jonathan Chico authored Nov 1, 2020
1 parent d367350 commit 5592b68
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ potential_dict = {
'N N Ga': '1.0 0.001632 0.000 65.20700 2.82100 -0.518000 1.0 0.0 0.00000 0.00000 2.90 0.20 0.00000 0.00000',
'Ga N Ga': '1.0 0.007874 1.846 1.918000 0.75000 -0.301300 1.0 0.0 0.00000 0.00000 2.87 0.15 0.00000 0.00000'}
potential = DataFactory("lammps.potential")(
structure=structure, type=pair_style, data=potential_dict
type=pair_style, data=potential_dict
)
potential.attributes
```
Expand Down
3 changes: 1 addition & 2 deletions examples/launch_lammps_force_gan.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,8 @@

# setup nodes
inputs.structure = structure
# inputs.potential = Dict(dict=potential)
inputs.potential = EmpiricalPotential(
structure=structure, type="tersoff", data=tersoff_gan
type=potential["pair_style"], data=potential["data"]
)

# run calculation
Expand Down
2 changes: 1 addition & 1 deletion examples/launch_lammps_md_si.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
# setup nodes
inputs.structure = structure
inputs.potential = EmpiricalPotential(
structure=structure, type="tersoff", data=tersoff_si
type=potential["pair_style"], data=potential["data"]
)

inputs.parameters = Dict(dict=parameters_md)
Expand Down
3 changes: 1 addition & 2 deletions examples/launch_lammps_optimization_fe.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,8 @@

# setup nodes
inputs.structure = structure
# inputs.potential = Dict(dict=potential)
inputs.potential = EmpiricalPotential(
structure=structure, type="eam", data=eam_data
type=potential["pair_style"], data=potential["data"]
)

print(inputs.potential.get_potential_file())
Expand Down
3 changes: 1 addition & 2 deletions examples/launch_lammps_optimization_gan.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,8 @@

# setup nodes
inputs.structure = structure
# inputs.potential = Dict(dict=potential)
inputs.potential = EmpiricalPotential(
structure=structure, type="tersoff", data=tersoff_gan
type=potential["pair_style"], data=potential["data"]
)

inputs.parameters = Dict(dict=parameters_opt)
Expand Down
2 changes: 1 addition & 1 deletion examples/launch_lammps_optimization_lj.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
# setup nodes
inputs.structure = structure
inputs.potential = EmpiricalPotential(
structure=structure, type="lennard_jones", data={"1 1": "0.01029 3.4 2.5"}
type=potential["pair_style"], data=potential["data"]
)

inputs.parameters = Dict(dict=parameters_opt)
Expand Down

0 comments on commit 5592b68

Please sign in to comment.