Add MQ{C,R}NN Python version (port from MXNet)#3276
Open
timoschowski wants to merge 7 commits intoawslabs:devfrom
Open
Add MQ{C,R}NN Python version (port from MXNet)#3276timoschowski wants to merge 7 commits intoawslabs:devfrom
timoschowski wants to merge 7 commits intoawslabs:devfrom
Conversation
…data. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Key fixes: - Changed scaling parameter default from True to None (defaults to False for quantile output, matching MXNet's NOPScaler behavior) - Removed incorrect scale multiplication before quantile projection (MXNet applies quantile_proj directly to decoder output) - Added checkpoint loading error handling in PyTorchLightningEstimator - Added AddSeriesScale transformation for forking sequence models Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Added static features (including log(scale)) to RNN encoder input to match CNN encoder and MXNet MQRNN behavior. Changes: - RNNEncoder.forward() now concatenates target + static_features + dynamic_features - Matches CNN encoder feature concatenation pattern - Matches MXNet RNNEncoder._assemble_inputs() behavior Results: - Reduced MAE difference from 32.85% to 21.16% on electricity dataset - RMSE difference improved to 8.62% - Still investigating remaining ~20% difference Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Adds unit tests, integration tests, and parity tests to ensure MQCNN and MQRNN PyTorch implementations work correctly and maintain parity with MXNet reference implementations. Key additions: - Regression test for lazy initialization optimizer bug - Integration tests for both MQCNN and MQRNN estimators - MXNet vs PyTorch parity tests with documented tolerances - Tests verify RNN parameters are trained correctly Test coverage: - test_optimizer_includes_all_parameters: Critical regression test - test_mq_dnn_estimator_constant_dataset: End-to-end estimator tests - test_mq_dnn_mxnet_pytorch_parity: Framework parity verification - Additional tests for various configurations and edge cases All tests include clear assertions and failure messages to facilitate debugging if issues arise. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Remove backup files and debug output that should not be included in the pull request: - estimator.py.backup (backup file) - extreme_scales_output.txt (debug output) - MQ_DNN_MIGRATION_SUMMARY.md (internal documentation) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
3 tasks
Contributor
Author
Contributor
Author
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.


Issue #, if available:
#2059
Description of changes:
Claude and me worked on a port of MQCNN from MXNet to PyTorch. This works close enough for electricity dataset that I think we could try to merge this.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Please tag this pr with at least one of these labels to make our release process faster: BREAKING, new feature, bug fix, other change, dev setup