Skip to content

Commit

Permalink
Merge pull request #638 from oist/develop-main
Browse files Browse the repository at this point in the history
Release v1.2.1
  • Loading branch information
ReiHashimoto authored Apr 15, 2024
2 parents 5f0f529 + 2cf890d commit ccc71a0
Show file tree
Hide file tree
Showing 63 changed files with 1,663 additions and 528 deletions.
39 changes: 26 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,38 +28,51 @@ build_frontend:
docker-compose -f docker-compose.test.yml build build_studio_frontend
docker-compose -f docker-compose.test.yml run build_studio_frontend

.PHONY: format
format:
black studio *.py
isort studio *.py
flake8 studio *.py

.PHONY: docs
docs:
rm -rf docs/_build/
poetry install --with doc --no-root
# sphinx-apidoc -f -o ./docs/_build/modules ./studio
sphinx-autobuild -b html docs docs/_build --port 8001

.PHONY: dockerhub
dockerhub:
docker build --rm -t oistncu/optinist:latest . --platform=linux/amd64
docker push oistncu/optinist:latest

.PHONY: local_build
local_build:
rm -rf dist
cd frontend && yarn install --ignore-scripts && yarn build
poetry build

.PHONY: upload_testpypi
upload_testpypi:
.PHONY: push_testpypi
push_testpypi:
poetry publish -r testpypi

.PHONY: install_testpypi
install_testpypi:
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ optinist
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ optinist==${ver}
pip show optinist

.PHONY: build_test_docker
build_test_docker:
docker build --no-cache -t optinist-release-test:${ver} -f studio/config/docker/Dockerfile .

.PHONY: run_test_docker
run_test_docker:
docker run -it \
-v ${volume}:/app/studio_data \
--env OPTINIST_DIR="/app/studio_data" \
--name optinist-release-test -d -p 8000:8000 optinist-release-test:${ver} \
poetry run python main.py --host 0.0.0.0 --port 8000

.PHONY: push_pypi
push_pypi:
poetry publish

.PHONY: format
format:
black studio *.py
isort studio *.py
flake8 studio *.py
.PHONY: push_dockerhub
push_dockerhub:
docker build --rm -t oistncu/optinist:latest -f studio/config/docker/Dockerfile . --platform=linux/amd64
docker push oistncu/optinist:latest
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
project = "OptiNiSt"
copyright = f"{datetime.today().year}, OIST"
author = ""
release = "1.2.0"
release = "1.2.1"

# -- readthedocs -------------------------------------------------------------
on_rtd = os.environ.get("READTHEDOCS", None) == "True"
Expand Down
10 changes: 2 additions & 8 deletions docs/gui/workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -224,14 +224,8 @@ You may not want to modify your original data folder, or you may want to make yo
We implement loading C libraries for reading NIKON and Olympus file.
The libraries are available only on Linux and Windows (Not on MacOS).
And due to the license issue, we cannot distribute their library in this project.
You need to get the libraries by yourself and add them to the path. To do that,
- get the C library files from the manufacturer's support.
- use OptiNiSt by :ref:`developer mode <each-platforms-for-developer>`.
- set environment value ``MICROSCOPES_LIBRARY_DIR`` in ``studio/config/.env`` to your library path.
- put the libraries into ``MICROSCOPES_LIBRARY_DIR/dll/{nikon | olympus}/{linux | windows}/``
- If you use Linux, open ``studio/app/optinist/wrappers/optinist/conda/microscope.yaml`` and uncomment the ``- gcc=12`` line.
- If you use Linux, use OptiNiSt by :ref:`developer mode <each-platforms-for-developer>`.
- open ``studio/app/optinist/wrappers/optinist/conda/microscope.yaml`` and uncomment the ``- gcc=12`` line.
```

<p align="center">
Expand Down
6 changes: 3 additions & 3 deletions frontend/build/asset-manifest.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{
"files": {
"main.css": "/static/css/main.341bf264.css",
"main.js": "/static/js/main.2a95acf7.js",
"main.js": "/static/js/main.0f19d410.js",
"static/js/47.145ba9bc.chunk.js": "/static/js/47.145ba9bc.chunk.js",
"static/media/logo.png": "/static/media/logo.e44efe3246aecc6d6219.png",
"index.html": "/index.html",
"main.341bf264.css.map": "/static/css/main.341bf264.css.map",
"main.2a95acf7.js.map": "/static/js/main.2a95acf7.js.map",
"main.0f19d410.js.map": "/static/js/main.0f19d410.js.map",
"47.145ba9bc.chunk.js.map": "/static/js/47.145ba9bc.chunk.js.map"
},
"entrypoints": [
"static/css/main.341bf264.css",
"static/js/main.2a95acf7.js"
"static/js/main.0f19d410.js"
]
}
2 changes: 1 addition & 1 deletion frontend/build/index.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/static/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="manifest" href="/static/manifest.json"/><title>OptiNiSt</title><script defer="defer" src="/static/js/main.2a95acf7.js"></script><link href="/static/css/main.341bf264.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/static/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Web site created using create-react-app"/><link rel="manifest" href="/static/manifest.json"/><title>OptiNiSt</title><script defer="defer" src="/static/js/main.0f19d410.js"></script><link href="/static/css/main.341bf264.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "optinist",
"version": "1.2.0",
"version": "1.2.1",
"engines": {
"node": ">=20.0.0"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const ErrorIcon = memo(function ErrorIcon({ message }: ErrorIconProps) {
color="error"
padding={2}
marginBottom={0}
whiteSpace="pre-wrap"
>
{message}
</Typography>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/Workspace/FlowChart/FlowChart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ const FlowChart = memo(function FlowChart(props: UseRunPipelineReturnType) {
horizontal: "left",
}}
>
<div style={{ margin: 8 }}>
<div style={{ margin: 8, whiteSpace: "pre-wrap"}}>
<FormHelperText error={true}>
{messageError.message}
</FormHelperText>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,6 @@ const ImagePlotChart = memo(function ImagePlotChart({
}

const onChartClick = (event: PlotMouseEvent) => {
if (![MERGE_ROI, DELETE_ROI].includes(action)) return
// use as unknown because original PlotDatum does not have z property
const point: PlotDatum = event.points[0] as unknown as PlotDatum
if (point.curveNumber >= 1 && outputKey === "cell_roi") {
Expand Down
9 changes: 7 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[tool.poetry]
name = "optinist"
description = "Calcium Imaging Pipeline Tool"
version = "1.2.0"
version = "1.2.1"
license = "GPL-3.0"
authors = ["OIST <[email protected]>"]
readme = "README.md"
Expand Down Expand Up @@ -36,7 +36,12 @@ include = [
"sample_data/input/*",
"sample_data/output/**/*.yaml",
]
exclude = ["studio/tests/*", "studio/test_data/*", "conda.env.*"]
exclude = [
"studio/tests/*",
"studio/test_data/*",
"conda.env.*",
"studio/app/optinist/microscopes/libs.zip",
]

[tool.poetry.dependencies]
python = "^3.8.1"
Expand Down
126 changes: 63 additions & 63 deletions sample_data/output/tutorial2/experiment.yaml
Original file line number Diff line number Diff line change
@@ -1,91 +1,95 @@
finished_at: '2023-11-22 17:20:57'
workspace_id: '1'
unique_id: tutorial2
name: Tutorial2
started_at: '2024-04-11 16:47:34'
finished_at: '2024-04-11 16:49:14'
success: success
hasNWB: true
function:
caiman_cnmf_z6a16cmiwl:
finished_at: '2023-11-22 17:20:48'
hasNWB: true
message: caiman_cnmf success
name: caiman_cnmf
outputPaths:
all_roi:
max_index: null
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_z6a16cmiwl/all_roi.json
type: roi
cell_roi:
max_index: null
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_z6a16cmiwl/cell_roi.json
type: roi
fluorescence:
max_index: 6
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_z6a16cmiwl/fluorescence
type: timeseries
images:
max_index: 1
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_z6a16cmiwl/images.json
type: images
non_cell_roi:
max_index: null
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_z6a16cmiwl/non_cell_roi.json
type: roi
started_at: null
success: success
unique_id: caiman_cnmf_z6a16cmiwl
caiman_mc_p4f6nsi9bh:
finished_at: '2023-11-22 17:20:50'
unique_id: caiman_mc_p4f6nsi9bh
name: caiman_mc
success: success
hasNWB: true
message: caiman_mc success
name: caiman_mc
outputPaths:
mc_images:
max_index: 2000
path: /tmp/studio/output/1/tutorial2/caiman_mc_p4f6nsi9bh/mc_images.json
path: /tmp/studio/output/1/tutorial2/caiman_mc_p4f6nsi9bh/tiff/mc_images/mc_images.tif
type: images
max_index: 2000
meanImg:
max_index: 1
path: /tmp/studio/output/1/tutorial2/caiman_mc_p4f6nsi9bh/meanImg.json
type: images
max_index: 1
rois:
max_index: null
path: /tmp/studio/output/1/tutorial2/caiman_mc_p4f6nsi9bh/rois.json
type: roi
started_at: null
success: success
unique_id: caiman_mc_p4f6nsi9bh
max_index: null
started_at: '2024-04-11 16:47:49'
finished_at: '2024-04-11 16:48:34'
input_0:
finished_at: '2023-11-22 17:20:42'
unique_id: input_0
name: sample_mouse2p_image.tiff
success: success
hasNWB: false
message: null
name: sample_mouse2p_image.tiff
outputPaths: null
started_at: '2023-11-22 17:20:42'
success: success
unique_id: input_0
started_at: '2024-04-11 16:47:34'
finished_at: '2024-04-11 16:47:34'
pca_xi0d87mbrk:
finished_at: '2023-11-22 17:20:57'
unique_id: pca_xi0d87mbrk
name: pca
success: success
hasNWB: true
message: pca success
name: pca
outputPaths:
contribution:
explained_variance:
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/evr.json
type: bar
max_index: null
projectedNd:
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/projectedNd.json
type: scatter
max_index: null
contribution:
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/contribution.json
type: bar
cumsum_contribution:
max_index: null
cumsum_contribution:
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/cumsum_contribution.json
type: bar
explained_variance:
max_index: null
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/evr.json
type: bar
projectedNd:
max_index: null
path: /tmp/studio/output/1/tutorial2/pca_xi0d87mbrk/projectedNd.json
type: scatter
started_at: '2023-11-22 17:20:53'
started_at: '2024-04-11 16:49:09'
finished_at: '2024-04-11 16:49:14'
caiman_cnmf_qcjcwx9uq7:
unique_id: caiman_cnmf_qcjcwx9uq7
name: caiman_cnmf
success: success
unique_id: pca_xi0d87mbrk
hasNWB: true
name: Tutorial2
hasNWB: true
message: caiman_cnmf success
outputPaths:
images:
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_qcjcwx9uq7/images.json
type: images
max_index: 1
fluorescence:
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_qcjcwx9uq7/fluorescence
type: timeseries
max_index: 4
all_roi:
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_qcjcwx9uq7/all_roi.json
type: roi
max_index: null
cell_roi:
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_qcjcwx9uq7/cell_roi.json
type: roi
max_index: null
non_cell_roi:
path: /tmp/studio/output/1/tutorial2/caiman_cnmf_qcjcwx9uq7/non_cell_roi.json
type: roi
max_index: null
started_at: '2024-04-11 16:48:36'
finished_at: '2024-04-11 16:48:59'
nwb:
device:
description: Microscope Information
Expand Down Expand Up @@ -119,7 +123,3 @@ snakemake:
forcetargets: true
lock: false
use_conda: true
started_at: '2023-11-22 17:20:42'
success: success
unique_id: tutorial2
workspace_id: '1'
Loading

0 comments on commit ccc71a0

Please sign in to comment.