McStasMcXtrace / iFit

a simple library to analyze data (with McCode and Phonons/DFT hooks). :warning: this project has been moved to https://gitlab.com/soleil-data-treatment/soleil-software-projects/remote-desktop
http://ifit.mccode.org
Other
5 stars 5 forks source link

Models: Sqw: phonons: support Octopus #121

Closed farhi closed 6 years ago

farhi commented 6 years ago

Octopus seems also a good choice. Works in real space, but is currently limited to orthogonal lattices.

Get binaries at http://octopus-code.org/wiki/Manual:Installation#Binaries for older releases.

Ubuntu package: http://octopus-code.org/wiki/Octopus_5.0.1 (current, linked with MPI and OpenMP)

Test in ASE:

from ase.calculators.octopus import Octopus
from ase.lattice import bulk
system = bulk('Si', orthorhombic=True)
calc = Octopus(label='silicon', Spacing=0.25, KPointsGrid=[[4, 4, 4]], KPointsUseSymmetries=True, Output='dos + density + potential', OutputFormat='xcrysden', DosGamma=0.1)
system.set_calculator(calc)
system.get_potential_energy()
farhi commented 6 years ago

Octopus only supports pure orthorombic structures: fcc structure are not handled as well, (a,b,c) matrix is not diagonal.

**************************** FATAL ERROR *****************************
*** Fatal Error (description follows)
*--------------------------------------------------------------------
* Non-orthogonal cells support not implemented.
farhi commented 6 years ago

Octopus 6.0 compilation:

farhi commented 6 years ago

Octopus requires a lot of memory. With 24 cores and SrTiO3 -> 60 Gb

Currently functional when inserting ASE MR https://gitlab.com/ase/ase/merge_requests/596 and added 'Sampling=0.25' argument to calculator (in Angs, real space).

farhi commented 6 years ago

Done for the iFit side with commit https://github.com/McStasMcXtrace/iFit/commit/b560a3cae686d67e8a8380d41bc9b63b56ac1665

farhi commented 6 years ago

The Octopus failure:

Non-orthogonal cells support not implemented.

occurs when reducing the cell to its primitive in ifit.py:141

Otherwise, when inactivated, most fcc materials pass OK.

farhi commented 6 years ago

Omitting the find_primitive call does not solve. Octopus is limited. Works OK for SrTiO3, not Al, Si, ...

farhi commented 6 years ago

To work in parallel, Octopus should use 'octopus_mpi' else goes into 'serial' mode.

Octopus 7.1 compile (14.04):

farhi commented 6 years ago

Octopus 7.1: oct-help -s "" does not return anymore all available variables. This makes ASE calculator fail. Also, we have an error:

Octopus 7.0: OK, we have an error:

Octopus 6.0 seems the best choice to date (not for non-orthogonal of course) but else works OK:

farhi commented 6 years ago

Seems Octopus 7.1 is now OK when properly installed. And now supports non-orthogonal cells !!!

Excellent. Now testing on MgO:

farhi commented 6 years ago

Octopus seems to be rather unstable. We are now using version 7.1.

Infrastructure is OK on our side with commit https://github.com/McStasMcXtrace/iFit/commit/be71f935d2b1d6bfc834bd3a31a07c01cc0d19e2