Resolve inconsistent parameter names via aliasing + deprecationwarning.#3332
Open
deruyter92 wants to merge 8 commits into
Open
Resolve inconsistent parameter names via aliasing + deprecationwarning.#3332deruyter92 wants to merge 8 commits into
deruyter92 wants to merge 8 commits into
Conversation
C-Achard
reviewed
May 15, 2026
Collaborator
There was a problem hiding this comment.
Definitely like this one, we have several inconsistencies throughout between snake/camel case and this makes the API easier imo.
C-Achard
reviewed
May 15, 2026
Collaborator
C-Achard
left a comment
There was a problem hiding this comment.
Really nice overall !
I just have a few broader questions to make sure this stays "healthy" on the longer term:
- Can we handle non-keyword args safely with this ? Are there still risks of collisions/improper usage for users ?
- I think we should disallow "chaining" renames if possible, ie. videotype -> video_type is fine, but videotype -> video_type -> extensions raises, if possible. Not 100% needed. docs could suffice
- I would favor having super-clear rules on the decorator itself. e.g. : Always use the new version in code and never the old. Do not chain rename or stack, etc.
- We could also systematically test these, but not crucial
I don't mean to keep this blocked though, I just think a bit of documentation would be perfect, no need to go much further yet (automation etc)
Member
|
merge conflicts need fixing @deruyter92 |
81cfba6 to
6e6df5f
Compare
Collaborator
Author
|
@MMathisLab I have resolved all conflicts and rebased on main now |
Collaborator
Author
|
@C-Achard, currently addressing your review, valid points thanks! |
Collaborator
Author
|
Collaborator
|
Amazing thank you @deruyter92 ! |
C-Achard
approved these changes
May 15, 2026
…save_iters, max_iters
b02268f to
128a390
Compare
Collaborator
Author
|
(rebased again, removing empty diffs) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Standardize public API parameter names
This PR cleans up a series of inconsistent parameter names across the public DeepLabCut API. All renames are fully backward-compatible: the old names
are preserved as deprecated aliases via the existing
@renamed_parameterdecorator, which emits aDLCDeprecationWarning.Changes
Shuffles,shuffles→shufflesSnapindex,snapshotindex→snapshotindexvideotype,video_type,extensions→extensionsbatchsize,batch_size→batch_sizedisplayiters,display_iters→display_iterssaveiters,save_iters→save_itersmaxiters,max_iters→max_iterscomparisonbodyparts,comparison_bodyparts→comparison_bodypartsAll docstrings and inline examples have been updated to use the new names.