No label appears

Hi. I’m using Deeplabcut2.0 GUI under the ubuntu with GPU.

ZeroDivisionError: float division by zero

(main.py:3054): Gtk-WARNING **: 16:17:31.865: Negative content height -11 (allocation 1, extents 6x6) while allocating gadget (node button, owner GtkButton)

I’ve got this message with the problem that no label appearing in the lable frame session.
Could help me out?
Thans

Dear @Eunee_Lee,

could you please post more details of the error message? In what step does this appear? [Perhaps it is related to: https://github.com/AlexEMG/DeepLabCut/issues/557 or https://github.com/AlexEMG/DeepLabCut/issues/430]

Alexander

Thanks for the help
When I execute extract frame, I’ve got this error message.

Starting GUI…
Config file read successfully.
Traceback (most recent call last):
File “/home/eunee/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/gui/extract_frames.py”, line 176, in extract_frames
deeplabcut.extract_frames(self.config,mode,algo,crop=False,userfeedback=userfeedback,cluster_step=self.cluster_step.GetValue(),cluster_resizewidth=30,cluster_color=False,opencv=opencv,slider_width=slider_width)
File “/home/eunee/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/generate_training_dataset/frame_extraction.py”, line 140, in extract_frames
duration=nframes*1./fps
ZeroDivisionError: float division by zero

Thanks in advance

so this:

nframes*1./fps
ZeroDivisionError: float division by zero

is causing the error, i.e. the metadata from your video cannot be read correctly.
Please be sure the video is not corrupt.

We added a new check in the code, https://github.com/AlexEMG/DeepLabCut/pull/558 which is in deeplabcut 2.1.6.1, so please upgrade your package as well. You can run pip install --upgrade deeplabcut inside your env.

Really I appreciate your reply.
I upgraded the deeplabcut.
but same ZeroDivisionError occurs.
I found no label appears still. and this is what I’ve got during label frame.
Thanks

(dlc-ubuntu-GPU) eunee@eunee-desktop:~$ python -m deeplabcut
/home/eunee/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/statsmodels/tools/_testing.py:19: FutureWarning: pandas.util.testing is deprecated. Use the functions in the public API at pandas.testing instead.
import pandas.util.testing as tm
Starting GUI…
Created “/home/eunee/deeplabcut test-ss-2020-02-18/videos”
Created “/home/eunee/deeplabcut test-ss-2020-02-18/labeled-data”
Created “/home/eunee/deeplabcut test-ss-2020-02-18/training-datasets”
Created “/home/eunee/deeplabcut test-ss-2020-02-18/dlc-models”
Creating the symbolic link of the video
Created the symlink of /media/eunee/새 볼륨/영상/2020-01-28_immune_Cohort-1_TC/Booth 8/TV_CAM_장치_20200128_162745.avi to /home/eunee/deeplabcut test-ss-2020-02-18/videos/TV_CAM_장치_20200128_162745.avi
/home/eunee/deeplabcut test-ss-2020-02-18/videos/TV_CAM_장치_20200128_162745.avi
Generated “/home/eunee/deeplabcut test-ss-2020-02-18/config.yaml”

A new project with name deeplabcut test-ss-2020-02-18 is created at /home/eunee and a configurable file (config.yaml) is stored there. Change the parameters in this file to adapt to your project’s needs.
Once you have changed the configuration file, use the function ‘extract_frames’ to select frames for labeling.
. [OPTIONAL] Use the function ‘add_new_videos’ to add new videos to your project (at any stage).
Project “/home/eunee/deeplabcut test-ss-2020-02-18” already exists!
Traceback (most recent call last):
File “/home/eunee/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/gui/create_new_project.py”, line 269, in create_new_project
page3 = Extract_frames(self.parent,self.gui_size,self.cfg)
File “/home/eunee/anaconda3/envs/dlc-ubuntu-GPU/lib/python3.6/site-packages/deeplabcut/gui/extract_frames.py”, line 50, in init
self.sel_config.SetPath(self.config)
TypeError: FilePickerCtrl.SetPath(): argument 1 has unexpected type ‘NoneType’
Created “/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/videos”
Created “/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/labeled-data”
Created “/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/training-datasets”
Created “/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/dlc-models”
Creating the symbolic link of the video
Created the symlink of /media/eunee/새 볼륨/영상/2020-01-28_immune_Cohort-1_TC/Booth 8/TV_CAM_장치_20200128_162745.avi to /home/eunee/Desktop/deeplabcut test-ss-2020-02-18/videos/TV_CAM_장치_20200128_162745.avi
/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/videos/TV_CAM_장치_20200128_162745.avi
Generated “/home/eunee/Desktop/deeplabcut test-ss-2020-02-18/config.yaml”

A new project with name deeplabcut test-ss-2020-02-18 is created at /home/eunee/Desktop and a configurable file (config.yaml) is stored there. Change the parameters in this file to adapt to your project’s needs.
Once you have changed the configuration file, use the function ‘extract_frames’ to select frames for labeling.
. [OPTIONAL] Use the function ‘add_new_videos’ to add new videos to your project (at any stage).
Config file read successfully.
Extracting frames based on kmeans …
Kmeans-quantization based extracting of frames from 0.0 seconds to 602.82 seconds.
Extracting and downsampling… 18067 frames from the video.
18067it [00:07, 2512.09it/s]
Kmeans clustering … (this might take a while)

Frames were selected.
You can now label the frames using the function ‘label_frames’ (if you extracted enough frames for all videos).

(main.py:26818): Gtk-WARNING **: 12:26:37.138: Negative content height -11 (allocation 1, extents 6x6) while allocating gadget (node button, owner GtkButton)

(main.py:26818): Gtk-WARNING **: 12:26:37.138: Negative content height -11 (allocation 1, extents 6x6) while allocating gadget (node button, owner GtkButton)

(main.py:26818): Gtk-WARNING **: 12:26:37.138: Negative content height -11 (allocation 1, extents 6x6) while allocating gadget (node button, owner GtkButton)

(main.py:26818): Gtk-WARNING **: 12:26:37.138: Negative content height -11 (allocation 1, extents 6x6) while allocating gadget (node button, owner GtkToggleButton)

I don’t know what you mean by no label appears; you need to RIGHT click to add a label in the GUI (see HELP button). The errors you post are only related to you trying to re-create the same project twice

Project “/home/eunee/deeplabcut test-ss-2020-02-18” already exists!

Also, special characters I don’t believe are supported…

/media/eunee/새 볼륨/영상/2020-01-28_immune_Cohort-1_TC/Booth 8/TV_CAM_장치_20200128_162745.avi