File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11#! /bin/bash
2+ set -e # Exit on any error
3+
4+ echo " Starting notebook build process..."
5+
26# pyiron config
7+ echo " Setting up pyiron configuration..."
38python .github/ci_support/pyironconfig.py
49
510# import dataset
11+ echo " Importing datasets..."
612bash .github/ci_support/import_dataset.sh
713
8- # install papermill (already in environment.yml)
9- # conda install -c conda-forge papermill
10-
1114# register jupyter kernel
15+ echo " Registering Jupyter kernel..."
1216python -m ipykernel install --user --name python3 --display-name " Python 3"
1317
18+ # verify papermill is available
19+ echo " Verifying papermill installation..."
20+ python -c " import papermill; print('papermill version:', papermill.__version__)"
21+
1422# execute notebooks
23+ echo " Executing notebooks..."
1524current_dir=$( pwd)
1625i=0;
1726for f in $( find . -name " *.ipynb" | sort -n) ; do
27+ echo " Processing notebook: $f "
1828 cd $( dirname $f ) ;
1929 notebook=$( basename $f ) ;
20- papermill ${notebook} ${notebook% .* } -out.${notebook##* .} -k " python3" || i=$(( i+ 1 )) ;
30+ if papermill ${notebook} ${notebook% .* } -out.${notebook##* .} -k " python3" ; then
31+ echo " Successfully executed: $notebook "
32+ else
33+ echo " Failed to execute: $notebook "
34+ i=$(( i+ 1 )) ;
35+ fi
2136 cd $current_dir ;
2237done ;
2338
2439# push error to next level
2540if [ $i -gt 0 ]; then
41+ echo " Failed to execute $i notebook(s)"
2642 exit 1;
2743fi ;
44+
45+ echo " All notebooks executed successfully!"
Original file line number Diff line number Diff line change 11channels :
22 - conda-forge
33dependencies :
4+ - python>=3.11,<3.13
5+ - pip
6+ - numpy =1.26.4
7+ - ase =3.26.0
8+ - pymatgen =2025.6.14
9+ - pyiron_workflow =0.15.2
10+ - pyiron_lammps =0.4.6
11+ - pandas =2.3.1
12+ - lammps =2024.08.29=*_mpi*
13+ - pysqa =0.3.0
414 - jupyter-book
515 - ipykernel
616 - jupyter
717 - papermill
8-
18+ - pip :
19+ - pyiron-workflow-atomistics==0.0.2
20+ - pyiron-workflow-lammps==0.0.2
21+ - pyiron-snippets==0.2.0
Original file line number Diff line number Diff line change 11#! /bin/bash
2+ # Check if pyiron directory exists, if not create it
3+ if [ ! -d " pyiron" ]; then
4+ echo " Creating pyiron directory..."
5+ mkdir -p pyiron/calculation
6+ fi
7+
28cd pyiron
9+
10+ # Check if calculation directory and tar.gz files exist
11+ if [ ! -d " calculation" ] || [ ! " $( ls -A calculation/* .tar.gz 2> /dev/null) " ]; then
12+ echo " No calculation/*.tar.gz files found. Skipping dataset import."
13+ exit 0
14+ fi
15+
316for ds in $( ls calculation/* .tar.gz) ; do
417 cp ${ds} .
518 cp calculation/export.csv .
Original file line number Diff line number Diff line change 1717 with :
1818 auto-update-conda : true
1919 python-version : 3.12
20- environment-file : environment.yml
20+ environment-file : .github/ci_support/ environment.yml
2121 auto-activate-base : false
2222 - name : Tests
2323 shell : bash -l {0}
You can’t perform that action at this time.
0 commit comments