Skip to content

AttributeError: module 'numpy' has no attribute 'int'. #2375

@kkatugam

Description

@kkatugam

Is there an existing issue for this?

  • I have searched the existing issues

Bug description

Attempting to run multi-animal tracking with analyze_videos, keep getting the following error message:

Traceback (most recent call last):
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\gui\utils.py", line 22, in run
    self.func()
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\predict_videos.py", line 640, in analyze_videos
    convert_detections2tracklets(
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\predict_videos.py", line 1873, in convert_detections2tracklets
    trackingutils.fill_tracklets(
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\lib\trackingutils.py", line 761, in fill_tracklets
    tracklet_id, pred_id = content[-2:].astype(np.int)
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\numpy\__init__.py", line 305, in __getattr__
    raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'int'.

Operating System

Windows 11

DeepLabCut version

dlc version 2.3.5

DeepLabCut mode

multi animal

Device type

gpu RTX 3080 laptop

Steps To Reproduce

  1. With a top-down multi-animal project
  2. 4 markers per animal per frame, ~15 animals per video
individuals:
- bird01
- bird02
- bird03
- bird04
- bird05
- bird06
- bird07
- bird08
- bird09
- bird10
- bird11
- bird12
- bird13
- bird14
- bird15
uniquebodyparts: []
multianimalbodyparts:
- head
- shoulder
- tailbase
- tailend
bodyparts: MULTI!

    # Fraction of video to start/stop when extracting frames for labeling/refinement
start: 0
stop: 1
numframes2pick: 20

    # Plotting configuration
skeleton:
- - head
  - shoulder
- - shoulder
  - tailbase
- - tailbase
  - tailend
skeleton_color: white
pcutoff: 0.6
dotsize: 12
alphavalue: 0.7
colormap: rainbow

    # Training,Evaluation and Analysis configuration
TrainingFraction:
- 0.95
iteration: 0
default_net_type: dlcrnet_ms5
default_augmenter: multi-animal-imgaug
default_track_method: ellipse
snapshotindex: -1
batch_size: 8

    # Cropping Parameters (for analysis and outlier frame detection)
cropping: false
    #if cropping is true for analysis, then set the values here:
x1: 0
x2: 640
y1: 277
y2: 624

    # Refinement configuration (parameters from annotation dataset configuration also relevant in this stage)
corner2move2:
- 50
- 50
move2corner: true
  1. Run analyze_videos from GUI
  2. See attribute error

Relevant log output

Traceback (most recent call last):
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\gui\utils.py", line 22, in run
    self.func()
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\predict_videos.py", line 640, in analyze_videos
    convert_detections2tracklets(
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\predict_videos.py", line 1873, in convert_detections2tracklets
    trackingutils.fill_tracklets(
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\deeplabcut\pose_estimation_tensorflow\lib\trackingutils.py", line 761, in fill_tracklets
    tracklet_id, pred_id = content[-2:].astype(np.int)
  File "C:\Users\kavya\anaconda3\envs\snakes\lib\site-packages\numpy\__init__.py", line 305, in __getattr__
    raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'int'.

Anything else?

No response

Code of Conduct

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions