Author Topic: Moment Tensor Potential Attribute  (Read 3426 times)

0 Members and 1 Guest are viewing this topic.

Offline krabidix

  • Regular QuantumATK user
  • **
  • Posts: 22
  • Country: fi
  • Reputation: 0
    • View Profile
Moment Tensor Potential Attribute
« on: March 12, 2023, 18:33 »
Hi, I was trying to run the tutorial on MTP  https://docs.quantumatk.com/tutorials/mtp_basic/mtp_basic.html. The tutorial works fine, although to plot the results the below commands:
Code
moment_tensor_potential_training=nlread('MTP_basics_results.hdf5',MomentTensorPotentialTraining)[0]
moment_tensor_potential_training._nlplotscatter(fit_index=1)
are not working. When using 2022.12 version following error showed up: Traceback (most recent call last):   File "/n/work00/software/quantumatk/2022.12/bin/../atkpython/bin/atkpython", line 8, in <module>     sys.exit(__run_atkpython())   File "zipdir/ATKExecutables/atkwrappers/__init__.py", line 879, in __run_atkpython   File "plot.py", line 2, in <module>     moment_tensor_potential_training._nlplotscatter(fit_index=1) AttributeError: 'MomentTensorPotentialTraining' object has no attribute '_nlplotscatter' When version 2022.03-sp1 used following error occurred:   File "zipdir/NL/IO/NLSaveUtilities.py", line 669, in nlread   File "zipdir/NL/IO/HDF5.py", line 568, in readHDF5   File "zipdir/NL/IO/HDF5.py", line 699, in readHDF5Group   File "zipdir/NL/IO/HDF5.py", line 638, in readHDF5GroupToSerializable   File "zipdir/NL/IO/HDF5.py", line 614, in readHDF5Dict   File "zipdir/NL/IO/HDF5.py", line 699, in readHDF5Group   File "zipdir/NL/IO/HDF5.py", line 659, in readHDF5GroupToSerializable   File "zipdir/NL/IO/Serializable.py", line 331, in _fromVersionedData   File "zipdir/NL/CommonConcepts/Calculator.py", line 67, in _createObject   File "zipdir/NL/QuantumATK/ScopeExecuter.py", line 244, in scope_execute NL.ComputerScienceUtilities.Exceptions.NLScopeExecutionError: __init__() got an unexpected keyword argument 'paw_grid_tolerance' Kindly, help me in resolving the problem.

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5575
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
Re: Moment Tensor Potential Attribute
« Reply #1 on: March 13, 2023, 21:58 »
Not sure why you got that error in 2022.12, it should work, but anyway it's a lot easier to just plot the data in NanoLab.

Note that the _ in the beginning of _nlplotscatter indicates that it's a private method and probably it will be removed in the future. We should remove the reference to it from the tutorial.

The error from the older version is expected, the PAW method was not fully implemented yet there.
« Last Edit: March 13, 2023, 21:59 by Anders Blom »

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5575
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
Re: Moment Tensor Potential Attribute
« Reply #2 on: March 13, 2023, 22:01 »
Oh I see why it doesn't work in 2022.12. The method name is actually _nlplotScatter (capital S).

Offline krabidix

  • Regular QuantumATK user
  • **
  • Posts: 22
  • Country: fi
  • Reputation: 0
    • View Profile
Re: Moment Tensor Potential Attribute
« Reply #3 on: March 14, 2023, 17:22 »
Hi,
Yes, it worked with the capital "S".

Thanks for the help.