-
Notifications
You must be signed in to change notification settings - Fork 91
Fix quantized_embedding_norm undefined when normalize=False
#249
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix quantized_embedding_norm undefined when normalize=False
#249
Conversation
stes
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks, but can you also add the test that fails without the change, and passes now?
MMathisLab
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm, thanks @CeliaBenquet
|
test added @stes thanks :) |
stes
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm
* 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.
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.