<jupyter_start><jupyter_text>Test your pyiron installationThe goal of this notebooks is to evaluate your pyiron installation - to identify which components are working and which are might need some additional configuration.  Your operation system<jupyter_code>import sys
sys.platform  # ['linux', 'darwin', 'win32']<jupyter_output><empty_output><jupyter_text>Test pyiron Install pyiron from conda-forge: ```conda install -c conda-forge pyiron```<jupyter_code>! conda list pyiron<jupyter_output># packages in environment at /srv/conda/envs/notebook:
#
# Name                    Version                   Build  Channel
pyiron                    0.2.11             pyh9f0ad1d_0    conda-forge<jupyter_text>Install locationList where conda is installed:<jupyter_code>import pyiron
pyiron.__file__  # location where pyiron is installed<jupyter_output><empty_output><jupyter_text>Your .pyiron configuration Check pyiron configuration, if pyiron is not configured, configure it using: ```python>>> import pyiron>>> pyiron.install()```<jupyter_code>from pyiron.base.settings.generic import Settings
s = Settings()
s._configuration<jupyter_output><empty_output><jupyter_text>Your pyiron working directory pyiron restricts the users to execute notebooks only in the `project_paths`. We check if the current working directory is part of the `project_paths`.<jupyter_code>from pyiron import Project
pr = Project('.')<jupyter_output><empty_output><jupyter_text>NGLview for visualizing atomistic structuresNGLView is used for visualisation of atomistic structures. First we check if NGLview was installed using conda:<jupyter_code>! conda list nglview<jupyter_output># packages in environment at /srv/conda/envs/notebook:
#
# Name                    Version                   Build  Channel
nglview                   2.7.5              pyh5ca1d4c_0    conda-forge<jupyter_text>For jupyter notebooks nglview can be installed using: ```conda install -c conda-forge nglviewjupyter nbextension install nglview --py --sys-prefixjupyter nbextension enable nglview --py --sys-prefix```For jupyterlab the installation is slightly different: ```conda install -c conda-forge nodejs nglviewjupyter labextension install @jupyter-widgets/jupyterlab-manager --no-buildjupyter labextension install nglview-js-widgets```<jupyter_code>import nglview
nglview.demo()  # You should see a molecule which you can rotate in 3D<jupyter_output><empty_output><jupyter_text>Simulation codespyiron does not include any simulation codes, these have to be installed separatley:  Lammps We start with installing Lammps directly from Anaconda (the conda-forge channel provides the executables for Linux and Mac Os X): ```conda install -c conda-forge lammps ```For windows Lammps is available from the pyiron conda channel: ```conda install -c pyiron lammps ```<jupyter_code>! conda list lammps
from pyiron import Project
pr = Project('lammps')
pr.remove_jobs(recursive=True)
lmp = pr.create_job(pr.job_type.Lammps, 'static')
lmp.structure = pr.create_structure('Fe', 'bcc', 2.55)
lmp.potential = 'Fe_C_Hepburn_Ackland_eam'
lmp.run()  # The job static was saved and received the ID: 1<jupyter_output>The job static was saved and received the ID: 1<jupyter_text>Lammps interactive The conda-forge channel includes the Lammps executables as well as the Lammps library, unfortunatley this is not available for windows. Therefore for Windows we recommend installing pyiron using the Linux subsystem.<jupyter_code>from pyiron import Project
pr = Project('lammps')
pr.remove_jobs(recursive=True)
lmp = pr.create_job(pr.job_type.Lammps, 'interactive')
lmp.structure = pr.create_structure('Fe', 'bcc', 2.55)
lmp.potential = 'Fe_C_Hepburn_Ackland_eam'
lmp.server.run_mode.interactive = True
lmp.run()  # The job interactive was saved and received the ID: 1
print(lmp.output.energy_tot)  # [-6.38884508]
lmp.run()
print(lmp.output.energy_tot) # [-6.38884508 -6.38884508]
lmp.interactive_close()<jupyter_output>The job interactive was saved and received the ID: 1
[-6.38884508 -6.38884508 -6.38884508]
[-6.38884508 -6.38884508 -6.38884508 -6.38884508]<jupyter_text>Sphinx The Sphinx DFT code is developed at the MPIE and it can be installed for Linux using the conda-forge channel: ```conda install -c conda-forge sphinxdft```<jupyter_code>! conda list sphinxdft
from pyiron import Project
pr = Project('sphinx')
pr.remove_jobs(recursive=True)
lmp = pr.create_job(pr.job_type.Sphinx, 'static')
lmp.structure = pr.create_structure('Fe', 'bcc', 2.55)
lmp.run()  # The job static was saved and received the ID: 2<jupyter_output>The job static was saved and received the ID: 2
The files are already compressed!<jupyter_text>GPAW Besides Sphinx is GPAW a second opensource DFT code available for pyiron. For both Mac Os X and Linux GPAW is available from conda-forge available: ```conda install -c conda-forge ```<jupyter_code>! conda list gpaw
from pyiron import Project
pr = Project('gpaw')
pr.remove_jobs(recursive=True)
lmp = pr.create_job(pr.job_type.GpawJob, 'static')
lmp.structure = pr.create_structure('Fe', 'bcc', 2.55)
lmp.run()  # The job static was saved and received the ID: 3<jupyter_output>The job static was saved and received the ID: 3
{'fraction_non_alphanumeric': 0.08870502212815086, 'fraction_numerical': 0.024629593996536463, 'mean_word_length': 5.108108108108108, 'pattern_counts': {'":': 0, '<': 39, '<?xml version=': 0, '>': 45, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '11', 'dir': 'jupyter-structured-clean-dedup', 'id': '50973', 'license': 'BSD-3-Clause', 'n_tokens_mistral': 1776, 'n_tokens_neox': 1680, 'n_words': 529, 'path': 'notebooks/test_pyiron_installation.ipynb', 'repo_name': 'srmnitc/pyiron', 'size': '5197'}