Skip to content

Conversation

anujonthemove
Copy link
Contributor

Description

In the predict section of the Readme.md file, there is a minor issue/typo.

The optimize_for_inference() method was being assigned back to the model variable. After running through the codebase, I found out that this method modifies the model in-place and doesn't return the initialized and optimized model. This was causing the model variable to become None when we try to use model.predict() method.

Type of change

  • This change requires a documentation update

How has this change been tested, please provide a testcase or example of how you tested the change?

No specific test case(s) required.

Any specific deployment considerations

No

Docs

  • Docs updated? What were the changes:
  • I have fixed the typo in the readme file. Now when we try to use the code under the predict section, it works.

The optimize_for_inference() method was being assigned back to the model variable, but this method modifies the model in-place and doesn't return the model. This was causing the model to become `None`. Now when we try to use the predict method, it works.
@CLAassistant
Copy link

CLAassistant commented Jul 25, 2025

CLA assistant check
All committers have signed the CLA.

@isaacrob-roboflow isaacrob-roboflow merged commit 0b047e4 into roboflow:develop Jul 31, 2025
2 checks passed
sandesha-hegde pushed a commit to sandesha-hegde/rf-detr that referenced this pull request Aug 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants