TypeError: can't multiply sequence by non-int of type 'float'


on my WSL - Ubuntu I installed all openkim packages.

But the second testing program for ASE OpenKIM · Using KIM Models · Interatomic Potentials and Force Fields gives the error

python3 coh_en2.py
Traceback (most recent call last):
  File "/mnt/c/Users/milias/Documents/git-projects/open-collection/theoretical_chemistry/software/openkim/buildup_on_servers/jinr_ru/wsl_win10_pc7321b/cohesive_energy_fcc_aluminium/coh_en2.py", line 19, in <module>
    atoms = FaceCenteredCubic("Al", latticeconstant=a0)
  File "/home/milias/.local/lib/python3.10/site-packages/ase/lattice/bravais.py", line 79, in __call__
  File "/home/milias/.local/lib/python3.10/site-packages/ase/lattice/cubic.py", line 47, in make_crystal_basis
    self.crystal_basis = (self.latticeconstant * self.basis_factor
TypeError: can't multiply sequence by non-int of type 'float'

Hi Miroslav,

The query site is currently down, so the variable a0 ends up having something other than a floating point number in it. You can confirm by going to https://query.openkim.org, and seeing that none of the example queries work.

It may not be up until after the weekend, unfortunately. A workaround you can use to continue testing your installation is to find the lattice constant on the website:

You can find “Equilibrium zero-temperature lattice constant for fcc Al” and click “expand” to see the lattice constant. Then you can set a0=4.032082033157349 in your script manually instead of querying for it.

Sorry about this! We are working on making our query site more reliable.

Cheers, ilia

1 Like

Hi Miroslav,

The query site is back up.

1 Like