Tool (desktop application) for allowing the examination of Time of Flight (ToF) inelastic neutron data, from single crystal, direct geometry experiments.
Create and activate a virtual environment with Pixi. Prerequisites: Pixi installation e.g. for Linux:
curl -fsSL https://pixi.sh/install.sh | sh
Download the repository. Setup/Update the environment
pixi installEnter the environment
pixi shell
The Shiver environment is activated and the application is ready to use.
*Alternatively, stable versions of shiver are provided as conda package: Shiver Package Installation Instructions
Start the application
shiverTo start shiver from within the Mantid workbench, start
mantidworkbench then run the following in the IPython console
from shiver import Shiver
s=Shiver()
s.show()There are pixi tasks for starting the GUI. The tasks have the same names as the deployment environments
pixi run start_guistarts the shiver guipixi run start_mantidstarts mantidworkbench with the shiver gui available
Development/Deployment
Any change to pyproject.toml, e.g. new dependencies, requires updating the pixi.lock file and including it in the commit.
pixi.lock
Testing
To run all tests for shiver
pytest
#or
python -m pytestTo run pre-commit manually
pre-commit run --all-filesOr
To set the pre-commit hook before each git commit
pre-commit installAutomated Jobs
The repository runs automated tests on branches during Pull-Requests and on the main ones: next, main and qa. The jobs are described in .github/workflows/actions.yml:
-
Testing suite. It includes pytest, pre-commit and code coverage tools -
Conda build. A new conda package is built and uploaded in a github temporary location (servers). -
Conda Verify. The new conda package is installed in a test environment and checked, e.g. import shiver. -
Publish. The new conda package is uploaded in Anaconda Neutrons registry. -
Trigger deploy. Given that the two above jobs were successful, deployment is triggered. (this is temporarily in comments)
Documentation Updates
When adding new views, presenters and methods, please navigate to docs/source/repo_doc.rst. Add the new feature under the appropriate section following the given template:
.. automodule:: path.to.new.module
:members:Once complete, rebuild the documentation:
cd SHIVER/docs/
make clean
make html
https://shiver.readthedocs.io/en/latest/