Skip to content

Commit cafb069

Browse files
committed
Merge #48
2 parents fa1fca6 + eef7eac commit cafb069

File tree

127 files changed

+10180
-3509
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

127 files changed

+10180
-3509
lines changed

.github/workflows/build_docs.yml

Lines changed: 27 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,38 @@
1-
name: Deploy Sphinx documentation to Pages
1+
name: deploy
22

33
on:
44
push:
55
branches: # branch to trigger deployment
66
- main
77

8+
# This job installs dependencies, build the book, and pushes it to `gh-pages`
89
jobs:
9-
pages:
10-
runs-on: ubuntu-20.04
10+
build-and-deploy-book:
11+
runs-on: ${{ matrix.os }}
12+
strategy:
13+
matrix:
14+
os: [ubuntu-latest]
15+
python-version: [3.8]
1116
steps:
12-
- id: deployment
13-
uses: sphinx-notes/pages@v3
17+
- uses: actions/checkout@v2
18+
19+
# Install dependencies
20+
- name: Set up Python ${{ matrix.python-version }}
21+
uses: actions/setup-python@v1
1422
with:
15-
publish: false
16-
- uses: peaceiris/actions-gh-pages@v3
23+
python-version: ${{ matrix.python-version }}
24+
- name: Install dependencies
25+
run: |
26+
pip install jupyter-book
27+
28+
# Build the book
29+
- name: Build the book
30+
run: |
31+
jupyter-book build docs/
32+
33+
# Deploy the book's HTML to gh-pages branch
34+
- name: GitHub Pages action
35+
uses: peaceiris/[email protected]
1736
with:
1837
github_token: ${{ secrets.GITHUB_TOKEN }}
19-
publish_dir: ${{ steps.deployment.outputs.artifact }}
38+
publish_dir: docs/_build/html

.gitignore

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,17 @@ venv/
9393
# written by setuptools_scm
9494
**/_version.py
9595

96+
# WANDB
97+
/wandb/
9698

9799

98100
########
99101
#project specific
100102
#dataset, weights, old logos, requirements
101103
/napari_cellseg3d/code_models/models/dataset/
102104
/napari_cellseg3d/code_models/models/saved_weights/
103-
/docs/res/logo/old_logo/
105+
/docs/source/logo/old_logo/
106+
/docs/source/code/_autosummary/
104107
/reqs/
105108
/loss_plots/
106109
/wandb/
@@ -111,7 +114,7 @@ notebooks/full_plot.html
111114
notebooks/instance_test.ipynb
112115
*.prof
113116
/docs/_build/
114-
/docs/source/code/_autosummary/
117+
/docs/source/code/_autosummary/*.rst
115118

116119
#include test data
117120
!napari_cellseg3d/_tests/res/test.tif
@@ -121,3 +124,8 @@ notebooks/instance_test.ipynb
121124
!napari_cellseg3d/_tests/res/wnet_test/lab/*.tif
122125
!napari_cellseg3d/_tests/res/wnet_test/vol/*.tif
123126
cov.syspath.txt
127+
128+
#include docs images
129+
!docs/source/logo/*
130+
!docs/source/images/*
131+
napari_cellseg3d/dev_scripts/wandb

.pre-commit-config.yaml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@ repos:
77
- id: trailing-whitespace
88
- id: check-yaml
99
- id: check-added-large-files
10+
args: [--maxkb=5000]
1011
- id: check-toml
1112
# - repo: https://github.com/pycqa/isort
1213
# rev: 5.12.0
1314
# hooks:
1415
# - id: isort
1516
# args: ["--profile", "black", --line-length=79]
16-
- repo: https://github.com/charliermarsh/ruff-pre-commit
17-
# Ruff version.
18-
rev: 'v0.0.262'
19-
hooks:
20-
- id: ruff
21-
args: [ --fix, --exit-non-zero-on-fix ]
17+
# - repo: https://github.com/charliermarsh/ruff-pre-commit
18+
# # Ruff version.
19+
# rev: 'v0.0.262'
20+
# hooks:
21+
# - id: ruff
22+
# args: [ --fix, --exit-non-zero-on-fix ]
2223
- repo: https://github.com/psf/black
2324
rev: 23.3.0
2425
hooks:

conda/napari_cellseg3d_m1.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ dependencies:
1616
- tifffile>=2022.2.9
1717
- imageio-ffmpeg>=0.4.5
1818
- torch>=1.11
19-
- monai[nibabel,einops]>=0.9.0
19+
- monai>=0.9.0
2020
- tqdm
2121
- nibabel
2222
- scikit-image

docs/Makefile

Lines changed: 0 additions & 196 deletions
This file was deleted.

docs/TODO.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
[//]: # (
2+
TODO:
3+
- [ ] Add a way to get the current version of the library
4+
- [x] Update all modules
5+
- [x] Better WNet tutorial
6+
- [x] Setup GH Actions
7+
- [ ] Add a bibliography
8+
)

docs/_config.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Book settings
2+
# Learn more at https://jupyterbook.org/customize/config.html
3+
4+
title: napari-cellseg3d Documentation
5+
author: Cyril Achard, Maxime Vidal, Timokleia Kousi, Mackenzie Mathis | Mathis Laboratory
6+
logo: source/logo/logo_alpha.png
7+
8+
# Force re-execution of notebooks on each build.
9+
# See https://jupyterbook.org/content/execute.html
10+
execute:
11+
execute_notebooks: force
12+
13+
# Define the name of the latex output file for PDF builds
14+
latex:
15+
latex_documents:
16+
targetname: book.tex
17+
18+
# Add a bibtex file so that we can create citations
19+
bibtex_bibfiles:
20+
- references.bib
21+
22+
# Information about where the book exists on the web
23+
repository:
24+
url: https://github.com/AdaptiveMotorControlLab/CellSeg3d # Online location of your book
25+
path_to_book: docs # Optional path to your book, relative to the repository root
26+
branch: main # Which branch of the repository should be used when creating links (optional)
27+
28+
# Add GitHub buttons to your book
29+
# See https://jupyterbook.org/customize/config.html#add-a-link-to-your-repository
30+
html:
31+
use_issues_button: true
32+
use_repository_button: true
33+
34+
# Add auto-generated API docs
35+
sphinx:
36+
extra_extensions:
37+
- 'sphinx.ext.napoleon'
38+
- 'sphinx.ext.autodoc'
39+
- 'sphinx.ext.autosummary'
40+
- 'sphinx.ext.viewcode'
41+
- 'sphinx.ext.autosectionlabel'
42+
config:
43+
add_module_names: False
44+
autosectionlabel_prefix_document: True
45+
autosummary_generate: True
46+
autoclass_content: "both"
47+
# templates_path: ['_templates']
48+
exclude_patterns:
49+
- '_build'
50+
- '_templates'
51+
# - 'napari_cellseg3d/__pycache__'

0 commit comments

Comments
 (0)