![]() |
风流倜傥的高山 · 民事诉讼法(1996年6月26日第109号法 ...· 4 月前 · |
![]() |
仗义的长颈鹿 · 全国青联、全国学联关于南海仲裁案结果的声明_ ...· 5 月前 · |
![]() |
私奔的硬盘 · 前端过滤,搜索框注入案例 - ...· 9 月前 · |
![]() |
侠义非凡的红金鱼 · 奔驰大G两座版来了,不过怎么看着像大号吉姆尼 ...· 1 年前 · |
Hi everbody,
I have a bit of a general question/suggestion for Napari.
Is there currently any function, widget or plugin that allows the user to define a scale (pixel size) for a specific layer?
I’m thinking of something like the ImageJ tool “Set Scale”
I know how to adjust the image scaling programmatically but it would be great to have a GUI option to do so.
You can easily do:
viewer.layers[‘your_layers_name’].scale = [3, 1, 1]
With the values corresponding to : [z,y,x]
Can also be a tuple.
edit:
Didn’t read the post fully.
the napari-pyclesperanto-assistant plugin has a utilities ‘set voxel’, and ‘set voxel of all layers’ under tools> utilities> .
Hi @andreas.m.arnold ,
the napari-pyclesperanto-assistant has this functionality.
You can also read the voxel size using the napari-layer-details-display .
Both come together in the devbio-napari distribution.
Let us know if this works for you.
Best,
Robert
Hi
@haesleinhuepf
I tried installing mamba and devbio-napari following the instructions in
devbio-napari
.
While installing mamba with
conda install mamba -c conda-forge
seems to have worked, I now get an error when trying to create an environment with
mamba create --name devbio-napari-env python=3.9 devbio-napari -c conda-forge -c pytorch
The error message is:
argument COMMAND: conflicting subparser: repoquery
# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<
Traceback (most recent call last):
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\conda\exception_handler.py", line 17, in __call__
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 945, in exception_converter
raise e
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 938, in exception_converter
exit_code = _wrapped_main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 877, in _wrapped_main
configure_parser_repoquery(p._subparsers._group_actions[0])
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 805, in configure_parser_repoquery
p = sub_parsers.add_parser(
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\argparse.py", line 1192, in add_parser
raise ArgumentError(self, _('conflicting subparser: %s') % name)
argparse.ArgumentError: argument COMMAND: conflicting subparser: repoquery
`$ C:\Users\arnoldam\AppData\Local\anaconda3\Scripts\mamba create --name devbio-napari-env python=3.9 devbio-napari -c conda-forge -c pytorch`
environment variables:
CIO_TEST=<not set>
CONDA_DEFAULT_ENV=base
CONDA_EXE=C:\Users\arnoldam\AppData\Local\anaconda3\condabin\..\Scripts\conda.ex
CONDA_EXES="C:\Users\arnoldam\AppData\Local\anaconda3\condabin\..\Scripts\conda.e
CONDA_PREFIX=C:\Users\arnoldam\AppData\Local\anaconda3
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=C:\Users\arnoldam\AppData\Local\anaconda3\python.exe
CONDA_ROOT=C:\Users\arnoldam\AppData\Local\anaconda3
CONDA_SHLVL=1
CUDA_PATH=C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0
CURL_CA_BUNDLE=<not set>
HOMEPATH=\
LD_PRELOAD=<not set>
NVTOOLSEXT_PATH=C:\Program Files\NVIDIA Corporation\NvToolsExt\
PATH=C:\Users\arnoldam\AppData\Local\anaconda3;C:\Users\arnoldam\AppData\Lo
cal\anaconda3\Library\mingw-
w64\bin;C:\Users\arnoldam\AppData\Local\anaconda3\Library\usr\bin;C:\U
sers\arnoldam\AppData\Local\anaconda3\Library\bin;C:\Users\arnoldam\Ap
pData\Local\anaconda3\Scripts;C:\Users\arnoldam\AppData\Local\anaconda
3\bin;C:\Users\arnoldam\AppData\Local\anaconda3\condabin;C:\Program
Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files\NVIDIA
GPU Computing Toolkit\CUDA\v10.0\bin;C:\Program Files\NVIDIA GPU
Computing Toolkit\CUDA\v10.0\libnvvp;C:\cygwin64\bin;C:\cygwin64\usr\l
ocal\IMOD\bin;C:\Program Files (x86)\Intel\Intel(R) Management Engine
Components\iCLS;C:\Program Files\Intel\Intel(R) Management Engine Comp
onents\iCLS;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:
\windows\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\HID
Global\ActivClient;C:\Program Files\HID Global\ActivClient;C:\Program
Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program
Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files
(x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program
Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program
Files\Microsoft VS Code\bin;C:\Program Files (x86)\NVIDIA
Corporation\PhysX\Common;C:\Program
Files\MATLAB\R2023a\runtime\win64;C:\Program
Files\MATLAB\R2023a\bin;C:\Program Files\dotnet;C:\Program
Files\Git\cmd;C:\Users\arnoldam\AppData\Local\Microsoft\WindowsApps;.
PSMODULEPATH=C:\Program Files\WindowsPowerShell\Modules;C:\windows\system32\Windows
PowerShell\v1.0\Modules
REQUESTS_CA_BUNDLE=<not set>
SSL_CERT_FILE=<not set>
active environment : base
active env location : C:\Users\arnoldam\AppData\Local\anaconda3
shell level : 1
user config file : C:\Users\arnoldam\.condarc
populated config files :
conda version : 23.7.4
conda-build version : 3.27.0
python version : 3.11.5.final.0
virtual packages : __archspec=1=x86_64
__cuda=11.7=0
__win=0=0
base environment : C:\Users\arnoldam\AppData\Local\anaconda3 (writable)
conda av data dir : C:\Users\arnoldam\AppData\Local\anaconda3\etc\conda
conda av metadata url : None
channel URLs : https://repo.anaconda.com/pkgs/main/win-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/win-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/msys2/win-64
https://repo.anaconda.com/pkgs/msys2/noarch
package cache : C:\Users\arnoldam\AppData\Local\anaconda3\pkgs
C:\Users\arnoldam\.conda\pkgs
C:\Users\arnoldam\AppData\Local\conda\conda\pkgs
envs directories : C:\Users\arnoldam\AppData\Local\anaconda3\envs
C:\Users\arnoldam\.conda\envs
C:\Users\arnoldam\AppData\Local\conda\conda\envs
platform : win-64
user-agent : conda/23.7.4 requests/2.31.0 CPython/3.11.5 Windows/10 Windows/10.0.19045
administrator : False
netrc file : None
offline mode : False
An unexpected error has occurred. Conda has prepared the above report.
If you suspect this error is being caused by a malfunctioning plugin,
consider using the --no-plugins option to turn off plugins.
Example: conda --no-plugins install <package>
Alternatively, you can set the CONDA_NO_PLUGINS environment variable on
the command line to run the command without plugins enabled.
Example: CONDA_NO_PLUGINS=true conda install <package>
Do you have an idea what’s happening here? Might it be a problem with using a full anaconda distribution instead of miniconda?
Also, is there any best practice as to what “version” of Napari to use as a base install? I keep running into issues where different plugins seem to be incompatible. Hence I’m a bit worried about installing a big plugin like devbio-napari (is it even a plugin or am I mistaken) for something small like adding a scale.
I’m just wondering how to best use Napari to avoid such issues as much as possible.
Small addition:
I get the same (or at least a similar) error when trying to install an empty environment with
mamba create -y -n test-env -c conda-forge python=3.10
The error is:
argument COMMAND: conflicting subparser: repoquery
# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<
Traceback (most recent call last):
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\conda\exception_handler.py", line 17, in __call__
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 945, in exception_converter
raise e
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 938, in exception_converter
exit_code = _wrapped_main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 877, in _wrapped_main
configure_parser_repoquery(p._subparsers._group_actions[0])
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\site-packages\mamba\mamba.py", line 805, in configure_parser_repoquery
p = sub_parsers.add_parser(
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\arnoldam\AppData\Local\anaconda3\Lib\argparse.py", line 1192, in add_parser
raise ArgumentError(self, _('conflicting subparser: %s') % name)
argparse.ArgumentError: argument COMMAND: conflicting subparser: repoquery
`$ C:\Users\arnoldam\AppData\Local\anaconda3\Scripts\mamba create -y -n test-env -c conda-forge python=3.10`
environment variables:
CIO_TEST=<not set>
CONDA_DEFAULT_ENV=base
CONDA_EXE=C:\Users\arnoldam\AppData\Local\anaconda3\condabin\..\Scripts\conda.ex
CONDA_PREFIX=C:\Users\arnoldam\AppData\Local\anaconda3
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=C:\Users\arnoldam\AppData\Local\anaconda3\python.exe
CONDA_ROOT=C:\Users\arnoldam\AppData\Local\anaconda3
CONDA_SHLVL=1
CUDA_PATH=C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0
CURL_CA_BUNDLE=<not set>
HOMEPATH=\
LD_PRELOAD=<not set>
NVTOOLSEXT_PATH=C:\Program Files\NVIDIA Corporation\NvToolsExt\
PATH=C:\Users\arnoldam\AppData\Local\anaconda3;C:\Users\arnoldam\AppData\Lo
cal\anaconda3\Library\mingw-
w64\bin;C:\Users\arnoldam\AppData\Local\anaconda3\Library\usr\bin;C:\U
sers\arnoldam\AppData\Local\anaconda3\Library\bin;C:\Users\arnoldam\Ap
pData\Local\anaconda3\Scripts;C:\Users\arnoldam\AppData\Local\anaconda
3\bin;C:\Users\arnoldam\AppData\Local\anaconda3\condabin;C:\Program
Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files\NVIDIA
GPU Computing Toolkit\CUDA\v10.0\bin;C:\Program Files\NVIDIA GPU
Computing Toolkit\CUDA\v10.0\libnvvp;C:\cygwin64\bin;C:\cygwin64\usr\l
ocal\IMOD\bin;C:\Program Files (x86)\Intel\Intel(R) Management Engine
Components\iCLS;C:\Program Files\Intel\Intel(R) Management Engine Comp
onents\iCLS;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:
\windows\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\HID
Global\ActivClient;C:\Program Files\HID Global\ActivClient;C:\Program
Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program
Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files
(x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program
Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program
Files\Microsoft VS Code\bin;C:\Program Files (x86)\NVIDIA
Corporation\PhysX\Common;C:\Program
Files\MATLAB\R2023a\runtime\win64;C:\Program
Files\MATLAB\R2023a\bin;C:\Program Files\dotnet;C:\Program
Files\Git\cmd;C:\Users\arnoldam\AppData\Local\Microsoft\WindowsApps;.
PSMODULEPATH=C:\Program Files\WindowsPowerShell\Modules;C:\windows\system32\Windows
PowerShell\v1.0\Modules
REQUESTS_CA_BUNDLE=<not set>
SSL_CERT_FILE=<not set>
active environment : base
active env location : C:\Users\arnoldam\AppData\Local\anaconda3
shell level : 1
user config file : C:\Users\arnoldam\.condarc
populated config files :
conda version : 23.7.4
conda-build version : 3.27.0
python version : 3.11.5.final.0
virtual packages : __archspec=1=x86_64
__cuda=11.7=0
__win=0=0
base environment : C:\Users\arnoldam\AppData\Local\anaconda3 (writable)
conda av data dir : C:\Users\arnoldam\AppData\Local\anaconda3\etc\conda
conda av metadata url : None
channel URLs : https://repo.anaconda.com/pkgs/main/win-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/win-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/msys2/win-64
https://repo.anaconda.com/pkgs/msys2/noarch
package cache : C:\Users\arnoldam\AppData\Local\anaconda3\pkgs
C:\Users\arnoldam\.conda\pkgs
C:\Users\arnoldam\AppData\Local\conda\conda\pkgs
envs directories : C:\Users\arnoldam\AppData\Local\anaconda3\envs
C:\Users\arnoldam\.conda\envs
C:\Users\arnoldam\AppData\Local\conda\conda\envs
platform : win-64
user-agent : conda/23.7.4 requests/2.31.0 CPython/3.11.5 Windows/10 Windows/10.0.19045
administrator : False
netrc file : None
offline mode : False
An unexpected error has occurred. Conda has prepared the above report.
If you suspect this error is being caused by a malfunctioning plugin,
consider using the --no-plugins option to turn off plugins.
Example: conda --no-plugins install <package>
Alternatively, you can set the CONDA_NO_PLUGINS environment variable on
the command line to run the command without plugins enabled.
Example: CONDA_NO_PLUGINS=true conda install <package>
So it seems to be an issue with mamba rather than devbio-napari (?)
That’s a bit inconvenient because I need to get IT for that (at NIH we need IT for most anything because of the security system
) but I can definitly reinstall it…
Would it be better to use miniconda? I just used anaconda because I wanted to try out the QtDesigner that comes with it…
I’m just wondering if I can make my life easier.
Edit: I believe I originally misunderstood your answer… you are saying I should install mambaforge instead of anaconda?
### Solution to issue cannot be found in the documentation.
- [X] I checked the… documentation.
### Issue
mamba clean --a
mamba update --a
result in the following error , while <conda> command has the expected behaviour.
Apple M2 Max, macOS 14.0 (23A344)
(base) steffen@snmb ~ % mamba clean --all
argument COMMAND: conflicting subparser: repoquery
# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<
Traceback (most recent call last):
File "/Users/steffen/miniforge3/lib/python3.11/site-packages/conda/exception_handler.py", line 17, in __call__
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/Users/steffen/miniforge3/lib/python3.11/site-packages/mamba/mamba.py", line 945, in exception_converter
raise e
File "/Users/steffen/miniforge3/lib/python3.11/site-packages/mamba/mamba.py", line 938, in exception_converter
exit_code = _wrapped_main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/steffen/miniforge3/lib/python3.11/site-packages/mamba/mamba.py", line 877, in _wrapped_main
configure_parser_repoquery(p._subparsers._group_actions[0])
File "/Users/steffen/miniforge3/lib/python3.11/site-packages/mamba/mamba.py", line 805, in configure_parser_repoquery
p = sub_parsers.add_parser(
^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/steffen/miniforge3/lib/python3.11/argparse.py", line 1192, in add_parser
raise ArgumentError(self, _('conflicting subparser: %s') % name)
argparse.ArgumentError: argument COMMAND: conflicting subparser: repoquery
`$ /Users/steffen/miniforge3/bin/mamba clean --all`
environment variables:
CIO_TEST=<not set>
CONDA_DEFAULT_ENV=base
CONDA_EXE=/Users/steffen/miniforge3/bin/conda
CONDA_PREFIX=/Users/steffen/miniforge3
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=/Users/steffen/miniforge3/bin/python
CONDA_ROOT=/Users/steffen/miniforge3
CONDA_SHLVL=1
CURL_CA_BUNDLE=<not set>
INFOPATH=/opt/homebrew/share/info:
LD_PRELOAD=<not set>
MANPATH=/opt/homebrew/share/man::
PATH=/Users/steffen/miniforge3/bin:/Users/steffen/miniforge3/condabin:/opt/
homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/u
sr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.crypt
exd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.c
ryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cry
ptexd/codex.system/bootstrap/usr/appleinternal/bin
REQUESTS_CA_BUNDLE=<not set>
SSL_CERT_FILE=<not set>
active environment : base
active env location : /Users/steffen/miniforge3
shell level : 1
user config file : /Users/steffen/.condarc
populated config files :
conda version : 23.7.4
conda-build version : not installed
python version : 3.11.6.final.0
virtual packages : __archspec=1=arm64
__osx=14.0=0
__unix=0=0
base environment : /Users/steffen/miniforge3 (writable)
conda av data dir : /Users/steffen/miniforge3/etc/conda
conda av metadata url : None
channel URLs : https://repo.anaconda.com/pkgs/main/osx-arm64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/osx-arm64
https://repo.anaconda.com/pkgs/r/noarch
package cache : /Users/steffen/miniforge3/pkgs
/Users/steffen/.conda/pkgs
envs directories : /Users/steffen/miniforge3/envs
/Users/steffen/.conda/envs
platform : osx-arm64
user-agent : conda/23.7.4 requests/2.31.0 CPython/3.11.6 Darwin/23.0.0 OSX/14.0
UID:GID : 501:20
netrc file : None
offline mode : False
An unexpected error has occurred. Conda has prepared the above report.
If you suspect this error is being caused by a malfunctioning plugin,
consider using the --no-plugins option to turn off plugins.
Example: conda --no-plugins install <package>
Alternatively, you can set the CONDA_NO_PLUGINS environment variable on
the command line to run the command without plugins enabled.
Example: CONDA_NO_PLUGINS=true conda install <package>
### Installed packages
```shell
# packages in environment at /Users/steffen/miniforge3:
# Name Version Build Channel
aiocache 0.12.2 pyhd8ed1ab_0 conda-forge
aiohttp 3.8.5 py311heffc1b2_0 conda-forge
aiomcache 0.8.1 pypi_0 pypi
aiosignal 1.3.1 pyhd8ed1ab_0 conda-forge
alpha_vantage 2.3.1 pyhd8ed1ab_0 conda-forge
anyio 4.0.0 pyhd8ed1ab_0 conda-forge
appnope 0.1.3 pyhd8ed1ab_0 conda-forge
argon2-cffi 23.1.0 pyhd8ed1ab_0 conda-forge
argon2-cffi-bindings 21.2.0 py311heffc1b2_4 conda-forge
arrow 1.3.0 pyhd8ed1ab_0 conda-forge
asttokens 2.4.0 pyhd8ed1ab_0 conda-forge
async-lru 2.0.4 pyhd8ed1ab_0 conda-forge
async-timeout 4.0.3 pyhd8ed1ab_0 conda-forge
attrs 23.1.0 pyh71513ae_1 conda-forge
aws-c-auth 0.7.4 h2ed40ff_1 conda-forge
aws-c-cal 0.6.2 h12c43c8_2 conda-forge
aws-c-common 0.9.3 hb547adb_0 conda-forge
aws-c-compression 0.2.17 h12c43c8_3 conda-forge
aws-c-event-stream 0.3.2 h88fe898_1 conda-forge
aws-c-http 0.7.13 he062130_1 conda-forge
aws-c-io 0.13.32 h13ba428_4 conda-forge
aws-c-mqtt 0.9.6 h3ffe4bb_2 conda-forge
aws-c-s3 0.3.17 hf064be9_3 conda-forge
aws-c-sdkutils 0.1.12 h12c43c8_2 conda-forge
aws-checksums 0.1.17 h12c43c8_2 conda-forge
aws-crt-cpp 0.23.1 h96fc18d_5 conda-forge
aws-sdk-cpp 1.11.156 he831950_3 conda-forge
babel 2.12.1 pyhd8ed1ab_1 conda-forge
backcall 0.2.0 pyh9f0ad1d_0 conda-forge
backports 1.0 pyhd8ed1ab_3 conda-forge
backports.functools_lru_cache 1.6.5 pyhd8ed1ab_0 conda-forge
beautifulsoup4 4.12.2 pyha770c72_0 conda-forge
bleach 6.0.0 pyhd8ed1ab_0 conda-forge
bokeh 3.2.2 pyhd8ed1ab_0 conda-forge
boltons 23.0.0 pyhd8ed1ab_0 conda-forge
boost-cpp 1.82.0 hca5e981_5 conda-forge
bottleneck 1.3.7 py311hb49d859_1 conda-forge
brotli 1.1.0 hb547adb_1 conda-forge
brotli-bin 1.1.0 hb547adb_1 conda-forge
brotli-python 1.1.0 py311ha891d26_1 conda-forge
bzip2 1.0.8 h3422bc3_4 conda-forge
c-ares 1.19.1 hb547adb_0 conda-forge
ca-certificates 2023.7.22 hf0a4a13_0 conda-forge
cached-property 1.5.2 hd8ed1ab_1 conda-forge
cached_property 1.5.2 pyha770c72_1 conda-forge
cachetools 5.3.1 pyhd8ed1ab_0 conda-forge
certifi 2023.7.22 pyhd8ed1ab_0 conda-forge
cffi 1.16.0 py311h4a08483_0 conda-forge
charset-normalizer 3.2.0 pyhd8ed1ab_0 conda-forge
click 8.1.7 unix_pyh707e725_0 conda-forge
cloudpickle 2.2.1 pyhd8ed1ab_0 conda-forge
colorama 0.4.6 pyhd8ed1ab_0 conda-forge
comm 0.1.4 pyhd8ed1ab_0 conda-forge
conda 23.7.4 py311h267d04e_0 conda-forge
conda-libmamba-solver 23.9.1 pyhd8ed1ab_0 conda-forge
conda-package-handling 2.2.0 pyh38be061_0 conda-forge
conda-package-streaming 0.9.0 pyhd8ed1ab_0 conda-forge
confuse 2.0.1 pyhd8ed1ab_0 conda-forge
contourpy 1.1.1 py311he4fd1f5_1 conda-forge
cryptography 41.0.4 py311h5fb2c35_0 conda-forge
cvxpy 1.3.2 py311ha1ab1f8_0 conda-forge
cvxpy-base 1.3.2 py311h9e438b8_0 conda-forge
cycler 0.11.0 pyhd8ed1ab_0 conda-forge
cython 3.0.2 py311ha891d26_2 conda-forge
cytoolz 0.12.2 py311heffc1b2_1 conda-forge
dask 2023.9.3 pyhd8ed1ab_0 conda-forge
dask-core 2023.9.3 pyhd8ed1ab_0 conda-forge
debugpy 1.8.0 py311ha891d26_1 conda-forge
decorator 5.1.1 pyhd8ed1ab_0 conda-forge
defusedxml 0.7.1 pyhd8ed1ab_0 conda-forge
dill 0.3.7 pyhd8ed1ab_0 conda-forge
distex 0.7.2 pypi_0 pypi
distributed 2023.9.3 pyhd8ed1ab_0 conda-forge
ecos 2.0.11 py311h4add359_0 conda-forge
entrypoints 0.4 pyhd8ed1ab_0 conda-forge
eventkit 1.0.0 pyhd8ed1ab_0 conda-forge
exceptiongroup 1.1.3 pyhd8ed1ab_0 conda-forge
executing 1.2.0 pyhd8ed1ab_0 conda-forge
fmt 10.1.1 h1995070_0 conda-forge
fonttools 4.43.0 py311heffc1b2_0 conda-forge
fqdn 1.5.1 pyhd8ed1ab_0 conda-forge
freetype 2.12.1 hadb7bae_2 conda-forge
frozenlist 1.4.0 py311heffc1b2_1 conda-forge
fsspec 2023.9.2 pyh1a96a4e_0 conda-forge
gflags 2.2.2 hc88da5d_1004 conda-forge
glog 0.6.0 h6da1cb0_0 conda-forge
hdf5 1.14.2 nompi_h3aba7b3_100 conda-forge
ib-insync 0.9.82 pyhd8ed1ab_0 conda-forge
icu 73.2 hc8870d7_0 conda-forge
idna 3.4 pyhd8ed1ab_0 conda-forge
importlib-metadata 6.8.0 pyha770c72_0 conda-forge
importlib_metadata 6.8.0 hd8ed1ab_0 conda-forge
importlib_resources 6.1.0 pyhd8ed1ab_0 conda-forge
inflection 0.5.1 pyh9f0ad1d_0 conda-forge
ipykernel 6.25.2 pyh1050b4e_0 conda-forge
ipython 8.16.1 pyh31c8845_0 conda-forge
isoduration 20.11.0 pyhd8ed1ab_0 conda-forge
jedi 0.19.1 pyhd8ed1ab_0 conda-forge
jinja2 3.1.2 pyhd8ed1ab_1 conda-forge
joblib 1.3.2 pyhd8ed1ab_0 conda-forge
json5 0.9.14 pyhd8ed1ab_0 conda-forge
jsonpatch 1.33 pyhd8ed1ab_0 conda-forge
jsonpointer 2.4 py311h267d04e_3 conda-forge
jsonschema 4.19.1 pyhd8ed1ab_0 conda-forge
jsonschema-specifications 2023.7.1 pyhd8ed1ab_0 conda-forge
jsonschema-with-format-nongpl 4.19.1 pyhd8ed1ab_0 conda-forge
jupyter-lsp 2.2.0 pyhd8ed1ab_0 conda-forge
jupyter_client 8.3.1 pyhd8ed1ab_0 conda-forge
jupyter_core 5.3.2 py311h267d04e_0 conda-forge
jupyter_events 0.7.0 pyhd8ed1ab_2 conda-forge
jupyter_server 2.7.3 pyhd8ed1ab_1 conda-forge
jupyter_server_terminals 0.4.4 pyhd8ed1ab_1 conda-forge
jupyterlab 4.0.6 pyhd8ed1ab_0 conda-forge
jupyterlab_pygments 0.2.2 pyhd8ed1ab_0 conda-forge
jupyterlab_server 2.25.0 pyhd8ed1ab_0 conda-forge
kiwisolver 1.4.5 py311he4fd1f5_1 conda-forge
krb5 1.21.2 h92f50d5_0 conda-forge
lcms2 2.15 hf2736f0_3 conda-forge
lerc 4.0.0 h9a09cb3_0 conda-forge
libabseil 20230802.1 cxx17_h13dd4ca_0 conda-forge
libaec 1.1.1 h13dd4ca_0 conda-forge
libarchive 3.7.2 h82b9b87_0 conda-forge
libarrow 13.0.0 h0c25ffe_5_cpu conda-forge
libblas 3.9.0 18_osxarm64_openblas conda-forge
libboost 1.82.0 h72cdd8a_5 conda-forge
libboost-devel 1.82.0 hf450f58_5 conda-forge
libboost-headers 1.82.0 hce30654_5 conda-forge
libbrotlicommon 1.1.0 hb547adb_1 conda-forge
libbrotlidec 1.1.0 hb547adb_1 conda-forge
libbrotlienc 1.1.0 hb547adb_1 conda-forge
libcblas 3.9.0 18_osxarm64_openblas conda-forge
libcrc32c 1.1.2 hbdafb3b_0 conda-forge
libcurl 8.3.0 hc52a3a8_0 conda-forge
libcxx 16.0.6 h4653b0c_0 conda-forge
libdeflate 1.19 hb547adb_0 conda-forge
libedit 3.1.20191231 hc8eb9b7_2 conda-forge
libev 4.33 h642e427_1 conda-forge
libevent 2.1.12 h2757513_1 conda-forge
libexpat 2.5.0 hb7217d7_1 conda-forge
libffi 3.4.2 h3422bc3_5 conda-forge
libgfortran 5.0.0 13_2_0_hd922786_1 conda-forge
libgfortran5 13.2.0 hf226fd6_1 conda-forge
libgoogle-cloud 2.12.0 hde42cda_2 conda-forge
libgrpc 1.57.0 hdbe17d8_1 conda-forge
libiconv 1.17 he4db4b2_0 conda-forge
libjpeg-turbo 3.0.0 hb547adb_1 conda-forge
liblapack 3.9.0 18_osxarm64_openblas conda-forge
libmamba 1.5.1 hace0f30_1 conda-forge
libmambapy 1.5.1 py311h7cacacc_1 conda-forge
libnghttp2 1.52.0 hae82a92_0 conda-forge
libopenblas 0.3.24 openmp_hd76b1f2_0 conda-forge
libosqp 0.6.3 h13dd4ca_0 conda-forge
libpng 1.6.39 h76d750c_0 conda-forge
libprotobuf 4.23.4 hf590ac1_6 conda-forge
libqdldl 0.1.5 hb7217d7_1 conda-forge
libsodium 1.0.18 h27ca646_1 conda-forge
libsolv 0.7.25 ha614eb4_0 conda-forge
libsqlite 3.43.0 hb31c410_0 conda-forge
libssh2 1.11.0 h7a5bd25_0 conda-forge
libthrift 0.19.0 h026a170_1 conda-forge
libtiff 4.6.0 ha8a6c65_2 conda-forge
libutf8proc 2.8.0 h1a8c8d9_0 conda-forge
libuv 1.46.0 hb547adb_0 conda-forge
libwebp-base 1.3.2 hb547adb_0 conda-forge
libxcb 1.15 hf346824_0 conda-forge
libxml2 2.11.5 h25269f3_1 conda-forge
libzip 1.10.1 ha0bc3c6_3 conda-forge
libzlib 1.2.13 h53f4e23_5 conda-forge
llvm-openmp 16.0.6 h1c12783_0 conda-forge
llvmlite 0.41.0 py311_0 numba
locket 1.0.0 pyhd8ed1ab_0 conda-forge
lz4 4.3.2 py311h0c6baac_1 conda-forge
lz4-c 1.9.4 hb7217d7_0 conda-forge
lzo 2.10 h642e427_1000 conda-forge
mamba 1.5.1 py311hb045da1_1 conda-forge
markupsafe 2.1.3 py311heffc1b2_1 conda-forge
matplotlib 3.8.0 py311ha1ab1f8_1 conda-forge
matplotlib-base 3.8.0 py311h3bc9839_1 conda-forge
matplotlib-inline 0.1.6 pyhd8ed1ab_0 conda-forge
mistune 3.0.1 pyhd8ed1ab_0 conda-forge
more-itertools 10.1.0 pyhd8ed1ab_0 conda-forge
msgpack-python 1.0.6 py311he4fd1f5_0 conda-forge
multidict 6.0.4 py311he2be06e_0 conda-forge
munkres 1.1.4 pyh9f0ad1d_0 conda-forge
nbclient 0.8.0 pyhd8ed1ab_0 conda-forge
nbconvert-core 7.8.0 pyhd8ed1ab_0 conda-forge
nbformat 5.9.2 pyhd8ed1ab_0 conda-forge
ncurses 6.4 h7ea286d_0 conda-forge
nest-asyncio 1.5.6 pyhd8ed1ab_0 conda-forge
notebook 7.0.4 pyhd8ed1ab_0 conda-forge
notebook-shim 0.2.3 pyhd8ed1ab_0 conda-forge
numba 0.58.0 np1.22py3.11h8833779_g54c0cf862_0 numba
numexpr 2.8.7 py311h9e438b8_2 conda-forge
numpy 1.25.2 py311hb8f3215_0 conda-forge
openjpeg 2.5.0 h4c1507b_3 conda-forge
openssl 3.1.3 h53f4e23_0 conda-forge
orc 1.9.0 hbfdecac_2 conda-forge
osqp 0.6.3 py311h9e438b8_1 conda-forge
overrides 7.4.0 pyhd8ed1ab_0 conda-forge
packaging 23.2 pyhd8ed1ab_0 conda-forge
pandas 2.1.1 py311h9e438b8_1 conda-forge
pandocfilters 1.5.0 pyhd8ed1ab_0 conda-forge
parso 0.8.3 pyhd8ed1ab_0 conda-forge
partd 1.4.1 pyhd8ed1ab_0 conda-forge
patsy 0.5.3 pyhd8ed1ab_0 conda-forge
pexpect 4.8.0 pyh1a96a4e_2 conda-forge
pickleshare 0.7.5 py_1003 conda-forge
pillow 10.0.1 py311h8dc27b9_2 conda-forge
pip 23.2.1 pyhd8ed1ab_0 conda-forge
pkgutil-resolve-name 1.3.10 pyhd8ed1ab_1 conda-forge
platformdirs 3.11.0 pyhd8ed1ab_0 conda-forge
pluggy 1.3.0 pyhd8ed1ab_0 conda-forge
prometheus_client 0.17.1 pyhd8ed1ab_0 conda-forge
prompt-toolkit 3.0.39 pyha770c72_0 conda-forge
prompt_toolkit 3.0.39 hd8ed1ab_0 conda-forge
psutil 5.9.5 py311heffc1b2_1 conda-forge
pthread-stubs 0.4 h27ca646_1001 conda-forge
ptyprocess 0.7.0 pyhd3deb0d_0 conda-forge
pure_eval 0.2.2 pyhd8ed1ab_0 conda-forge
py-lets-be-rational 1.0.1 pypi_0 pypi
py-vollib 1.0.1 pypi_0 pypi
pyarrow 13.0.0 py311hd7bc329_5_cpu conda-forge
pybind11-abi 4 hd8ed1ab_3 conda-forge
pycosat 0.6.6 py311heffc1b2_0 conda-forge
pycparser 2.21 pyhd8ed1ab_0 conda-forge
pygments 2.16.1 pyhd8ed1ab_0 conda-forge
pyobjc-core 10.0 py311hb702dc4_0 conda-forge
pyobjc-framework-cocoa 10.0 py311hb702dc4_1 conda-forge
pyopenssl 23.2.0 pyhd8ed1ab_1 conda-forge
pyparsing 3.1.1 pyhd8ed1ab_0 conda-forge
pysocks 1.7.1 pyha2e5f31_6 conda-forge
python 3.11.6 h47c9636_0_cpython conda-forge
python-dateutil 2.8.2 pyhd8ed1ab_0 conda-forge
python-fastjsonschema 2.18.1 pyhd8ed1ab_0 conda-forge
python-json-logger 2.0.7 pyhd8ed1ab_0 conda-forge
python-tzdata 2023.3 pyhd8ed1ab_0 conda-forge
python_abi 3.11 4_cp311 conda-forge
pytrade 1.0.0 dev_0 <develop>
pytz 2023.3.post1 pyhd8ed1ab_0 conda-forge
pyyaml 6.0.1 py311heffc1b2_1 conda-forge
pyzmq 25.1.1 py311hb1af645_1 conda-forge
qdldl-python 0.1.5.post2 py311h4eec4a9_0 conda-forge
quandl 3.7.0 pypi_0 pypi
re2 2023.03.02 hc5e2d97_0 conda-forge
readline 8.2 h92ec313_1 conda-forge
referencing 0.30.2 pyhd8ed1ab_0 conda-forge
reproc 14.2.4.post0 hb547adb_0 conda-forge
reproc-cpp 14.2.4.post0 h13dd4ca_0 conda-forge
requests 2.31.0 pyhd8ed1ab_0 conda-forge
rfc3339-validator 0.1.4 pyhd8ed1ab_0 conda-forge
rfc3986-validator 0.1.1 pyh9f0ad1d_0 conda-forge
rpds-py 0.10.3 py311h0563b04_1 conda-forge
ruamel.yaml 0.17.33 py311heffc1b2_1 conda-forge
ruamel.yaml.clib 0.2.7 py311heffc1b2_2 conda-forge
scikit-learn 1.3.1 py311hf0b18b8_0 conda-forge
scipy 1.11.3 py311h93d07a4_0 conda-forge
scs 3.2.3 py311h0dc035f_0 conda-forge
seaborn 0.13.0 hd8ed1ab_0 conda-forge
seaborn-base 0.13.0 pyhd8ed1ab_0 conda-forge
send2trash 1.8.2 pyhd1c38e8_0 conda-forge
setuptools 68.2.2 pyhd8ed1ab_0 conda-forge
simplejson 3.19.1 py311heffc1b2_1 conda-forge
six 1.16.0 pyh6c4a22f_0 conda-forge
snappy 1.1.10 h17c5cce_0 conda-forge
sniffio 1.3.0 pyhd8ed1ab_0 conda-forge
sortedcontainers 2.4.0 pyhd8ed1ab_0 conda-forge
soupsieve 2.5 pyhd8ed1ab_1 conda-forge
stack_data 0.6.2 pyhd8ed1ab_0 conda-forge
statsmodels 0.14.0 py311hb49d859_1 conda-forge
tblib 2.0.0 pyhd8ed1ab_0 conda-forge
terminado 0.17.1 pyhd1c38e8_0 conda-forge
threadpoolctl 3.2.0 pyha21a80b_0 conda-forge
tinycss2 1.2.1 pyhd8ed1ab_0 conda-forge
tk 8.6.13 hb31c410_0 conda-forge
tomli 2.0.1 pyhd8ed1ab_0 conda-forge
toolz 0.12.0 pyhd8ed1ab_0 conda-forge
tornado 6.3.3 py311heffc1b2_1 conda-forge
tqdm 4.66.1 pyhd8ed1ab_0 conda-forge
traitlets 5.11.2 pyhd8ed1ab_0 conda-forge
types-python-dateutil 2.8.19.14 pyhd8ed1ab_0 conda-forge
typing-extensions 4.8.0 hd8ed1ab_0 conda-forge
typing_extensions 4.8.0 pyha770c72_0 conda-forge
typing_utils 0.1.0 pyhd8ed1ab_0 conda-forge
tzdata 2023c h71feb2d_0 conda-forge
ujson 5.8.0 py311ha891d26_0 conda-forge
uri-template 1.3.0 pyhd8ed1ab_0 conda-forge
urllib3 2.0.5 pyhd8ed1ab_0 conda-forge
uvloop 0.17.0 py311heffc1b2_2 conda-forge
wcwidth 0.2.8 pyhd8ed1ab_0 conda-forge
webcolors 1.13 pyhd8ed1ab_0 conda-forge
webencodings 0.5.1 pyhd8ed1ab_2 conda-forge
websocket-client 1.6.3 pyhd8ed1ab_0 conda-forge
wheel 0.41.2 pyhd8ed1ab_0 conda-forge
xorg-libxau 1.0.11 hb547adb_0 conda-forge
xorg-libxdmcp 1.1.3 h27ca646_0 conda-forge
xyzservices 2023.7.0 pyhd8ed1ab_0 conda-forge
xz 5.2.6 h57fd34a_0 conda-forge
yaml 0.2.5 h3422bc3_2 conda-forge
yaml-cpp 0.8.0 h13dd4ca_0 conda-forge
yarl 1.9.2 py311heffc1b2_0 conda-forge
zeromq 4.3.4 hbdafb3b_1 conda-forge
zict 3.0.0 pyhd8ed1ab_0 conda-forge
zipp 3.17.0 pyhd8ed1ab_0 conda-forge
zlib 1.2.13 h53f4e23_5 conda-forge
zstandard 0.21.0 py311hae4035a_1 conda-forge
zstd 1.5.5 h4f39d0f_0 conda-forge
### Environment info
```shell
active environment : base
active env location : /Users/steffen/miniforge3
shell level : 1
user config file : /Users/steffen/.condarc
populated config files : /Users/steffen/miniforge3/.condarc
conda version : 23.7.4
conda-build version : not installed
python version : 3.11.6.final.0
virtual packages : __archspec=1=arm64
__osx=14.0=0
__unix=0=0
base environment : /Users/steffen/miniforge3 (writable)
conda av data dir : /Users/steffen/miniforge3/etc/conda
conda av metadata url : None
channel URLs : https://conda.anaconda.org/conda-forge/osx-arm64
https://conda.anaconda.org/conda-forge/noarch
package cache : /Users/steffen/miniforge3/pkgs
/Users/steffen/.conda/pkgs
envs directories : /Users/steffen/miniforge3/envs
/Users/steffen/.conda/envs
platform : osx-arm64
user-agent : conda/23.7.4 requests/2.31.0 CPython/3.11.6 Darwin/23.0.0 OSX/14.0
UID:GID : 501:20
netrc file : None
offline mode : False
hi @psobolewskiPhD
Thx for the tip!
In the end uninstalling anaconda and installing mambaforge instead solved this issue for me.
However, devbio-napari still doesn’t work
I get this error when trying to run
naparia
in my environment.
(devbio-napari-env) C:\>naparia
Traceback (most recent call last):
File "C:\Users\arnoldam\AppData\Local\miniforge3\envs\devbio-napari-env\Scripts\naparia-script.py", line 5, in <module>
from napari_assistant import main
File "C:\Users\arnoldam\AppData\Local\miniforge3\envs\devbio-napari-env\lib\site-packages\napari_assistant\__init__.py", line 1, in <module>
from ._gui import Assistant
File "C:\Users\arnoldam\AppData\Local\miniforge3\envs\devbio-napari-env\lib\site-packages\napari_assistant\_gui\__init__.py", line 1, in <module>
from ._Assistant import Assistant
File "C:\Users\arnoldam\AppData\Local\miniforge3\envs\devbio-napari-env\lib\site-packages\napari_assistant\_gui\_Assistant.py", line 10, in <module>
from ._button_grid import ButtonGrid, _get_highlight_brush, _get_background_brush
File "C:\Users\arnoldam\AppData\Local\miniforge3\envs\devbio-napari-env\lib\site-packages\napari_assistant\_gui\_button_grid.py", line 1, in <module>
from pyrsistent import b
ModuleNotFoundError: No module named 'pyrsistent'
Maybe @haesleinhuepf has better idea, but it looks like you have an older version Napari-assistant – that bug was fixed in remove import of pyresistant by haesleinhuepf · Pull Request #48 · haesleinhuepf/napari-assistant · GitHub
Can you give output of pip show napari-assistant
?
To fix you can try:
pip install pyrsistent
our napari-bigfish plugin also allows to set the scale (but only in nm). I know how easy it is to do this from the built-in console, but I think this is so important and expected by users that it should be part of the base-napari. Until then, it would be easy enough to write a plugin that does only this, but I do not have the time right now.
Best,
Volker
Hi @volker ,
I agree that this seems to be something that would be great as a tool in base-napari.
Maybe I can look into building small plugin for only this. Could you point out your github repo as inspiration on how to do this?
Hi @andreas.m.arnold,
sorry I was wrong. It actually asks the scale for batch processing, but doesn’t apply it to the displayed image, I thought it also did that.
Clément who is working with me is going to write the “set scale” plugin tomorrow. It can be very simple. Just a magicgui interface asking for xy-voxel size, z-voxel size and the unit as a string. It shouldn’t take him more than an hour to do this.
The layer object has an attribute scale which is a list of the scales of the different dimensions. I don’t remember the order, but it’s something like the last three are z, y and x and the unit goes to the scale-bar (viewer.scale_bar.unit
).
Best,
Volker
Volker Bäcker:
It can be very simple. Just a magicgui interface asking for xy-voxel size, z-voxel size and the unit as a string. It shouldn’t take him more than an hour to do this.
Feel free to copy from here. 
Thanks for the hint @haesleinhuepf ! This is great to build at least a temporary solution for myself 
I still think it would be great to have this as a small general plugin like @volker suggested! Please reach out if I can help or contribute!
I am not a software engineer but excited to learn more about Napari.
Thanks @haesleinhuepf for your code example!
I just finished a beta of the plugin (a poorly named version), it’s available on PyPI (set-calibration · PyPI)
Have fun trying to break it, and have a great weekend.
andy-sweet/napari-metadata/blob/e6da33db23bbdaf385daaed16564f5193d0717d9/src/napari_metadata/_axes_widget.py
from typing import TYPE_CHECKING, List, Tuple
from qtpy.QtCore import Qt
from qtpy.QtWidgets import QComboBox, QGridLayout, QLabel, QLineEdit, QWidget
from napari_metadata._axis_type import AxisType
from napari_metadata._model import (
Axis,
ChannelAxis,
SpaceAxis,
TimeAxis,
coerce_extra_metadata,
from napari_metadata._space_units import SpaceUnits
from napari_metadata._time_units import TimeUnits
from napari_metadata._widget_utils import (
CompactLineEdit,
readonly_lineedit,
set_row_visible,
update_num_rows,
From a quick skim I think it’s the most robust on this thread because it works for an arbitrary number and type of axes.
(Well, as long as the type is one of time, space, and channel.
but it’s not just xyz is what I mean.
) (The need for this flexibility is part of the reason why we still don’t have an official widget btw…
But we all agree that it needs to be in there, if someone wants to have a stab at putting it in built-ins…)
Andy has given me permission to grab it as a basis for a standalone plugin, and I presume that permission extends to anyone here. (And anyway the BSD license allows it as long as you acknowledge the source.
)
Hi @jni,
yes, that looks more elaborated
.
I installed it (napari: 0.4.18). I get ‘value is invalid’ when I want to open it and it doesn’t show up. The error also repeats each time I open a new image or select a layer afterwards.
Do I need a different version of napari or of some libaries for this to work?
Best,
Volker
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari/_qt/menus/plugins_menu.py:105, in PluginsMenu._add_plugin_actions.<locals>._add_toggle_widget(key=('napari-metadata', 'Layer metadata'), hook_type='dock')
102 return
104 if hook_type == 'dock':
--> 105 self._win.add_plugin_dock_widget(*key)
key = ('napari-metadata', 'Layer metadata')
self._win = <napari._qt.qt_main_window.Window object at 0x7fd6ac006100>
self = <napari._qt.menus.plugins_menu.PluginsMenu object at 0x7fd6199cf5e0>
106 else:
107 self._win._add_plugin_function_widget(*key)
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari/_qt/qt_main_window.py:811, in Window.add_plugin_dock_widget(self=<napari._qt.qt_main_window.Window object>, plugin_name='napari-metadata', widget_name='Layer metadata', tabify=False)
808 wdg = wdg._magic_widget
809 return dock_widget, wdg
--> 811 wdg = _instantiate_dock_widget(
Widget = <class 'napari_metadata._widget.MetadataWidget'>
self = <napari._qt.qt_main_window.Window object at 0x7fd6ac006100>
812 Widget, cast('Viewer', self._qt_viewer.viewer)
813 )
815 # Add dock widget
816 dock_kwargs.pop('name', None)
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari/_qt/qt_main_window.py:1465, in _instantiate_dock_widget(wdg_cls=<class 'napari_metadata._widget.MetadataWidget'>, viewer=Viewer(camera=Camera(center=(7.5, 255.5, 255.5),...ouse_drag_gen={}, _mouse_wheel_gen={}, keymap={}))
1460 break
1461 # cannot look for param.kind == param.VAR_KEYWORD because
1462 # QWidget allows **kwargs but errs on unknown keyword arguments
1464 # instantiate the widget
-> 1465 return wdg_cls(**kwargs)
kwargs = {'napari_viewer': Viewer(camera=Camera(center=(7.5, 255.5, 255.5), zoom=1.7793945312500001, angles=(-18.9960157284967, 5.633093956399732, 137.20513121194864), perspective=0.0, mouse_pan=True, mouse_zoom=True), cursor=Cursor(position=(124.15804477121566, 327.72926224793184, 521.6704418506295), scaled=True, size=1, style=<CursorStyle.STANDARD: 'standard'>), dims=Dims(ndim=3, ndisplay=3, last_used=2, range=((0.0, 16.0, 1.0), (0.0, 512.0, 1.0), (0.0, 512.0, 1.0)), current_step=(7, 255, 255), order=(0, 1, 2), axis_labels=('0', '2', '3')), grid=GridCanvas(stride=1, shape=(-1, -1), enabled=False), layers=[<Image layer 'nuclei' at 0x7fd53c4b2eb0>], help='use <2> for transform', status={'layer_base': 'nuclei', 'source_type': 'sample', 'plugin': 'napari builtins', 'coordinates': ' [124 328 522]'}, tooltip=Tooltip(visible=True, text=''), theme='dark', title='napari', mouse_over_canvas=True, mouse_move_callbacks=[], mouse_drag_callbacks=[], mouse_double_click_callbacks=[], mouse_wheel_callbacks=[<function dims_scroll at 0x7fd6d1acdca0>], _persisted_mouse_event={}, _mouse_drag_gen={}, _mouse_wheel_gen={}, keymap={})}
wdg_cls = <class 'napari_metadata._widget.MetadataWidget'>
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_widget.py:375, in MetadataWidget.__init__(self=<napari_metadata._widget.MetadataWidget object>, napari_viewer=Viewer(camera=Camera(center=(7.5, 255.5, 255.5),...ouse_drag_gen={}, _mouse_wheel_gen={}, keymap={}))
367 self._editable_widget._temporal_units.currentTextChanged.connect(
368 self._readonly_widget.set_temporal_units
369 )
371 self._viewer.layers.selection.events.changed.connect(
372 self._on_selected_layers_changed
373 )
--> 375 self._on_selected_layers_changed()
self = <napari_metadata._widget.MetadataWidget object at 0x7fd69ddd4dc0>
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_widget.py:408, in MetadataWidget._on_selected_layers_changed(self=<napari_metadata._widget.MetadataWidget object>)
405 coerce_extra_metadata(self._viewer, layer)
407 self._readonly_widget.set_selected_layer(layer)
--> 408 self._editable_widget.set_selected_layer(layer)
layer = <Image layer 'nuclei' at 0x7fd53c4b2eb0>
self = <napari_metadata._widget.MetadataWidget object at 0x7fd69ddd4dc0>
self._editable_widget = <napari_metadata._widget.EditableMetadataWidget object at 0x7fd69ddf4040>
410 self._selected_layer = layer
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_widget.py:148, in EditableMetadataWidget.set_selected_layer(self=<napari_metadata._widget.EditableMetadataWidget object>, layer=<Image layer 'nuclei'>)
145 time_unit = str(extras.get_time_unit())
146 self._temporal_units.setCurrentText(time_unit)
--> 148 self._spacing_widget.set_selected_layer(layer)
layer = <Image layer 'nuclei' at 0x7fd53c4b2eb0>
self = <napari_metadata._widget.EditableMetadataWidget object at 0x7fd69ddf4040>
self._spacing_widget = <napari_metadata._transform_widget.TransformWidget object at 0x7fd69ddf4670>
150 self._selected_layer = layer
151 self._update_restore_enabled()
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_transform_widget.py:76, in TransformWidget.set_selected_layer(self=<napari_metadata._transform_widget.TransformWidget object>, layer=<Image layer 'nuclei'>)
74 self._layer = layer
75 if self._layer is not None:
---> 76 self._on_layer_scale_changed()
self = <napari_metadata._transform_widget.TransformWidget object at 0x7fd69ddf4670>
77 self._on_layer_translate_changed()
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_transform_widget.py:92, in TransformWidget._on_layer_scale_changed(self=<napari_metadata._transform_widget.TransformWidget object>)
90 widgets = self._layer_widgets()
91 for s, w in zip(scale, widgets):
---> 92 w.spacing.setValue(s)
s = 1.0
w = <napari_metadata._transform_widget.TransformRow object at 0x7fd5fb3de3d0>
w.spacing = <napari_metadata._widget_utils.DoubleLineEdit object at 0x7fd69dab9ca0>
File ~/mambaforge/envs/napari-env/lib/python3.9/site-packages/napari_metadata/_widget_utils.py:40, in DoubleLineEdit.setValue(self=<napari_metadata._widget_utils.DoubleLineEdit object>, value=1.0)
38 state, text, _ = self.validator().validate(text, 0)
39 if state != QValidator.State.Acceptable:
---> 40 raise ValueError("Value is invalid.")
41 if text != self.text():
42 super().setText(text)
ValueError: Value is invalid.
Hmm, I don’t know, it works fine here, even checking out 0.4.18.
Could you write down exactly what you did?
I just opened napari, then File > Open Sample > napari builtins > Cells (3D + 2Ch), then Plugins > Layer metadata (napari-metadata).