Fix quantized_embedding_norm undefined when normalize=False#249
Merged
stes merged 2 commits intoAdaptiveMotorControlLab:mainfrom May 5, 2025
Merged
Conversation
stes
requested changes
Apr 25, 2025
Member
stes
left a comment
There was a problem hiding this comment.
thanks, but can you also add the test that fails without the change, and passes now?
MMathisLab
approved these changes
Apr 26, 2025
Member
MMathisLab
left a comment
There was a problem hiding this comment.
Lgtm, thanks @CeliaBenquet
Member
Author
|
test added @stes thanks :) |
MMathisLab
approved these changes
May 1, 2025
CeliaBenquet
added a commit
to CeliaBenquet/CEBRA
that referenced
this pull request
May 20, 2025
stes
pushed a commit
that referenced
this pull request
Jun 5, 2025
* start tests * remove print statements * first passing test * move functionality to base file in solver and separate in functions * add test_select_model for multisession * remove float16 * Improve modularity remove duplicate code and todos * Add tests to solver * Fix save/load * Fix extra docs errors * Add review updates * apply ruff auto-fixes * fix linting errors * Run isort, ruff, yapf * Fix gaussian mixture dataset import * Fix all tests but xcebra tests * Fix pytorch API usage example * Make xCEBRA compatible with the batched inference & padding in solver * Add some tests on transform() with xCEBRA * Add some docstrings and typings and clean unnecessary changes * Implement review comments * Fix sklearn test * Initial pass at integrating unifiedCEBRA * Add name in NOTE * Implement reviews on tests and typing * Fix import errors * Add select_model to aux solvers * Fix tests * Add mask tests * Fix docs error * Remove masking init() * Remove shuffled neurons in unified dataset * Remove extra datasets * Add tests on the private functions in base solver * Update tests and duplicate code based on review * Fix quantized_embedding_norm undefined when `normalize=False` (#249) * Fix tests * Adapt unified code to get_model method * Update mask.py add headers to new files * Update masking.py - header * Update test_data_masking.py - header * Implement review comments and fix typos * Fix docs errors * Remove np.int typing error * Fix docstring warning * Fix indentation docstrings * Implement review comments * Fix circular import and abstract method * Add maskedmixin to __all__ * Implement extra review comments * Change masking kwargs as tuple and not dict in sklearn impl * Add integrations/decoders.py * Fix typo * minor simplification in solver --------- Note, some comments in this PR overlap with #168 and #225 which were developed in parallel.
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.
When running
align_embeddings(embeddings, labels, normalize=False)quantized_embedding_norminquantized_embeddings.append(quantized_embedding_norm)is undefined.Solved by appending
quantized_embeddingtoquantized_embeddingsinstead whennormalize=False.