01_setup_environment.sh 611 B

12345678910111213141516171819202122232425262728
  1. #!/usr/bin/bash
  2. cd ../envs
  3. conda_version=$(conda --version)
  4. # make a venv
  5. # check conda version as expected
  6. if [ "${conda_version}" != "conda 22.11.1" ]; then
  7. echo "conda version ${conda_version} is not correct, should be 22.11.1"
  8. exit 1
  9. else
  10. echo "${conda_version}"
  11. fi
  12. conda env create --file environment.yml
  13. eval "$(conda shell.bash hook)"
  14. conda activate junifer_release
  15. # check python version as expected
  16. if [ "$(python3 --version)" != "Python 3.10.8" ]; then
  17. echo "python version $(python3 --version) is not correct, should be 3.10.8"
  18. exit 1
  19. else
  20. echo "$(python3 --version)"
  21. fi
  22. cd ../code