"vscode:/vscode.git/clone" did not exist on "f81a60bec0e31e5c6c219d0566ecb4ae45ea1588"
  1. 05 Jun, 2020 1 commit
  2. 04 Jun, 2020 3 commits
  3. 03 Jun, 2020 1 commit
    • Vasiliy Kuznetsov's avatar
      torchvision QAT tutorial: update for QAT with DDP (#2280) · 39021408
      Vasiliy Kuznetsov authored
      Summary:
      
      We've made two recent changes to QAT in PyTorch core:
      1. add support for SyncBatchNorm
      2. make eager mode QAT prepare scripts respect device affinity
      
      This PR updates the torchvision QAT reference script to take
      advantage of both of these.  This should be landed after
      https://github.com/pytorch/pytorch/pull/39337 (the last PT
      fix) to avoid compatibility issues.
      
      Test Plan:
      
      ```
      python -m torch.distributed.launch
        --nproc_per_node 8
        --use_env
        references/classification/train_quantization.py
        --data-path {imagenet1k_subset}
        --output-dir {tmp}
        --sync-bn
      ```
      
      Reviewers:
      
      Subscribers:
      
      Tasks:
      
      Tags:
      39021408
  4. 01 Jun, 2020 3 commits
  5. 31 May, 2020 1 commit
  6. 30 May, 2020 1 commit
  7. 29 May, 2020 4 commits
  8. 26 May, 2020 3 commits
  9. 21 May, 2020 3 commits
  10. 20 May, 2020 5 commits
    • Philip Meier's avatar
      12b551e7
    • Francisco Massa's avatar
      Deprecate Conv2d, ConvTranspose2d and BatchNorm2d (#2244) · 9055250a
      Francisco Massa authored
      * Deprecate Conv2d, ConvTranspose2d and BatchNorm
      
      * Fix lint
      9055250a
    • Erik's avatar
      add clarifications to Object detection reference documentation (#2241) · cb655900
      Erik authored
      * Update README.md
      
      added some clarity to get the examples executable.  Waiting to hear back if instructions should mention to setup COCO dataset
      
      * Update README.md
      
      * Update README.md
      
      * Update README.md
      
      * Update README.md
      
      * Update README.md
      cb655900
    • Negin Raoof's avatar
      [ONNX] Fix export of images with no detection (#2215) · 97e21c10
      Negin Raoof authored
      * Fixing nms on boxes when no detection
      
      * test
      
      * Fix for scale_factor computation
      
      * remove newline
      
      * Fix for mask_rcnn dynanmic axes
      
      * Clean up
      
      * Update transform.py
      
      * Fix for torchscript
      
      * Fix scripting errors
      
      * Fix annotation
      
      * Fix lint
      
      * Fix annotation
      
      * Fix for interpolate scripting
      
      * Fix for scripting
      
      * refactoring
      
      * refactor the code
      
      * Fix annotation
      
      * Fixed annotations
      
      * Added test for resize
      
      * lint
      
      * format
      
      * bump ORT
      
      * ort-nightly version
      
      * Going to ort 1.1.0
      
      * remove version
      
      * install typing-extension
      
      * Export model for images with no detection
      
      * Upgrade ort nightly
      
      * update ORT
      
      * Update test_onnx.py
      
      * updated tests
      
      * Updated tests
      
      * merge
      
      * Update transforms.py
      
      * Update cityscapes.py
      
      * Update celeba.py
      
      * Update caltech.py
      
      * Update pkg_helpers.bash
      
      * Clean up
      
      * Clean up for dynamic split
      
      * Remove extra casts
      
      * flake8
      
      * Fix for mask rcnn no detection export
      
      * clean up
      
      * Enable mask rcnn tests
      
      * Added test
      
      * update ORT
      
      * Update .travis.yml
      
      * fix annotation
      
      * Clean up roi_heads
      
      * clean up
      
      * clean up misc ops
      97e21c10
    • Mike Ruberry's avatar
      Updates integer division to use floor division operator (#2243) · ba63fbdb
      Mike Ruberry authored
      Another instance of integer division using the division operator. In this case line 266 already shows the correct formulation, so line 185 only needs the update.
      ba63fbdb
  11. 19 May, 2020 3 commits
  12. 18 May, 2020 6 commits
    • eellison's avatar
      remove script classes (#2210) · 222a599e
      eellison authored
      
      Co-authored-by: default avatareellison <eellison@fb.com>
      222a599e
    • Vasiliy Kuznetsov's avatar
      vision classification QAT tutorial: fix for DDP (redo) (#2230) · 7ed3950e
      Vasiliy Kuznetsov authored
      Summary:
      
      Redo of https://github.com/pytorch/vision/pull/2191
      
      Makes the classification QAT tutorial not crash when used
      with DDP. There were two issues:
      
      1. the model was moved to GPU before the observers were added, and they
      are created on CPU. In the context of this repo, the fix is to finalize
      the model before moving to GPU. We can potentially follow up with a
      better error message in the future, in a separate PR.
      2. the QAT conversion was running on the DDP'ed model, which had various
      problems. The fix is to unwrap the model from DDP before cloning it for
      evaluation.
      
      There is still work to do on verifying that BN is working correctly in
      QAT + DDP, but saving that for a separate PR.
      
      Test Plan:
      
      ```
      python -m torch.distributed.launch --use_env references/classification/train_quantization.py --data-path {path_to_imagenet_1k} --output_dir {output_dir}
      ```
      
      Reviewers:
      
      Subscribers:
      
      Tasks:
      
      Tags:
      7ed3950e
    • Steven Basart's avatar
      Add pil_to_tensor to functionals (#2092) · e6d3f8c5
      Steven Basart authored
      * Adds as_tensor to functional.py
      
      Similar functionality to to_tensor without the default conversion to float and division by 255.
      Also adds support for Image mode 'L'.
      
      * Adds tests to AsTensor()
      
      Adds tests to AsTensor and removes the conversion to float and division by 255.
      
      * Adds AsTensor to transforms.py
      
      Calls the as_tensor function in functionals and adds the function AsTensor as callable from transforms.
      
      * Removes the pic.mode == 'L'
      
      This was handled by the else condition previously so I'll remove it.
      
      * Fix Lint issue
      
      Adds two line breaks between functions to fix lint issue
      
      * Replace from_numpy with as_tensor
      
      Removes the extra if conditionals and replaces from_numpy with as_tensor.
      
      * Renames as_tensor to pil_to_tensor
      
      Renames the function as_tensor to pil_to_tensor and narrows the scope of the function.  At the same time also creates a flag that defaults to True for swapping to the channels first format.
      
      * Renames AsTensor to PILToImage
      
      Renames the function AsTensor to PILToImage and modifies the description.  Adds the swap_to_channelsfirst boolean variable to indicate if the user wishes to change the shape of the input.
      
      * Add the __init__ function to PILToTensor 
      
      Add the __init__ function to PILToTensor since it contains the swap_to_channelsfirst parameter now.
      
      * fix lint issue
      
      remove trailing white space
      
      * Fix the tests
      
      Reflects the name change to PILToTensor and the parameter to the function as well as the new narrowed scope that the function only accepts PIL images.
      
      * fix tests
      
      Instead of undoing the transpose just create a new tensor and test that one.
      
      * Add the view back
      
      Add img.view(pic.size[1], pic.size[0], len(pic.getbands())) back to outside the if condition.
      
      * fix test
      
      fix conversion from torch tensor to PIL back to torch tensor.
      
      * fix lint issues
      
      * fix lint
      
      remove trailing white space
      
      * Fixed the channel swapping tensor test
      
      Torch tranpose operates differently than numpy transpose.  Changed operation to permute.
      
      * Add mode='F'
      
      Add mode information when converting to PIL Image from Float Tensor.
      
      * Added inline comments to follow shape changes
      
      * ToPILImage converts FloatTensors to uint8
      
      * Remove testing not swapping
      
      * Removes the swap_channelsfirst parameter
      
      Makes the channel swapping the default behavior.
      
      * Remove the swap_channelsfirst argument
      
      Remove the swap_channelsfirst argument and makes the swapping the default functionality.
      e6d3f8c5
    • Francisco Massa's avatar
      Fix Python lint (#2226) · e2e511be
      Francisco Massa authored
      e2e511be
    • Fernando Pérez-García's avatar
    • Francisco Massa's avatar
      Fix missing include for OSX in video decoder (#2224) · 7d5b601b
      Francisco Massa authored
      * Fix missing include for OSX in video decoder
      
      * clang-format
      7d5b601b
  13. 15 May, 2020 1 commit
    • Urwa Muaz's avatar
      Feat/unfreeze layers fpn backbone (#2160) · 348dd5a7
      Urwa Muaz authored
      * freeze layers only if pretrained backbone is used
      
      If pretrained backbone is not used and one intends to train the entire network from scratch, no layers should be frozen.
      
      * function argument to control the trainable features
      
      Depending on the size of dataset one might want to control the number of tunable parameters in the backbone, and this parameter in hyper parameter optimization for the dataset. It would be nice to have this function support this.
      
      * ensuring tunable layer argument is valid
      
      * backbone freezing in fasterrcnn_resnet50_fpn
      
      Handle backbone freezing in fasterrcnn_resnet50_fpn function rather than the resnet_fpn_backbone function that it uses to get the backbone.
      
      * remove layer freezing code
      
      layer freezing code has been moved to fasterrcnn_resnet50_fpn function that consumes resnet_fpn_backbone function.
      
      * correcting linting errors
      
      * correcting linting errors
      
      * move freezing logic to resnet_fpn_backbone
      
      Moved layer freezing logic to resnet_fpn_backbone with an additional parameter.
      
      * remove layer freezing from fasterrcnn_resnet50_fpn
      
      Layer freezing logic has been moved to resnet_fpn_backbone. This function only ensures that the all layers are made trainable if pretrained models are not used.
      
      * update example resnet_fpn_backbone docs
      
      * correct typo in var name
      
      * correct indentation
      
      * adding test case for layer freezing in faster rcnn
      
      This PR adds functionality to specify the number of trainable layers while initializing the faster rcnn using fasterrcnn_resnet50_fpn function. This commits adds a test case to test this functionality.
      
      * updating layer freezing condition for clarity
      
      More information in PR
      
      * remove linting errors
      
      * removing linting errors
      
      * removing linting errors
      348dd5a7
  14. 14 May, 2020 4 commits
  15. 12 May, 2020 1 commit