Skip to content

issue with tensor types #3505

Closed

Description

@bryantkg

Is there an existing issue for this?

  • I have searched the existing issues

Operating System

linux

DeepLabCut version

3.0.1

What engine are you using?

pytorch

DeepLabCut mode

single animal

Device type

RTX A4000

Bug description 🐛

Hello - we downloaded/updated to the newest version of deeplabcut and keep getting this error "'>' not supported between instances of 'Tensor' and 'NoneType'" that we didnt get before/don't get with a back-up of our older deeplabcut version. We are running into this issue whenever we try to train a new model or run a model on new videos.

Steps To Reproduce

No response

Relevant log output

Anything else?

No response

Code of Conduct

Activity

  1. added theissue type on Sep 11, 2026
  2. added
    more-data-requested-by-us
    on Sep 11, 2026
  3. C-Achard commented on Sep 11, 2026

    @C-Achard
    Member

    Hello @bryantkg,

    Thanks for the report; would you be able to share the relevant traceback from the terminal?

    There are several such comparisons in the code and knowing which file and line is raising this would be very helpful.

    If you have time, it would also be helpful to share:

    • Which previous version does work for you
    • Whether it is the same traceback between training and analysis
    • Your pytorch_config.yaml for this training run (in <project_path>/dlc-models-pytorch/iteration-<N>/<Task><date>-trainset<XX>shuffle<S>/train/pytorch_config.yaml)

    Thanks and best,
    Cyril

  4. bryantkg commented on Sep 11, 2026

    @bryantkg
    Author

    The previous version which worked for us was v.3.0.0rc10, though now we get a "missing matplotlib" error when trying to use the old version on our backup conda environment before we updated to the newer release.

    It is the same error whether we are doing training or analysis.

    Image

    pytorch_config.yaml

    Thanks!

  5. removed
    more-data-requested-by-us
    on Sep 14, 2026
  6. C-Achard commented on Sep 14, 2026

    @C-Achard
    Member

    Note: I suspect this was flagged and fixed in #3470 already, confirming first

  7. C-Achard commented on Sep 14, 2026

    @C-Achard
    Member

    Thanks for sharing the error @bryantkg!

  8. C-Achard commented on Sep 14, 2026

    @C-Achard
    Member

    Okay, I can confirm this was fixed in #3470 and #3475, which will be shipped in the upcoming 3.0.2.

    In the meantime, there's a workaround for this: add the following to your pytorch config YAML

    detector:
      model:
        type: FasterRCNN
        # ...
        variant: fasterrcnn_mobilenet_v3_large_fpn
        box_score_thresh: 0.01 # <- add this entry

    This should immediately resolve the error, just two things to know:

    • Re-running create_training_dataset will drop the edit
    • If the edit is rejected make sure it is correctly indented so it is under detector.model

    Let me know if you have any questions.

    Best,
    Cyril

  9. bryantkg commented on Sep 14, 2026

    @bryantkg
    Author

    Its now working as expected with this fix - we'll be sure to update to 3.0.2 when it releases. Thank you!!

  10. C-Achard commented on Sep 15, 2026

    @C-Achard
    Member

    (Leaving open until release so others can find the workaround)

    Thanks again @bryantkg! Please let us know if you encounter any other problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions