-
Notifications
You must be signed in to change notification settings - Fork 70
Update dev instructions #2286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
paskino
wants to merge
27
commits into
TomographicImaging:master
Choose a base branch
from
paskino:update_dev_instructions
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Update dev instructions #2286
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
998c25a
rempove py36 np1.15, GHA to test py39 np122
paskino 250cb03
update readme
paskino 42af679
updated clone and build command
paskino 3c1b642
update pip command to find IPP
paskino 482a640
fix recipe to find IPP
paskino d227e3c
Merge branch 'master' into update_dev_instructions
paskino d37a157
update pip command
paskino 758f315
add search CMake search path for WIN32 IPP
paskino 6a098d5
added instructions on developer guide
paskino e597d53
updated changelog
paskino 8b3f51b
Update README with shallow clone instructions
paskino c7e05ab
fix FindIPP
casperdcl 36179bc
Apply suggestion from @Neonbluestoplight
lauramurgatroyd f794772
Merge branch 'master' into update_dev_instructions
lauramurgatroyd 89504b1
Apply suggestions from code review
lauramurgatroyd 52e7808
Merge branch 'master' into update_dev_instructions
lauramurgatroyd 7e84ee4
Move instructions out of readme
lauramurgatroyd 222e9e6
update doc instructions and remove old scripts
lauramurgatroyd b8e7ed2
Fix formatting
lauramurgatroyd f56203b
Rearrange docs
lauramurgatroyd 9010a29
Fix titles
lauramurgatroyd 79d14b4
Merge branch 'master' into update_dev_instructions
lauramurgatroyd 66f0461
Apply suggestions from code review
lauramurgatroyd a0db0ab
fix syntax
casperdcl 5b8eeaf
Apply suggestions from code review
lauramurgatroyd b92a0b1
Merge remote-tracking branch 'upstream/master'
lauramurgatroyd 5a29f83
merge master
lauramurgatroyd File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,89 @@ | ||
| name: conda_and_docs_build | ||
|
|
||
| on: | ||
| release: | ||
| types: [published] | ||
| push: | ||
| branches: [ master ] | ||
| tags: | ||
| - '**' | ||
| pull_request: | ||
| branches: [ master ] | ||
|
|
||
| jobs: | ||
| conda_build: | ||
| runs-on: ubuntu-20.04 | ||
| steps: | ||
| - uses: actions/checkout@v3.1.0 | ||
| with: | ||
| fetch-depth: 0 | ||
| - name: conda-build | ||
| uses: paskino/conda-package-publish-action@v2.0.0 | ||
| with: | ||
| subDir: 'recipe' | ||
| channels: '-c conda-forge -c intel -c astra-toolbox/label/dev -c cvxgrp -c ccpi --override-channels' | ||
| convert_win: false | ||
| convert_osx: false | ||
| test_pyver: 3.9 | ||
| test_npver: 1.22 | ||
| - name: Upload artifact of the conda package. | ||
| uses: actions/upload-artifact@v3.1.1 | ||
| with: | ||
| name: cil-package | ||
| path: recipe/linux-64/cil* | ||
| docs_build: | ||
| needs: conda_build | ||
| runs-on: ubuntu-20.04 | ||
| steps: | ||
| - uses: actions/checkout@v3.1.0 | ||
| with: | ||
| fetch-depth: 0 | ||
| - name: change directory | ||
| run: | | ||
| ls | ||
| - name: Download artifact of the conda package. | ||
| uses: actions/download-artifact@v3.0.1 | ||
| with: | ||
| name: 'cil-package' | ||
| path: 'conda_package' | ||
| - uses: conda-incubator/setup-miniconda@v2 | ||
| with: | ||
| python-version: 3.7 | ||
| - uses: lauramurgatroyd/build-sphinx-action@v0.1.3 | ||
| with: | ||
| DOCS_PATH: 'docs' | ||
| CONDA_BUILD_ENV_FILEPATH: 'docs/docs_environment.yml' | ||
| ARTIFACT_NAME: 'DocumentationHTML' | ||
| PACKAGE_FOLDER_PATH: 'conda_package' | ||
| PACKAGE_NAME: 'cil' | ||
| PACKAGE_CONDA_CHANNELS: 'conda-forge -c intel -c astra-toolbox/label/dev -c cvxgrp -c ccpi' | ||
| BUILD_SUBDIR_NAME: 'nightly' | ||
| docs_publish: | ||
| needs: docs_build | ||
| runs-on: ubuntu-latest | ||
| if: github.ref == 'refs/heads/master' | ||
| steps: | ||
| - name: Download artifact of the html output. | ||
| uses: actions/download-artifact@v3.0.1 | ||
| with: | ||
| name: DocumentationHTML | ||
| path: docs/build | ||
| - name: Commit documentation changes | ||
| run: | | ||
| git clone https://github.com/TomographicImaging/CIL.git --branch gh-pages --single-branch gh-pages | ||
| cp -r docs/build/* gh-pages/ | ||
| cd gh-pages | ||
| touch .nojekyll | ||
| git config --local user.email "action@github.com" | ||
| git config --local user.name "GitHub Action" | ||
| git add . | ||
| git commit -m "Update documentation" -a || true | ||
| # The above command will fail if no changes were present, so we ignore | ||
| # that. | ||
| - name: Push changes | ||
| uses: ad-m/github-push-action@v0.6.0 | ||
| with: | ||
| branch: gh-pages | ||
| directory: gh-pages | ||
| github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -120,80 +120,7 @@ Jupyter Notebooks usage examples without any local installation are provided in | |
|
|
||
| ## Building CIL from source code | ||
|
|
||
| ### Getting the code | ||
|
|
||
| In case of development it is useful to be able to build the software directly. You should clone this repository as | ||
|
|
||
| ```sh | ||
| git clone --recurse-submodule git@github.com:TomographicImaging/CIL | ||
| ``` | ||
|
|
||
| The use of `--recurse-submodule` is necessary if the user wants the examples data to be fetched (they are needed by the unit tests). We have moved such data, previously hosted in this repo at `Wrappers/Python/data` to the [CIL-data](https://github.com/TomographicImaging/CIL-Data) repository and linked it to this one as submodule. If the data is not available it can be fetched in an already cloned repository as | ||
|
|
||
| ```sh | ||
| git submodule update --init --recursive | ||
| ``` | ||
|
|
||
| ### Building with `pip` | ||
|
|
||
| #### Install Dependencies | ||
|
|
||
| To create a conda environment with all the dependencies for building CIL run the following shell script: | ||
|
|
||
| ```sh | ||
| bash ./scripts/create_local_env_for_cil_development.sh | ||
| ``` | ||
|
|
||
| Or with the CIL build and test dependencies: | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should we remove the batch script file itself if we no longer recommend to use it?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have done this, please let me know if ok |
||
|
|
||
| ```sh | ||
| bash ./scripts/create_local_env_for_cil_development.sh -t | ||
| ``` | ||
|
|
||
| And then install CIL in to this environment using `pip`. | ||
|
|
||
| Alternatively, one can use the `scripts/requirements-test.yml` to create a conda environment with all the | ||
| appropriate dependencies, using the following command: | ||
|
|
||
| ```sh | ||
| conda env create -f ./scripts/requirements-test.yml | ||
| ``` | ||
| or, on windows: | ||
| ```sh | ||
| conda env create -f ./scripts/requirements-test-windows.yml | ||
|
lauramurgatroyd marked this conversation as resolved.
|
||
| ``` | ||
|
|
||
| #### Build CIL | ||
|
|
||
| A C++ compiler is required to build the source code. Let's suppose that the user is in the source directory, then the following commands should work: | ||
|
|
||
| ```sh | ||
| pip install --no-deps . | ||
| ``` | ||
|
|
||
| If not installing inside a conda environment, then the user might need to set the locations of optional libraries: | ||
|
|
||
| ```sh | ||
| pip install . -Ccmake.define.IPP_ROOT="<path_to_ipp>" -Ccmake.define.OpenMP_ROOT="<path_to_openmp>" | ||
| ``` | ||
|
|
||
| ### Building with Docker | ||
|
|
||
| In the repository root, simply update submodules and run `docker build`: | ||
|
|
||
| ```sh | ||
| git submodule update --init --recursive | ||
| docker build . -t ghcr.io/tomographicimaging/cil | ||
| ``` | ||
|
|
||
| ### Testing | ||
|
|
||
| One installed, CIL functionality can be tested using the following command: | ||
|
|
||
| ```sh | ||
| export TESTS_FORCE_GPU=1 # optional, makes GPU test failures noisy | ||
| python -m unittest discover -v ./Wrappers/Python/test | ||
| ``` | ||
| For instructions on how to build CIL from source code, please see our [Developers' Guide](https://tomographicimaging.github.io/CIL/nightly/developer_guide/) | ||
|
|
||
| ## Citing CIL | ||
|
|
||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also find IPP change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adds conda environment paths to find IPP command in cmake?