[Wannier] kslice Matplotlib griddata error
Vahid Askarpour
vh261281 at dal.ca
Thu Nov 9 13:00:35 CET 2023
Dear Wannier90 community,
I am using Wannier90/3.1.0 to plot a slice of my data. The postw90.x creates the necessary python code but I get the following error when running this python script:
File "/gpfs/scratch/vaskarpo/Mn3Ge_hex/kslice/wannier90-kslice-curv_x+fermi_lines.py", line 64, in <module>
valint = ml.griddata(points_x,points_y, val_log, xint,yint)
AttributeError: module 'matplotlib.mlab' has no attribute ‘griddata'
Does any one know how to remedy this? I tried replacing the ml.griddata with scipy.interpolate.griddata but then I get the following error:
File "/gpfs/scratch/vaskarpo/Mn3Ge_hex/kslice/wannier90-kslice-curv_x+fermi_lines.py", line 64, in <module>
valint = interpolate.griddata(points_x,points_y, val_log, grid_x, grid_y)
File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx512/Core/scipy-stack/2023b/lib/python3.10/site-packages/scipy/interpolate/_ndgriddata.py", line 253, in griddata
if ndim == 1 and method in ('nearest', 'linear', 'cubic'):
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
I am attaching the python script.
Any suggestion is appreciated.
Thanks,
Vahid
-------------- next part --------------
A non-text attachment was scrubbed...
Name: script.py
Type: text/x-python-script
Size: 2631 bytes
Desc: script.py
URL: <http://lists.quantum-espresso.org/pipermail/wannier/attachments/20231109/d79fa021/attachment.bin>
More information about the Wannier
mailing list