Probe-Particle / PPSTM

Code simulating variousSTM techniques, especially for tilting tip (dependent on https://github.com/Probe-Particle/ppafm)l)
MIT License
8 stars 1 forks source link

Error code from CP2K input #2

Closed WangLulu97 closed 2 years ago

WangLulu97 commented 2 years ago

Hi,

I have used CP2K to run the examples of CuPc and 4N-Coeoene in the test file. And they both succeed to get the mapping from the GUI.py.

However, when I try my own example, It showed the error below.

We go to plotting Traceback (most recent call last): File "GUI.py", line 849, in running if self.plotImage(self.plotData, self.Hindx, self.Vindx, self.map): File "GUI.py", line 906, in plotImage self.plotGeom() File "GUI.py", line 864, in plotGeom atoms, tmp1, tmp2 = Bu.loadAtoms(os.path.join(self.paths['inputPath'], 'input_plot.xyz')); del tmp1, tmp2; File "/home/wongmw/Desktop/lulu/PPSTM-master/pyPPSTM/basUtils.py", line 16, in loadAtoms f = open(name,"r") FileNotFoundError: [Errno 2] No such file or directory: './tests/try81/input_plot.xyz' Aborted (core dumped)

Then I copied the geometry .xyz file as the input_plot.xyz, then this error not show anymore. However, another error showed.

We go to plotting skipped line : bigsurface

Traceback (most recent call last): File "GUI.py", line 849, in running if self.plotImage(self.plotData, self.Hindx, self.Vindx, self.map): File "GUI.py", line 906, in plotImage self.plotGeom() File "GUI.py", line 869, in plotGeom fc = '#%02x%02x%02x' % elements.ELEMENT_DICT[es[i]][7] #; print "DEBUG: fc", fc ; ##fc = '#FFFFFF' ## KeyError: 'bigsurface' Aborted (core dumped)

Is this because of the unit cell is too large(29*50) and not a square? How to fix this error?

Thank you!

Best regards, Lulu

ondrejkrejci commented 2 years ago

Easy and quick solve for it. Remove or empty the second line in the input_plot.xyz file.

Size does not matter. There is no repetition of the cell in the visualisation of the geometry, so orthogonality or non-orthogonality does not matter.

Generally the idea with input_plot.xyz is to put there only atoms you want to visualize (only molecule, or top-most layer) so you have to maybe create bigger cell before. Anyway, you can put it in and just see and then adjust the input_plot.xyz file later.

WangLulu97 commented 2 years ago

That helps a lot! Now the GUI can work without error!

Thank you very much!!!

ondrejkrejci commented 2 years ago

Great, closing this issue.