Code Monkey home page Code Monkey logo

napari-deeplabcut's Introduction

Welcome! 👋

DeepLabCut™️ is a toolbox for state-of-the-art markerless pose estimation of animals performing various behaviors. As long as you can see (label) what you want to track, you can use this toolbox, as it is animal and object agnostic. Read a short development and application summary below.

Please click the link above for all the information you need to get started! Please note that currently we support only Python 3.10+ (see conda files for guidance).

Developers Stable Release:

  • Very quick start: You need to have TensorFlow installed (up to v2.10 supported across platforms) pip install "deeplabcut[gui,tf]" that includes all functions plus GUIs, or pip install deeplabcut[tf] (headless version with PyTorch and TensorFlow).

Developers Alpha Release:

We recommend using our conda file, see here or the new deeplabcut-docker package.

Our docs walk you through using DeepLabCut, and key API points. For an overview of the toolbox and workflow for project management, see our step-by-step at Nature Protocols paper.

For a deeper understanding and more resources for you to get started with Python and DeepLabCut, please check out our free online course! http://DLCcourse.deeplabcut.org

🐭 pose tracking of single animals demo Open in Colab

🐭🐭🐭 pose tracking of multiple animals demo Open in Colab

  • See more demos here. We provide data and several Jupyter Notebooks: one that walks you through a demo dataset to test your installation, and another Notebook to run DeepLabCut from the beginning on your own data. We also show you how to use the code in Docker, and on Google Colab.

Why use DeepLabCut?

In 2018, we demonstrated the capabilities for trail tracking, reaching in mice and various Drosophila behaviors during egg-laying (see Mathis et al. for details). There is, however, nothing specific that makes the toolbox only applicable to these tasks and/or species. The toolbox has already been successfully applied (by us and others) to rats, humans, various fish species, bacteria, leeches, various robots, cheetahs, mouse whiskers and race horses. DeepLabCut utilized the feature detectors (ResNets + readout layers) of one of the state-of-the-art algorithms for human pose estimation by Insafutdinov et al., called DeeperCut, which inspired the name for our toolbox (see references below). Since this time, the package has changed substantially. The code has been re-tooled and re-factored since 2.1+: We have added faster and higher performance variants with MobileNetV2s, EfficientNets, and our own DLCRNet backbones (see Pretraining boosts out-of-domain robustness for pose estimation and Lauer et al 2022). Additionally, we have improved the inference speed and provided both additional and novel augmentation methods, added real-time, and multi-animal support. In v3.0+ we have changed the backend to support PyTorch. This brings not only an easier installation process for users, but performance gains, developer flexibility, and a lot of new tools! Importantly, the high-level API stays the same, so it will be a seamless transition for users 💜! We currently provide state-of-the-art performance for animal pose estimation and the labs (M. Mathis Lab and A. Mathis Group) have both top journal and computer vision conference papers.

Left: Due to transfer learning it requires little training data for multiple, challenging behaviors (see Mathis et al. 2018 for details). Mid Left: The feature detectors are robust to video compression (see Mathis/Warren for details). Mid Right: It allows 3D pose estimation with a single network and camera (see Mathis/Warren). Right: It allows 3D pose estimation with a single network trained on data from multiple cameras together with standard triangulation methods (see Nath* and Mathis* et al. 2019).

DeepLabCut is embedding in a larger open-source eco-system, providing behavioral tracking for neuroscience, ecology, medical, and technical applications. Moreover, many new tools are being actively developed. See DLC-Utils for some helper code.

Code contributors:

DLC code was originally developed by Alexander Mathis & Mackenzie Mathis, and was extended in 2.0 with the core dev team consisting of Tanmay Nath (2.0-2.1), and currently (2.1+) with Jessy Lauer and (2.3+) Niels Poulsen. DeepLabCut is an open-source tool and has benefited from suggestions and edits by many individuals including Mert Yuksekgonul, Tom Biasi, Richard Warren, Ronny Eichler, Hao Wu, Federico Claudi, Gary Kane and Jonny Saunders as well as the 100+ contributors. Please see AUTHORS for more details!

This is an actively developed package and we welcome community development and involvement.

Get Assistance & be part of the DLC Community✨:

🚉 Platform 🎯 Goal ⏱️ Estimated Response Time 📢 Support Squad
Image.sc forum
🐭Tag: DeepLabCut
To ask help and support questions👋 Promptly🔥 DLC Team and The DLC Community
GitHub DeepLabCut/Issues To report bugs and code issues🐛 (we encourage you to search issues first) 2-3 days DLC Team
Gitter To discuss with other users, share ideas and collaborate💡 2 days The DLC Community
GitHub DeepLabCut/Contributing To contribute your expertise and experience🙏💯 Promptly🔥 DLC Team
🚧 GitHub DeepLabCut/Roadmap To learn more about our journey✈️ N/A N/A
Twitter Follow To keep up with our latest news and updates 📢 Daily DLC Team
The DeepLabCut AI Residency Program To come and work with us next summer👏 Annually DLC Team

References:

If you use this code or data we kindly ask that you please cite Mathis et al, 2018 and, if you use the Python package (DeepLabCut2.x) please also cite Nath, Mathis et al, 2019. If you utilize the MobileNetV2s or EfficientNets please cite Mathis, Biasi et al. 2021. If you use versions 2.2beta+ or 2.2rc1+, please cite Lauer et al. 2022.

DOIs (#ProTip, for helping you find citations for software, check out CiteAs.org!):

Please check out the following references for more details:

@article{Mathisetal2018,
    title = {DeepLabCut: markerless pose estimation of user-defined body parts with deep learning},
    author = {Alexander Mathis and Pranav Mamidanna and Kevin M. Cury and Taiga Abe  and Venkatesh N. Murthy and Mackenzie W. Mathis and Matthias Bethge},
    journal = {Nature Neuroscience},
    year = {2018},
    url = {https://www.nature.com/articles/s41593-018-0209-y}}

 @article{NathMathisetal2019,
    title = {Using DeepLabCut for 3D markerless pose estimation across species and behaviors},
    author = {Nath*, Tanmay and Mathis*, Alexander and Chen, An Chi and Patel, Amir and Bethge, Matthias and Mathis, Mackenzie W},
    journal = {Nature Protocols},
    year = {2019},
    url = {https://doi.org/10.1038/s41596-019-0176-0}}
    
@InProceedings{Mathis_2021_WACV,
    author    = {Mathis, Alexander and Biasi, Thomas and Schneider, Steffen and Yuksekgonul, Mert and Rogers, Byron and Bethge, Matthias and Mathis, Mackenzie W.},
    title     = {Pretraining Boosts Out-of-Domain Robustness for Pose Estimation},
    booktitle = {Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision (WACV)},
    month     = {January},
    year      = {2021},
    pages     = {1859-1868}}
    
@article{Lauer2022MultianimalPE,
    title={Multi-animal pose estimation, identification and tracking with DeepLabCut},
    author={Jessy Lauer and Mu Zhou and Shaokai Ye and William Menegas and Steffen Schneider and Tanmay Nath and Mohammed Mostafizur Rahman and     Valentina Di Santo and Daniel Soberanes and Guoping Feng and Venkatesh N. Murthy and George Lauder and Catherine Dulac and M. Mathis and Alexander Mathis},
    journal={Nature Methods},
    year={2022},
    volume={19},
    pages={496 - 504}}

@article{insafutdinov2016eccv,
    title = {DeeperCut: A Deeper, Stronger, and Faster Multi-Person Pose Estimation Model},
    author = {Eldar Insafutdinov and Leonid Pishchulin and Bjoern Andres and Mykhaylo Andriluka and Bernt Schiele},
    booktitle = {ECCV'16},
    url = {http://arxiv.org/abs/1605.03170}}

Review & Educational articles:

@article{Mathis2020DeepLT,
    title={Deep learning tools for the measurement of animal behavior in neuroscience},
    author={Mackenzie W. Mathis and Alexander Mathis},
    journal={Current Opinion in Neurobiology},
    year={2020},
    volume={60},
    pages={1-11}}

@article{Mathis2020Primer,
    title={A Primer on Motion Capture with Deep Learning: Principles, Pitfalls, and Perspectives},
    author={Alexander Mathis and Steffen Schneider and Jessy Lauer and Mackenzie W. Mathis},
    journal={Neuron},
    year={2020},
    volume={108},
    pages={44-65}}

Other open-access pre-prints related to our work on DeepLabCut:

@article{MathisWarren2018speed,
    author = {Mathis, Alexander and Warren, Richard A.},
    title = {On the inference speed and video-compression robustness of DeepLabCut},
    year = {2018},
    doi = {10.1101/457242},
    publisher = {Cold Spring Harbor Laboratory},
    URL = {https://www.biorxiv.org/content/early/2018/10/30/457242},
    eprint = {https://www.biorxiv.org/content/early/2018/10/30/457242.full.pdf},
    journal = {bioRxiv}}

License:

This project is primarily licensed under the GNU Lesser General Public License v3.0. Note that the software is provided "as is", without warranty of any kind, express or implied. If you use the code or data, please cite us! Note, artwork (DeepLabCut logo) and images are copyrighted; please do not take or use these images without written permission.

SuperAnimal models are provided for research use only (non-commercial use).

Major Versions:

  • For all versions, please see here.

VERSION 3.0: A whole new experience with PyTorch🔥. While the high-level API remains the same, the backend and developer friendliness have greatly improved, along with performance gains!

VERSION 2.3: Model Zoo SuperAnimals, and a whole new GUI experience.

VERSION 2.2: Multi-animal pose estimation, identification, and tracking with DeepLabCut is supported (as well as single-animal projects).

VERSION 2.0-2.1: This is the Python package of DeepLabCut that was originally released in Oct 2018 with our Nature Protocols paper (preprint here). This package includes graphical user interfaces to label your data, and take you from data set creation to automatic behavioral analysis. It also introduces an active learning framework to efficiently use DeepLabCut on large experimental projects, and data augmentation tools that improve network performance, especially in challenging cases (see panel b).

VERSION 1.0: The initial, Nature Neuroscience version of DeepLabCut can be found in the history of git, or here: https://github.com/DeepLabCut/DeepLabCut/releases/tag/1.11

News (and in the news):

💜 We released a major update, moving from 2.x --> 3.x with the backend change to PyTorch

💜 The DeepLabCut Model Zoo launches SuperAnimals, see more here.

💜 DeepLabCut supports multi-animal pose estimation! maDLC is out of beta/rc mode and beta is deprecated, thanks to the testers out there for feedback! Your labeled data will be backwards compatible, but not all other steps. Please see the new 2.2+ releases for what's new & how to install it, please see our new paper, Lauer et al 2022, and the new docs on how to use it!

💜 We support multi-animal re-identification, see Lauer et al 2022.

💜 We have a real-time package available! http://DLClive.deeplabcut.org

napari-deeplabcut's People

Contributors

backyardbiomech avatar c-achard avatar hausmanns avatar jeylau avatar mmathislab avatar n-poulsen avatar neslihanedes avatar timokleia avatar yankofelipe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

napari-deeplabcut's Issues

Napari error for manual video frame extraction in DLC

Hi deeplabcut team,

I recently transitioned from the wxpython gui to napari gui with deeplabcut (v. 2.3.5), latest version. Usually, at the stage of deeplabcut.extract_frames(config_path, mode="manual"), I do manual frame extraction of the videos. However, after installing the 2.3.5 version of deeplabcut in a new anaconda environment, whenever I want to manually extract frames from my video, on napari, I go to the top corner, in Files, I click on 'open file(s)', and I get an error on the anaconda terminal.

Now, do note that opening folders is totally fine. For example, if I automatically extract frames, then I can easily use the napari to label the selected frames.

Another question I have is, in wxpython, I was able to use 'Ctrl+C' to copy my previous annotations to the next frame. Is there such a command for napari as well.

Here's the error:
Traceback (most recent call last):
File "C:\ProgramData\Anaconda3\envs\DLC\lib\site-packages\napari_qt\qt_viewer.py", line 735, in _open_files_dialog filenames, _ = dlg.getOpenFileNames(
AttributeError: PySide6.QtWidgets.QFileDialog.getOpenFileNames(): unsupported keyword 'directory' If you suspect this is an IPython 8.12.2 bug, please report it at: https://github.com/ipython/ipython/issues
or send an email to the mailing list at [email protected] You can print a more detailed traceback right now with "%tb", or use "%debug"
to interactively debug it. Extra-detailed tracebacks for bug-reporting purposes can be enabled via:
%config Application.verbose_crash=True

My system versions:
Python 3.8.17
Windows 11
DLC 2.3.5
napari 0.4.17
PySide 6.3.1

Thanks so much for all the kind help!
Let me know if you need more detailed information regarding the error!

error ValueError: cannot call `vectorize` on size 0 inputs unless `otypes` is set

Last night I was able to open all my files just fine in napari-deeplabcut. However, I'm not sure if I accidentally deleted something, but all of a sudden every single folder in this project gives me the error "cannot call vectorize on size 0 inputs unless otypes is set." Other folders stored elsewhere (in another project) seem to open just fine still. Does anyone know what might have happend/how to fix this?

Validation error for ColorManager

When importing a labeled data folder, I get the following error ("a5" below is a body part name):

>>> WARNING: Traceback (most recent call last):
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/_qt/qt_viewer.py", line 754, in _qt_open
    self.viewer.open(
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 941, in open
    layers = self._open_or_raise_error(
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 1064, in _open_or_raise_error
    raise MultipleReaderError(
napari.errors.reader_errors.MultipleReaderError: Multiple plugins found capable of reading /home/grover/Desktop/dockerdir/LiquidFoodDLC-Mehmet-2020-03-23/labeled-data/20211118_Fly39_F_B_SD_6D_9am-11182021165425. Select plugin from {'napari-deeplabcut': 'napari DeepLabCut', 'napari': 'napari (npe2)', 'builtins': 'builtins (npe1)'} and pass to reading function e.g. `viewer.open(..., plugin=...)`.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/_qt/qt_viewer.py", line 1106, in dropEvent
    self._qt_open([filename], stack=bool(shift_down))
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/_qt/qt_viewer.py", line 772, in _qt_open
    handle_gui_reading(filenames, self, stack, **kwargs)
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/_qt/dialogs/qt_reader_dialog.py", line 156, in handle_gui_reading
    open_with_dialog_choices(
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/_qt/dialogs/qt_reader_dialog.py", line 249, in open_with_dialog_choices
    qt_viewer.viewer.open(paths, stack=stack, plugin=plugin_name, **kwargs)
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 931, in open
    self._add_layers_with_plugins(
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 1160, in _add_layers_with_plugins
    added.extend(self._add_layer_from_data(*_data))
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 1234, in _add_layer_from_data
    layer = add_method(data, **(meta or {}))
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/components/viewer_model.py", line 4, in add_points
    import itertools
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/layers/points/points.py", line 433, in __init__
    self._face = ColorManager._from_layer_kwargs(
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/layers/utils/color_manager.py", line 577, in _from_layer_kwargs
    return cls(**color_kwargs)
  File "/home/grover/anaconda3/envs/napari-env/lib/python3.8/site-packages/napari/utils/events/evented_model.py", line 197, in __init__
    super().__init__(**kwargs)
  File "pydantic/main.py", line 341, in pydantic.main.BaseModel.__init__
pydantic.error_wrappers.ValidationError: 1 validation error for ColorManager
__root__
  could not convert string to float: 'a5' (type=value_error)

frame extraction issue

I am having trouble cropping the videos through the GUI. It does nos allow me to even extract the frames in both manual or automatic extraction mode.

When I disable the frame cropping it works.

Multianimal Labelling: Moving to next animal after skipping a bodypart sets GUI back to first bodypart but not in actual labelling

So I have a body parts list:

  • tip
  • middle

I have a list of individuals for multi animal labelling l1, l2, l3, etc ..

I'm on individual l33. I've labelled tip, the 'Keypoint selection' menu looks like this:
image

As I can't see the middle of l33, I will move onto l34 in the menu, and the GUI responds by resetting the body parts to tip:
image

But when I go to label, it will label the point for the middle of l34, the tip of l34 is skipped and the next point to label is l35 tip.

Installation: Missing `PyQt5` package

I installed the plugin as follows:

conda create -n napari python==3.8
conda activate napari
pip install napari-deeplabcut

which gives the error

napari

Traceback (most recent call last):
  File "/home/stes/.conda/envs/napari/bin/napari", line 8, in <module>
    sys.exit(main())
  File "/home/stes/.conda/envs/napari/lib/python3.8/site-packages/napari/__main__.py", line 446, in main
    _run()
  File "/home/stes/.conda/envs/napari/lib/python3.8/site-packages/napari/__main__.py", line 299, in _run
    from napari._qt.widgets.qt_splash_screen import NapariSplashScreen
  File "/home/stes/.conda/envs/napari/lib/python3.8/site-packages/napari/_qt/__init__.py", line 9, in <module>
    from qtpy import API_NAME, QtCore
  File "/home/stes/.conda/envs/napari/lib/python3.8/site-packages/qtpy/QtCore.py", line 15, in <module>
    from PyQt5.QtCore import *
ModuleNotFoundError: No module named 'PyQt5'

--> The setup instructions in the README should be updated in this regard.

This can be fixed by simply running

pip install PyQt5

on my machine. Should this

  • become a dependency of this package?
  • should we update the README accordingly?

Dependencies

Hi @jeylau, when reviewing conda-forge/napari-deeplabcut-feedstock#1

We found that some of the dependencies might not be updated.

Packages found by source code inspection but not in the meta.yaml:

pyyaml
scikit-image

Packages found in the meta.yaml but not found by source code inspection:

pytables
ruamel.yaml

Is this correct?

Perhaps you could update the setup.cfg so the next release includes the correct dependencies.

Cheers!

Missing Keypoint Selection Window

When labeling frames via the DLC GUI on napari I can only label the first keypoint. I am missing the Keypoint Selection Window with the dropdown to select other keypoints as seen in the demo video. Attached is the terminal output when I run napari --info as well as a screenshot of the napari window.

I had issues downloading the DLC GUI on my MacBook w M2 Chip, this is the method that ended up working.

Screenshot 2023-09-18 at 11 47 15 AM
Screenshot 2023-09-18 at 11 49 05 AM

Unable to load h5 from napari into DLC

Hi,

Thank you so much for creating napari. It really speeds up the labeling of images before DLC training. However, it seems that the h5 file produced cannot be read by DLC. I realized the issue might be that the DLC h5 contains the folder names, but the h5 produced by napari only has the file names (see snapshot fo csv below). Is there a way to correct this?

Left h5 from DLC, right h5 from napari.
image

Also just opening a folder containing a .h5 from DLC does not seem to work properly. I need to open the h5 separately as a file before the labels from the DLC gui can appear in napari. Might be the same issue as above though.

Regards,
Gao Xiang Ham

Unable to open frames for labeling

Is there an existing issue for this?

  • I have searched the existing issues

Bug description

When using the DLC GUI I click on the 'Label Frames' tab and then on the 'Label Frames' button. I select which folder I would like to open and a blank napari window opens without any images and the terminal returns the following error message.

I've been trying to debug this myself but am now stuck.

Operating System

operating system: Windows 10

DeepLabCut version

dlc version: 2.3.5

DeepLabCut mode

multi animal

Device type

gpu: NA

Steps To Reproduce

No response

Relevant log output

Starting GUI...
C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\pims\api.py:205: UserWarning: <class 'pims.image_reader.ImageReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
  warn(message)
C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\pims\api.py:205: UserWarning: <class 'pims.image_reader.ImageReaderND'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
  warn(message)
C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\pims\api.py:205: UserWarning: <class 'pims.imageio_reader.ImageIOReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
  warn(message)
Traceback (most recent call last):
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\deeplabcut\gui\tabs\label_frames.py", line 55, in label_frames
    _ = launch_napari(folder)
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\deeplabcut\gui\widgets.py", line 45, in launch_napari
    viewer.open(files, plugin="napari-deeplabcut")
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari\components\viewer_model.py", line 1014, in open
    self._add_layers_with_plugins(
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari\components\viewer_model.py", line 1216, in _add_layers_with_plugins
    layer_data, hookimpl = read_data_with_plugins(
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari\plugins\io.py", line 77, in read_data_with_plugins
    res = _npe2.read(paths, plugin, stack=stack)
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari\plugins\_npe2.py", line 55, in read
    layer_data, reader = io_utils.read_get_reader(
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\npe2\io_utils.py", line 66, in read_get_reader
    return _read(
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\npe2\io_utils.py", line 160, in _read
    read_func = rdr.exec(
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\npe2\manifest\contributions\_readers.py", line 52, in exec
    callable_ = super().exec(kwargs=kwargs)
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\npe2\manifest\utils.py", line 63, in exec
    return self.get_callable(reg)(*args, **kwargs)
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari_deeplabcut\_reader.py", line 74, in get_folder_parser
    layers.extend(read_images(images))
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\napari_deeplabcut\_reader.py", line 102, in read_images
    return [(imread(path), params, "image")]
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\dask_image\imread\__init__.py", line 48, in imread
    with pims.open(sfname) as imgs:
  File "C:\Users\blogeman\anaconda3\envs\DLC\lib\site-packages\pims\api.py", line 207, in open
    raise UnknownFormatError("All handlers returned exceptions:\n" + exceptions)
pims.api.UnknownFormatError: All handlers returned exceptions:
<class 'pims.image_reader.ImageReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
<class 'pims.image_reader.ImageReaderND'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
<class 'pims.imageio_reader.ImageIOReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'

Anything else?

My assumption is that the error is in the way the filepath is being input to pims. However, since I haven't found any other users reporting this error and have no idea what is unique to my setup, I suspect it must be something else. For example, running the following seems to work just fine.

import pims
pims.open('E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\img15288.png')

E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\img15288.png
<Frames>
Length: 1 frames
Frame Shape: 720 x 1280
Pixel Datatype: uint8

However, using the asterisk operator returns the same error as when using the DLC GUI

import pims
pims.open('E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png')

E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png
---------------------------------------------------------------------------
UnknownFormatError                        Traceback (most recent call last)
Cell In[4], line 1
----> 1 pims.open('E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png')

File ~\anaconda3\envs\DLC\lib\site-packages\pims\api.py:207, in open(sequence, **kwargs)
    205         warn(message)
    206         exceptions += message + '\n'
--> 207 raise UnknownFormatError("All handlers returned exceptions:\n" + exceptions)

UnknownFormatError: All handlers returned exceptions:
<class 'pims.image_reader.ImageReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
<class 'pims.image_reader.ImageReaderND'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'
<class 'pims.imageio_reader.ImageIOReader'> errored: No such file: 'E:\Manipulation_Videos\Adults-BL-2023-06-25\labeled-data\Father_01_Ar-floxed\*.png'

Code of Conduct

Keypoint annotation changing when labeling - Multi Animal

Dear awesome people who are working on napari-deeplabcut. First off thank you! Napari runs on my computer so smoothly while the DLC GUI crashes.

I have been labelling field of worms (<200 individuals). Sometimes I mess up and have to delete an annotation. When I do this using the pointer tool and then start re-annotating the sequence of annotations gets bumped forwards once from what I am expecting. Sometimes. Manually setting which annotation I am on does not prevent this behavior. If I delete multiple previous annotations and then click off the image, then manually enter what my annotation is, it seems to work correctly.

Cheers and thanks! keep up the good work. the DLC GUI lights my computer on fire when annotating hundreds of individuals while napari-deeplabcut just hums along easily.

fails to find yaml package

Bug

plugin fails to install with current instructions:

pip install git+https://github.com/DeepLabCut/napari-deeplabcut.git

traceback:

❯ pip install git+https://github.com/DeepLabCut/napari-deeplabcut.git
Collecting git+https://github.com/DeepLabCut/napari-deeplabcut.git
  Cloning https://github.com/DeepLabCut/napari-deeplabcut.git to /private/var/folders/ct/4w_vk2wn10xb_xj2fm7d6vqc0000gn/T/pip-req-build-pkqdoi73
  Running command git clone -q https://github.com/DeepLabCut/napari-deeplabcut.git /private/var/folders/ct/4w_vk2wn10xb_xj2fm7d6vqc0000gn/T/pip-req-build-pkqdoi73
  Resolved https://github.com/DeepLabCut/napari-deeplabcut.git to commit 5df8144e34c3f4189ff37ebf415f8489e1a81c48
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
ERROR: Could not find a version that satisfies the requirement yaml (from napari-deeplabcut) (from versions: none)
ERROR: No matching distribution found for yaml

Suggestion:

replace yaml --> ruamel.yaml

Other info:

  • python 3.8
  • macOS monterey 12.1
  • fresh napari install ... napari-0.4.16 napari-console-0.0.4 napari-plugin-engine-0.2.0 napari-svg-0.1.6

Bodypart dropbox should update which bodypart is labeled

I think the dropbox should change to show the next point that will be labeled, and changing the dropbox should change the next point to be labeled

Video shows me selecting a bodypart in the dropdown then labeling, but a different bodypart is added
https://user-images.githubusercontent.com/75952206/189493334-13ba3efb-874b-49f6-9512-3fe2a1d5e3e9.mp4

Enjoying the new UI! Just being able to use basic hotkeys and c+p datapoints is already speeding things up a lot.

How to trail more than 4 points

After we run the testing script (in /DeepLabCut/examples/testscript) to test if we have already installed the 'deeplabcut' package successfully, we can get a sample directory named as 'TEST-Alex-(date)'. Open the directory named 'labeled-data' and continuously open one of its subdirectories we can see a csv file. this csv file shows that only data of 4 points (body part 1, body part 2, body part 3, Object A) can be saved.

However, Lauer et al 2022 has shown that we can actually trail more than 4 body parts simultaneously. When we first open a directory we get 2 layers (1 is for background image and 1 is specifically built for lable 4 points and cannot change the max number of points that can be label in this layer, I refer this layer as 'default layer' for convience). To label more points, I have to make up a new layer and in this newly made layer (named as 'additive layer') I can label other points without restricting, that is, I can label another 5, 6, 7...points if I want. But we cannot add more points at the default layer. I'm not sure if there may be some buttons or functions (which have already been developed) that I ignored.

I met a error when I save the different layer. I can save the default layer successfully, just like what I expect. but I cannot use ctrl+S to save the additive layer, and when I click "File > Save Selected Layer(s)", it reports an error and the GUI window closed suddenly. So I cannot save the labeled data in additive layer, and thus cannot using this method to trail more than 4 points.

I wonder how to do this?

Napari not responding when asked to label frames in deeplabcut

Hi, I'm having trouble getting Napari to label frames in deeplabcut.

Everything goes well up to

deeplabcut.label_frames('/Users/bjm/Desktop/videos_cr/chrv12-7/test-BJM-2023-05-19/config.yaml')

Napari opens but the rainbow wheel keeps turning with nothing happening and the icon reports "Application Not Responding", so I am not even able to select the frame files to label.

I'm on a MacBook Pro, 13-inch M1, 2020 running macOS Ventura 13.3.1(a).
I installed deeplabcut according to developer instructions without issues.
Python is up to date:

Python 3.9.16 | packaged by conda-forge | (main, Feb  1 2023, 21:38:11) 
[Clang 14.0.6 ] on darwin

I also re-installed Napari for deeplabcut following its website instructions.

Help would be appreciated.
Cheers,
BM

Display body part coloring scheme

Can be a color bar (as in DeepLabCut's labeling GUI), or something prettier (like matplotlib.Patches alone) embedded in the dock widget.

Improve error message for when file name in the output h5 file does not match the folder directory

I had labelled some images using Napari under a particular folder. I then saved the file but renamed the folder another day to distinguish my progress. However, when I tried to open the folder again on Napari, none of the labels showed up. After a long time debugging, it was found that it was because the output h5 file stored the original folder name so that when I renamed the folder, it could no longer find the images. This is unintuitive as the images and h5 files are stored in the same folder and it was assumed that everything should have just been called from the current directory. The error message that popped up was:

ValueError: cannot call vectorizeon size 0 inputs unlessotypes is set

It would be more clear if the error message could be:

Directory not found

I am using napari-deeplab v0.2.0 on windows with python 3.9.

validation error for ColorManager

I am trying to open a folder of labels (that opens fine in the old DLC outlier refinement GUI) and I am getting the error below.
The weird thing is that I was able to open that folder and label images fine in the first attempt to use it. I then saved the layer and wanted to continue where I left yesterday, and now this error shows up.

Interestingly, I am also unable to open any other folder of labels that I did before. Giving the same error.

It looks similar to this issue: #23 even though there are differences.

(the full traceback is here : https://pastecode.io/s/jrggoj23)

    420 color_properties = (
    421     self.properties if self._data.size > 0 else self.property_choices
    422 )
    423 self._edge = ColorManager._from_layer_kwargs(
    424     n_colors=len(data),
    425     colors=edge_color,
   (...)
    429     properties=color_properties,
    430 )
--> 431 self._face = ColorManager._from_layer_kwargs(
        self = <Points layer 'CollectedData_ZeroNoiseLab' at 0x7fd5a4403fa0>
        ColorManager = <class 'napari.layers.utils.color_manager.ColorManager'>
        data = <class 'numpy.ndarray'> (2531, 3) float64
        face_color = 'label'
        face_colormap = 'viridis'
        face_contrast_limits = None
        face_color_cycle = <class 'numpy.ndarray'> (58, 4) float64
        color_properties = {'label': <class 'numpy.ndarray'> (2531,) object, 'id': <class 'numpy.ndarray'> (2531,) object, 'likelihood': <class 'numpy.ndarray'> (2531,) float64, 'valid': <class 'numpy.ndarray'> (2531,) bool}
    432     n_colors=len(data),
    433     colors=face_color,
    434     continuous_colormap=face_colormap,
    435     contrast_limits=face_contrast_limits,
    436     categorical_colormap=face_color_cycle,
    437     properties=color_properties,
    438 )
    440 if n_dimensional is not None:
    441     self._out_of_slice_display = n_dimensional

File ~/.conda/envs/napari/lib/python3.9/site-packages/napari/layers/utils/color_manager.py:577, in ColorManager._from_layer_kwargs(cls=<class 'napari.layers.utils.color_manager.ColorManager'>, colors='label', properties={'id': <class 'numpy.ndarray'> (2531,) object, 'label': <class 'numpy.ndarray'> (2531,) object, 'likelihood': <class 'numpy.ndarray'> (2531,) float64, 'valid': <class 'numpy.ndarray'> (2531,) bool}, n_colors=2531, continuous_colormap='viridis', contrast_limits=None, categorical_colormap=<class 'numpy.ndarray'> (58, 4) float64, color_mode=<ColorMode.COLORMAP: 'colormap'>, current_color=None, default_color_cycle=<class 'numpy.ndarray'> (4,) int64)
    569 else:
    570     color_kwargs.update(
    571         {
    572             'color_mode': color_mode,
    573             'color_properties': color_properties,
    574         }
    575     )
--> 577 return cls(**color_kwargs)
        color_kwargs = {'categorical_colormap': <class 'numpy.ndarray'> (58, 4) float64, 'continuous_colormap': 'viridis', 'contrast_limits': None, 'current_color': None, 'n_colors': 2531, 'color_mode': <ColorMode.COLORMAP: 'colormap'>, 'color_properties': ColorProperties(name='label', values=<class 'numpy.ndarray'> (2531,) object, current_value=None)}
        cls = <class 'napari.layers.utils.color_manager.ColorManager'>

File ~/.conda/envs/napari/lib/python3.9/site-packages/napari/utils/events/evented_model.py:196, in EventedModel.__init__(self=ColorManager(), **kwargs={'categorical_colormap': <class 'numpy.ndarray'> (58, 4) float64, 'color_mode': <ColorMode.COLORMAP: 'colormap'>, 'color_properties': ColorProperties(name='label', values=<class 'numpy.ndarray'> (2531,) object, current_value=None), 'continuous_colormap': 'viridis', 'contrast_limits': None, 'current_color': None, 'n_colors': 2531})
    195 def __init__(self, **kwargs):
--> 196     super().__init__(**kwargs)
        kwargs = {'categorical_colormap': <class 'numpy.ndarray'> (58, 4) float64, 'continuous_colormap': 'viridis', 'contrast_limits': None, 'current_color': None, 'n_colors': 2531, 'color_mode': <ColorMode.COLORMAP: 'colormap'>, 'color_properties': ColorProperties(name='label', values=<class 'numpy.ndarray'> (2531,) object, current_value=None)}
    198     self._events.source = self
    199     # add event emitters for each field which is mutable

File ~/.conda/envs/napari/lib/python3.9/site-packages/pydantic/main.py:342, in pydantic.main.BaseModel.__init__()

ValidationError: 1 validation error for ColorManager
__root__
  could not convert string to float: 'Brow_MidPoint' (type=value_error)

How to add additional body part labels?

Hi,

I have a few videos that I've already labeled in the napari GUI. Now, I want to add an additional body part label to the videos. I edited config.yaml with the new body part; however, when I go to add it to the videos, it doesn't show up in napari's list of labels. Is there anything I need to do to make the new labels show up in napari?

EDIT: I am using the latest commit on DeepLabCut's github repository as of June 14. Tried on both macOS 13 Ventura and Windows 10 22H2.

Thanks!

Cannot run any cell of Jupyter Notebook after save and close Napari

Hi everyone.
I'm using napari for deeplabcut.
After using the function "dlc.label_frames(config_path)", the napari came out, and I resumed the labeling and saved the layer with label. Then I closed the napari. Seems everything goes well.
But when I tried to re-open napari and continue the labeling, I find out that non of the cell in the Jupyter cannot run. I have to restart Jupyter.
image
It was stuck like this.

Any advice?
Thanks a lot.

napari-dlc can not handle 200k+ frames videos during manual frame extraction

Hi DLC developer! I am recording video at 60 Hz for 1 h. I was not able to use napari to manually extract frames (freezes for minute every move of slide-bar). DLC=2.3.7, Ubuntu 22.04. The manual extraction GUI is working fine in DLC 2.1.8.2. Can you briefly confirm on your side with a large frame number video if it's OS related issue or napari itself. Thank you!
Ziyan

Incorrect comparison of images and the final markup file in h5 format

Discussed in #61

Originally posted by Tanya16181618 February 9, 2023
Hi all!
I am using dlc version 2.3.0.
I came across the fact that in napari I have an incorrect match between the name of the photo and the markup itself in the h5 and csv file. Because of this, in my opinion, the neural network does not learn from me at all and I get bad results.
Attached is an example of such markup from the labled_data folder. For example, for photo 10.png there corresponds line 13 and photo 18.png. I calculated it so the results began to deteriorate, I began to check the markup. Moreover, in the graphical editor, the points are marked correctly, but not in the file. Tell me what can be done about it?
3_Problem.zip

refine_labels on Windows not working after inference on Linux

Hi,

I would like to point out an issue when new videos are analysed on a Linux-driven machine, but outlier frames are extracted and the labels refined on a Windows machine.

I will first describe the workflow I used to train a model with minimal resources:

  1. Label frames on Windows machine.
  2. Port project to Azure compute, which runs Ubuntu.
  3. Create test/train datasets and train a model.
  4. Analyze both videos that were part of the project and new videos.
  5. Port the project and new analyzed videos back to Windows machine.
  6. Extract outlier frames for all videos, both part of the project and the 'new' videos in a folder outside of the project folder.
  7. Refine labels.

For each 'port', I ensured that the project_path was properly set. Now, when I try to save the refined layer, I get an error as the config file cannot be found:

Traceback (most recent call last):
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari_deeplabcut_widgets.py", line 207, in
lambda: _save_layers_dialog(
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari_deeplabcut_widgets.py", line 94, in _save_layers_dialog
self.viewer.layers.save("", selected=True, plugin="napari-deeplabcut")
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari\components\layerlist.py", line 476, in save
return save_layers(path, layers, plugin=plugin, _writer=_writer)
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari\plugins\io.py", line 229, in save_layers
_written, writer_name = _write_single_layer_with_plugins(
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari\plugins\io.py", line 442, in _write_single_layer_with_plugins
written_paths, writer_name = _npe2.write_layers(
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari\plugins_npe2.py", line 101, in write_layers
paths, writer = io_utils.write_get_writer(
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\npe2\io_utils.py", line 115, in write_get_writer
return _write(path, layer_data, plugin_name=plugin_name, return_writer=True)
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\npe2\io_utils.py", line 224, in _write
res = writer.exec(args=args)
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\npe2\manifest\utils.py", line 62, in exec
return self.get_callable(_registry)(*args, **kwargs)
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari_deeplabcut_writer.py", line 65, in write_hdf
config = _load_config(os.path.join(project_folder, "config.yaml"))
File "C:\Users\NielsW\AppData\Local\miniconda3\envs\bradykinesia\lib\site-packages\napari_deeplabcut_reader.py", line 153, in _load_config
with open(config_path) as file:
FileNotFoundError: [Errno 2] No such file or directory: 'C:/Users/NielsW/Documents/Research Project/Bradykinesia-NielsW-2023-03-08/labeled-data/PD2_4_L_ON\config'

This must be since somewhere the DLCHeader is constructed on Ubuntu and the current method to split the last two directories from the root path relies on the path separators of the currently used OS. I have an easy fix that solves this issue, but I'm not well-versed with GitHub so I'm uncertain how to make a pull request. My proposal is as follows:

in _writer.py, line 65 was:
project_folder = root.rsplit(os.sep, 2)[0]

I propose to replace it with:
project_folder = os.path.dirname(os.path.dirname(root))

Maybe I'm overlooking some problems this might create, or I did something wrong when trying to port the project. My apologies if this issue is already addressed. I use napari-deeplabcut 0.0.9

Some issues when labeling the data

When our collaborator labeled the data, they meet some issues with the GUI:

When doing the labeling with Napari, if I save by choosing 'save all layers', the app crashes and closes. It seems to do it fine when I choose 'save current layer'.

poor/confusing workflow for saving data ?

Fix needed for saving. ...

Right now saving is painfully slow because it's manual. I don't quite understand the workflow; I open a DLC labeled-data folder (single folder). I either add points, or let's say I open the demo mont blanc data, move a point around and click ctrl+S; I then get a dialog box, whereas this should autosave into the H5 + CSV!

Screen Shot 2022-06-03 at 12 44 40 AM

Even more confusing, I "saved" a CollectedData_test to check what was happening, but it does not save, and rather the files are updated? The file choices are also very confusing ... can we NOT have this pop up for dlc projects that already have a CSV/H5?

Keypoint Identity Mismatch

It seems the labelling GUI is sporadically switching the identity of keypoints ex:
DLC Napari issue
In the example, the 'Keypoint selection' indicates the orange point is "tailbase", whereas the 'Color scheme reference' indicates that orange is "back left". I had labelled 9 other folders where the 'Keypoint selection' matched the 'Color scheme reference', but then for this folder it got mixed up. When I exited (without saving) and reopened the folder, the color scheme and keypoint selection were in agreement again.

Extract outlier frames Error

I'm getting the following error when trying to extract outlier frames (deeplabcut version 2.3.3, pandas version 2.0.0). This seems to be from a change in pandas 2.0.0 because it works fine when I downgrade to pandas 1.5.3

File ~.conda\envs\DEEPLABCUT\lib\site-packages\deeplabcut\refine_training_dataset\outlier_frames.py:408, in extract_outlier_frames(config, videos, videotype, shuffle, trainingsetindex, outlieralgorithm, frames2use, comparisonbodyparts, epsilon, p_bound, ARdegree, MAdegree, alpha, extractionalgorithm, automatic, cluster_resizewidth, cluster_color, opencv, savelabeled, copy_videos, destfolder, modelprefix, track_method)
406 temp_dt = df_temp.diff(axis=0) ** 2
407 temp_dt.drop("likelihood", axis=1, level="coords", inplace=True)
--> 408 sum_ = temp_dt.sum(axis=1, level=1)
409 ind = df_temp.index[(sum_ > epsilon**2).any(axis=1)].tolist()
410 Indices.extend(ind)

...

TypeError: sum() got an unexpected keyword argument 'level'

machine labels do not match up with napari images.

Hi,

I also noticed that when loading machinelabels.csv with napari, the labels do not line up with the images, as the extracted points from DLC are not in image order, but the images loaded are. Here is an illustration (below). Notice that the order of frames is not sorted in the csv, resulting in misalignment when loaded into napari.

image

extract_frames error

Hi, I'm new to deeplabcut and am getting stuck with the extract_frames command. I have created a project with one .avi video file and have not modified the config.yaml file. When manually extracting frames napari opens but when I try to open files I encounter the following errors:

In [3]: deeplabcut.extract_frames(config_path, ‘manual’)
Installed qt6 event loop hook.
WARNING: DirectWrite: CreateFontFaceFromHDC() failed (Indicates an error in an input file such as a font file.) for QFontDef(Family=“MS Sans Serif”, pointsize=12, pixelsize=16, styleHint=5, weight=400, stretch=100, hintingPreference=0) LOGFONT(“MS Sans Serif”, lfWidth=0, lfHeight=-16) dpi=144

Traceback (most recent call last):
File “C:\Users\FG\anaconda3\envs\deeplabcut\lib\site-packages\napari_qt\qt_viewer.py”, line 735, in _open_files_dialog
filenames, _ = dlg.getOpenFileNames(
AttributeError: PySide6.QtWidgets.QFileDialog.getOpenFileNames(): unsupported keyword ‘directory’

This is the error message from opening the labeled-data folder:
OSError: No supported images were found.

There is also an error when automatically running extract_frames:

File C:\Users\FG\anaconda3\envs\deeplabcut\lib\site-packages\deeplabcut\generate_training_dataset\frame_extraction.py:273, in extract_frames(config, mode, algo, crop, userfeedback, cluster_step, cluster_resizewidth, cluster_color, opencv, slider_width, config3d, extracted_cam, videos_list)
271 elif mode == "automatic":
272 config_file = Path(config).resolve()
--> 273 cfg = auxiliaryfunctions.read_config(config_file)
274 print("Config file read successfully.")
276 numframes2pick = cfg["numframes2pick"]

File C:\Users\FG\anaconda3\envs\deeplabcut\lib\site-packages\deeplabcut\utils\auxiliaryfunctions.py:210, in read_config(configname)
206 else:
207 raise FileNotFoundError(
208 "Config file is not found. Please make sure that the file exists and/or that you passed the path of the config file correctly!"
209 )
--> 210 return cfg

UnboundLocalError: local variable 'cfg' referenced before assignment

Please let me know if you have any suggestions!

Copying labels from one frame to another in napari

Hello, I am having problems to copy several labels from one frame to another using the new napari based labeling gui. I am trying to select the labels and copy-paste (ctrl-c, ctrl-v) some of the labels (of static objects) for all the frames in a video but even though single points can sometimes be copied to a different layer, it mostly does not work. Is there maybe another way to do this correctly?
I am using the newest version of DLC on Windows 10 without a GPU (just to label the frames).

Thanks a lot already for your help!
Milan

This is the error message I get when trying to copy the labels:

Traceback (most recent call last):
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\vispy\app\backends_qt.py", line 561, in keyPressEvent
self._keyEvent(self._vispy_canvas.events.key_press, ev)
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\vispy\app\backends_qt.py", line 622, in _keyEvent
func(native=ev, key=key, text=str(ev.text()), modifiers=mod)
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\vispy\util\event.py", line 453, in call
self._invoke_callback(cb, event)
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\vispy\util\event.py", line 471, in _invoke_callback
_handle_exception(self.ignore_callback_errors,
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\vispy\util\event.py", line 469, in _invoke_callback
cb(event)
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\utils\key_bindings.py", line 545, in on_key_press
self.press_key(combo)
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\utils\key_bindings.py", line 470, in press_key
generator_or_callback = func()
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\layers\points_points_key_bindings.py", line 64, in copy
layer._copy_data()
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\layers\points\points.py", line 1976, in _copy_data
'text': self.text._copy(index),
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\layers\utils\text_manager.py", line 215, in _copy
'color': _get_style_values(self.color, indices),
File "C:\Users...\anaconda3\envs\DEEPLABCUT\lib\site-packages\napari\layers\utils\style_encoding.py", line 289, in _get_style_values
return values if values.ndim == value_ndim else values[indices]
IndexError: index 4 is out of bounds for axis 0 with size 4

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.