Skip to content
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

Reg cocktails #358

Draft
wants to merge 50 commits into
base: development
Choose a base branch
from
Draft

Reg cocktails #358

wants to merge 50 commits into from

Commits on Jul 21, 2022

  1. First push for Mix/cut regularization

    Fix mypy
    
    Initial implementation of adversarial training
    
    Modifying the code to have activation controlled batch normalization
    
    Adding activation controlled weight decay, updating the style for code style check
    
    Commit for passing style check
    
    Style check try 2
    
    Bug fix
    
    Adding unit test for adversarial trainer
    
    Adding code for activation controlled skip connections, with the additional choice of shake-shake and shake-drop being hyperparameters as the choice for the multi branch networks
    
    Bug fix for the failing tests
    
    Adding better conditions
    
    Try at a fix
    
    Temporary fix for the failing test
    
    Failing code check
    
    Failing code check v2
    
    Add new update to fix break
    
    Flake8 coding style fix
    
    Removing duplicate unit test
    
    In progress
    franchuterivera authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    e138b69 View commit details
    Browse the repository at this point in the history
  2. Add cyclic property to lr scheduler and use_swa to trainer

    swa working, se in progress
    
    Fixed bug in update model with swa model, add predict with snapshot ensemble; todo: add tests for both
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    3b4feae View commit details
    Browse the repository at this point in the history
  3. ADD tests for SWA, SE

    Add pytest_mock to test dependencies
    
    lookahead in progress
    
    add lookahead hyperparameters
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    b845d4d View commit details
    Browse the repository at this point in the history
  4. ADD tests for LookAhead

    Fix flake mypy
    
    Fix error in test
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    8a2364d View commit details
    Browse the repository at this point in the history
  5. Added default for lookahead config

    Addressed comments from francisco
    
    fixed issues after merge
    
    Add displayable path to model file assertion
    
    Add test for non cyclic scheduler
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    e2ee40a View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    6e0d2bb View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    9290b07 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    c35c795 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    2512709 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    41677fd View commit details
    Browse the repository at this point in the history
  11. cont...

    add min for 1
    
    Addressed comments from shuhei, better documentation
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    e236df0 View commit details
    Browse the repository at this point in the history
  12. Addressed comments from arlind, change in T_mul and T_0 calculations

    Added debug information for API
    
    Fix flake
    
    Fix import
    
    made test deterministic for feature preprocessing
    
    Fix bug in parsing log
    
    convert to int
    
    Fix bug in testing
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    f29a7e0 View commit details
    Browse the repository at this point in the history
  13. Updating search space (#156)

    * Updating search space
    
    * fix typo
    
    * Bug fix
    
    * Fixing buggy implementation of predict when using gpu
    
    bug fixes
    
    fixing code style checks
    
    bug fix for use_pynisher in the base pipeline
    
    bug fix
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    f141d06 View commit details
    Browse the repository at this point in the history
  14. Adding constant clause in the testing module for hyperparameter range…

    …s, removing use_pynisher since it is not used anymore, hack for the moment to bypass illegal hyperparameter ranges for conditions
    
    Fixing flake8 fail
    
    flake8 fix
    
    flake8 fix
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    9339895 View commit details
    Browse the repository at this point in the history
  15. Updating implementation for tabular regression

    Addressing the comment from Ravin
    
    Adding checks for the possible different value range of multibranch_choice
    
    Removing comment since it is not relevant anymore
    
    Removing unecessary code that transforms to cpu, while it is on cpu
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    126f7d4 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    f6f05ba View commit details
    Browse the repository at this point in the history
  17. Updating implementation

    Temporary bug fix
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    456e261 View commit details
    Browse the repository at this point in the history
  18. Implementation fix for constant updates to skip connections. Multibra…

    …nch choice was dependant on an illegal value
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    c7af699 View commit details
    Browse the repository at this point in the history
  19. Fixing the implementation for weight decay in the case of fixed updat…

    …es. The reason is the illegal value for weight decay when use weight decay is off
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    2102b08 View commit details
    Browse the repository at this point in the history
  20. update setup.py

    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    18da2bd View commit details
    Browse the repository at this point in the history
  21. Updating implementation of the reg cocktails so that it is compatible…

    … with fixed search space updates
    
    Turning off small preprocessing and also removing the TAE assertion for when the budget is larger than 100
    
    Decreasing the dataset size for the fit pipeline since it is giving time out errors with its current implementation
    
    Updating implementation
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    18bdabf View commit details
    Browse the repository at this point in the history
  22. Create fit evaluator, no resampling strategy and fix bug for test sta…

    …tistics
    
    Fix mypy and flake
    
    Fix check for X_test while making test data loader
    
    fix bug in lookahead hyperparameters where lookahead was repeated for the hyperparameter name
    
    Make passing tests in api easier
    
    Fix bug in trainer weighted loss code for regression
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    0c2c604 View commit details
    Browse the repository at this point in the history
  23. Additional metrics during train (#194)

    * Added additional metrics to fit dictionary
    
    * Added in test also
    
    Fix mypy and flake after rebase, added random state to mixup and cutout and changs no resampling for new code
    
    fix bug in setup.py
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    6d4790f View commit details
    Browse the repository at this point in the history
  24. Fixing issues with imbalanced datasets (#197)

    * adding missing method from base_feature_validator
    
    * First try at a fix, removing redundant code
    
    * Fix bug
    
    * Updating unit test typo, fixing bug where the data type was not checked because X was a numpy array at the time of checking
    
    * Fixing flake 8 failing
    
    * Bug fix, implementation update for imbalanced datasets and unit tests to check the implementation
    
    * flake8 fix
    
    * Bug fix
    
    * Making the conversion to dataframe in the unit tests consistent with what happens at the validator, so the types do not change
    
    * flake8 fix
    
    * Addressing Ravin's comments
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    5168ba5 View commit details
    Browse the repository at this point in the history
  25. Reproducibility in cocktail (#204)

    * Fix randomness in cocktail ingredients
    
    * Fix flake
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    23d808b View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    6283c56 View commit details
    Browse the repository at this point in the history
  27. Add dropout shape as a hyperparameter (#213)

    * Add dropout shape as a hyperparameter
    
    * fix stupid bug
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    bc0540b View commit details
    Browse the repository at this point in the history
  28. Configuration menu
    Copy the full SHA
    5d6062f View commit details
    Browse the repository at this point in the history
  29. added no head (#218)

    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    622c185 View commit details
    Browse the repository at this point in the history
  30. Fix bugs in cutout training (#233)

    * Fix bugs in cutout training
    
    * Address comments from arlind
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    c4b7729 View commit details
    Browse the repository at this point in the history
  31. Cocktail hotfixes (#245)

    * Fixes for the development branch and regularization cocktails
    
    * Update implementation
    
    * Fix unit tests temporarily
    
    * Implementation update and bug fixes
    
    * Removing unecessary code
    
    * Addressing Ravin's comments
    
    [refactor] Address Shuhei's comments
    
    [refactor] Address Shuhei's comments
    
    [refactor] Address Shuhei's comments
    
    [refactor] Address Shuhei's comments
    ArlindKadra authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    0c8d2ff View commit details
    Browse the repository at this point in the history
  32. [refactor] Address Shuhei's comments

    [fix] Fix Flake8 issues
    
    [refactor] Address Shuhei's comment
    
    [refactor] Address Shuhei's comments
    
    [refactor] Address Shuhei's comments
    
    [refactor] Address Shuhei's comments
    nabenabe0928 authored and ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    c1a73f8 View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    769e041 View commit details
    Browse the repository at this point in the history
  34. Configuration menu
    Copy the full SHA
    0da4f72 View commit details
    Browse the repository at this point in the history
  35. Configuration menu
    Copy the full SHA
    c4a4565 View commit details
    Browse the repository at this point in the history
  36. Bug fixes (#249)

    * Update implementation
    
    * Coding style fixes
    
    * Implementation update
    
    * Style fix
    
    * Turn weighted loss into a constant again, implementation update
    
    * Cocktail branch inconsistencies (#275)
    
    * To nemo
    
    * Revert change in T_curr as results conclusively prove it should be 0
    
    * Revert cutmix change after data from run
    
    * Final conclusion after results
    
    * FIX bug in shake alpha beta
    
    * Updated if is_training condition for shake drop
    
    * Remove temp fix in row cutmic
    
    * Cocktail fixes time debug (#286)
    
    * preprocess inside data validator
    
    * add time debug statements
    
    * Add fixes for categorical data
    
    * add fit_ensemble
    
    * add arlind fix for swa and se
    
    * fix bug in trainer choice fit
    
    * fix ensemble bug
    
    * Correct bug in cleanup
    
    * Cleanup for removing time debug statements
    
    * ablation for adversarial
    
    * shuffle false in dataloader
    
    * drop last false in dataloader
    
    * fix bug for validation set, and cutout and cutmix
    
    * shuffle = False
    
    * Shake Shake updates (#287)
    
    * To test locally
    
    * fix bug in trainer choice fit
    
    * fix ensemble bug
    
    * Correct bug in cleanup
    
    * To test locally
    
    * Cleanup for removing time debug statements
    
    * ablation for adversarial
    
    * shuffle false in dataloader
    
    * drop last false in dataloader
    
    * fix bug for validation set, and cutout and cutmix
    
    * To test locally
    
    * shuffle = False
    
    * To test locally
    
    * updates to search space
    
    * updates to search space
    
    * update branch with search space
    
    * undo search space update
    
    * fix bug in shake shake flag
    
    * limit to shake-even
    
    * restrict to even even
    
    * Add even even and others for shake-drop also
    
    * fix bug in passing alpha beta method
    
    * restrict to only even even
    
    * fix silly bug:
    
    * remove imputer and ordinal encoder for categorical transformer in feature validator
    
    * Address comments from shuhei
    
    * fix issues with ensemble fitting post hoc
    
    * Address comments on the PR
    
    * Fix flake and mypy errors
    
    * Address comments from PR #286
    
    * fix bug in embedding
    
    * Update autoPyTorch/api/tabular_classification.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/datasets/base_dataset.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/datasets/base_dataset.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/components/training/trainer/base_trainer.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Address comments from shuhei
    
    * adress comments from shuhei
    
    * fix flake and mypy
    
    * Update autoPyTorch/pipeline/components/training/trainer/RowCutMixTrainer.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/tabular_classification.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * increase threads_per_worker
    
    * fix bug in rowcutmix
    
    * Enhancement for the tabular validator. (#291)
    
    * Initial try at an enhancement for the tabular validator
    
    * Adding a few type annotations
    
    * Fixing bugs in implementation
    
    * Adding wrongly deleted code part during rebase
    
    * Fix bug in _get_args
    
    * Fix bug in _get_args
    
    * Addressing Shuhei's comments
    
    * Address Shuhei's comments
    
    * Refactoring code
    
    * Refactoring code
    
    * Typos fix and additional comments
    
    * Replace nan in categoricals with simple imputer
    
    * Remove unused function
    
    * add comment
    
    * Update autoPyTorch/data/tabular_feature_validator.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/data/tabular_feature_validator.py
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Adding unit test for only nall columns in the tabular feature categorical evaluator
    
    * fix bug in remove all nan columns
    
    * Bug fix for making tests run by arlind
    
    * fix flake errors in feature validator
    
    * made typing code uniform
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * address comments from shuhei
    
    * address comments from shuhei (2)
    
    Co-authored-by: Ravin Kohli <[email protected]>
    Co-authored-by: Ravin Kohli <[email protected]>
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * resolve code issues with new versions
    
    * Address comments from shuhei
    
    * make run_traditional_ml function
    
    * implement suggestion from shuhei and fix bug in rowcutmixtrainer
    
    * fix return type docstring
    
    * add better documentation and fix bug in shake_drop_get_bl
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * add test for comparator and other improvements based on PR comments
    
    * fix bug in test
    
    * [fix] Fix the condition in the raising error of all_nan_columns
    
    * [refactor] Unite name conventions of numpy array and pandas dataframe
    
    * [doc] Add the description about the tabular feature transformation
    
    * [doc] Add the description of the tabular feature transformation
    
    * address comments from arlind
    
    * address comments from arlind
    
    * change to as_tensor and address comments from arlind
    
    * correct description for functions in data module
    
    Co-authored-by: nabenabe0928 <[email protected]>
    Co-authored-by: Arlind Kadra <[email protected]>
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Addressing Shuhei's comments
    
    * flake8 problems fix
    
    * Update autoPyTorch/api/base_task.py
    
    Add indent.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/api/base_task.py
    
    Add indent.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/data/tabular_feature_validator.py
    
    Add indentation.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Add line indentation.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/data/tabular_feature_validator.py
    
    Validate if there is a column transformer since for sparse matrices we will not have one.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/utils/implementations.py
    
    Delete uncommented line.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Allow the number of threads to be given by the user
    
    * Removing unnecessary argument and refactoring the attribute.
    
    * Addressing Ravin's comments
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Updating the function documentation according to the agreed style.
    
    Co-authored-by: Ravin Kohli <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/utils.py
    
    Providing information on the wrong method provided for shake-shake regularization.
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * add todo for backend and accept changes from shuhei
    
    * Addressing Shuhei's and Ravin's comments
    
    * Addressing Shuhei's and Ravin's comments, bug fix
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/ResNetBackbone.py
    
    Improving code readibility.
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Update autoPyTorch/pipeline/components/setup/network_backbone/ResNetBackbone.py
    
    Improving consistency.
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * bug fix
    
    Co-authored-by: Ravin Kohli <[email protected]>
    Co-authored-by: nabenabe0928 <[email protected]>
    Co-authored-by: nabenabe0928 <[email protected]>
    Co-authored-by: Ravin Kohli <[email protected]>
    5 people committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    6543316 View commit details
    Browse the repository at this point in the history
  37. [FIX] Passing checks (#298)

    * Initial fix for all tests passing locally py=3.8
    
    * fix bug in tests
    
    * fix bug in test for data
    
    * debugging error in dummy forward pass
    
    * debug try -2
    
    * catch runtime error in ci
    
    * catch runtime error in ci
    
    * add better debug test setup
    
    * debug some more
    
    * run this test only
    
    * remove sum backward
    
    * remove inplace in inception block
    
    * undo silly change
    
    * Enable all tests
    
    * fix flake
    
    * fix bug in test setup
    
    * remove anamoly detection
    
    * minor changes to comments
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    * Address comments from Shuhei
    
    * revert change leading to bug
    
    * fix flake
    
    * change comment position in feature validator
    
    * Add documentation for _is_datasets_consistent
    
    * address comments from arlind
    
    * case when all nans in test
    
    Co-authored-by: nabenabe0928 <[email protected]>
    ravinkohli and nabenabe0928 committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    392f07a View commit details
    Browse the repository at this point in the history
  38. [FIX] Tests after rebase of reg_cocktails (#359)

    * update requirements
    
    * update requirements
    
    * resolve remaining conflicts and fix flake and mypy
    
    * Fix remaining tests and examples
    
    * fix failing checks
    
    * fix flake
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    02e97a1 View commit details
    Browse the repository at this point in the history
  39. rebase and fix flake

    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    03ddb64 View commit details
    Browse the repository at this point in the history
  40. Configuration menu
    Copy the full SHA
    59b5830 View commit details
    Browse the repository at this point in the history
  41. [FIX] Enable preprocessing in reg_cocktails (#369)

    * enable preprocessing and remove is_small_preprocess
    
    * address comments from shuhei and fix precommit checks
    
    * fix tests
    
    * fix precommit checks
    
    * add suggestions from shuhei for astype use
    
    * address speed issue when using object_dtype_mapping
    
    * make code more readable
    
    * improve documentation for base network embedding
    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    c3b8844 View commit details
    Browse the repository at this point in the history
  42. fixes after rebase

    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    c1fffa1 View commit details
    Browse the repository at this point in the history
  43. [FIX] SWA and SE with non cyclic schedulers (#395)

    * Enable learned embeddings, fix bug with non cyclic schedulers
    
    * add forbidden condition cyclic lr
    
    * refactor base_pipeline forbidden conditions
    
    * Apply suggestions from code review
    
    Co-authored-by: nabenabe0928 <[email protected]>
    
    Co-authored-by: nabenabe0928 <[email protected]>
    ravinkohli and nabenabe0928 committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    366bede View commit details
    Browse the repository at this point in the history
  44. fixes after rebase

    ravinkohli committed Jul 21, 2022
    Configuration menu
    Copy the full SHA
    637a68b View commit details
    Browse the repository at this point in the history

Commits on Jul 26, 2022

  1. fix tests after rebase

    ravinkohli committed Jul 26, 2022
    Configuration menu
    Copy the full SHA
    e69ff3b View commit details
    Browse the repository at this point in the history
  2. fix mypy and flake

    ravinkohli committed Jul 26, 2022
    Configuration menu
    Copy the full SHA
    c138173 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    afddca5 View commit details
    Browse the repository at this point in the history

Commits on Aug 12, 2022

  1. Configuration menu
    Copy the full SHA
    34c704d View commit details
    Browse the repository at this point in the history

Commits on Sep 23, 2022

  1. [FIX] apply cutout for each row. (#481)

    * fixed cut mix
    
    * remove unnecessary comment
    
    * change all_supported_metrics
    ravinkohli authored Sep 23, 2022
    Configuration menu
    Copy the full SHA
    d29d11b View commit details
    Browse the repository at this point in the history

Commits on Oct 17, 2022

  1. [FIX] ROC AUC for multi class classification (#482)

    * fixed cut mix
    
    * remove unnecessary comment
    
    * change all_supported_metrics
    
    * fix roc_auc for multiclass
    
    * remove unnecessary code
    ravinkohli authored Oct 17, 2022
    Configuration menu
    Copy the full SHA
    873df9a View commit details
    Browse the repository at this point in the history