Skip to content

Commit

Permalink
Update yolo.py (ultralytics#2120)
Browse files Browse the repository at this point in the history
* Avoid mutable state in Detect

* LoadImages() pathlib update (ultralytics#2140)

* Unique *.cache filenames fix (ultralytics#2134)

* fix ultralytics#2121

* Update test.py

* Update train.py

* Update autoanchor.py

* Update datasets.py

* Update log_dataset.py

* Update datasets.py

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* Update train.py test batch_size (ultralytics#2148)

* Update train.py

* Update loss.py

* Update train.py (ultralytics#2149)

* Linear LR scheduler option (ultralytics#2150)

* Linear LR scheduler option

* Update train.py

* Update data-autodownload background tasks (ultralytics#2154)

* Update get_coco.sh

* Update get_voc.sh

* Update detect.py (ultralytics#2167)

Without this cv2.imshow opens a window but nothing is visible

* Update requirements.txt (ultralytics#2173)

* Update utils/datasets.py to support .webp files (ultralytics#2174)

Simply added 'webp' as an image format to the img_formats array so that webp image files can be used as training data.

* Changed socket port and added timeout (ultralytics#2176)

* PyTorch Hub results.save('path/to/dir') (ultralytics#2179)

* YOLOv5 Segmentation Dataloader Updates (ultralytics#2188)

* Update C3 module

* Update C3 module

* Update C3 module

* Update C3 module

* update

* update

* update

* update

* update

* update

* update

* update

* update

* updates

* updates

* updates

* updates

* updates

* updates

* updates

* updates

* updates

* updates

* update

* update

* update

* update

* updates

* updates

* updates

* updates

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update datasets

* update

* update

* update

* update attempt_downlaod()

* merge

* merge

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* parameterize eps

* comments

* gs-multiple

* update

* max_nms implemented

* Create one_cycle() function

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* GitHub API rate limit fix

* update

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* ComputeLoss

* astuple

* epochs

* update

* update

* ComputeLoss()

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* update

* merge

* merge

* merge

* merge

* update

* update

* update

* update

* commit=tag == tags[-1]

* Update cudnn.benchmark

* update

* update

* update

* updates

* updates

* updates

* updates

* updates

* updates

* updates

* update

* update

* update

* update

* update

* mosaic9

* update

* update

* update

* update

* update

* update

* institute cache versioning

* only display on existing cache

* reverse cache exists booleans

* Created using Colaboratory

* YOLOv5 PyTorch Hub results.save() method retains filenames (ultralytics#2194)

* save results with name

* debug

* save original imgs names

* Update common.py

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* TTA augument boxes one pixel shifted in de-flip ud and lr (ultralytics#2219)

* TTA augument boxes one pixel shifted in de-flip ud and lr

* PEP8 reformat

Co-authored-by: Jaap van de Loosdrecht <jaap.van.de.loosdrecht@nhlstenden.com>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* LoadStreams() frame loss bug fix (ultralytics#2222)

* Update yolo.py channel array (ultralytics#2223)

* Add check_imshow() (ultralytics#2231)

* Add check_imshow()

* Update general.py

* Update general.py

* Update CI badge (ultralytics#2230)

* Add isdocker() (ultralytics#2232)

* Add isdocker()

* Update general.py

* Update general.py

* YOLOv5 Hub URL inference bug fix (ultralytics#2250)

* Update common.py

* Update common.py

* Update common.py

* Improved hubconf.py CI tests (ultralytics#2251)

* Unified hub and detect.py box and labels plotting (ultralytics#2243)

* reset head

* Update inference default to multi_label=False (ultralytics#2252)

* Update inference default to multi_label=False

* bug fix

* Update plots.py

* Update plots.py

* Robust objectness loss balancing (ultralytics#2256)

* Created using Colaboratory

* Update minimum stride to 32 (ultralytics#2266)

* Dynamic ONNX engine generation (ultralytics#2208)

* add: dynamic onnx export

* delete: test onnx inference

* fix dynamic output axis

* Code reduction

* fix: dynamic output axes, dynamic input naming

* Remove fixed axes

Co-authored-by: Shivam Swanrkar <ss8464@nyu.edu>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* Update greetings.yml for auto-rebase on PR (ultralytics#2272)

* Update Dockerfile with apt install zip (ultralytics#2274)

* FLOPS min stride 32 (ultralytics#2276)

Signed-off-by: xiaowo1996 <429740343@qq.com>

* Update README.md

* Amazon AWS EC2 startup and re-startup scripts (ultralytics#2185)

* Amazon AWS EC2 startup and re-startup scripts

* Create resume.py

* cleanup

* Amazon AWS EC2 startup and re-startup scripts (ultralytics#2282)

* Update train.py (ultralytics#2290)

* Update train.py

* Update train.py

* Update train.py

* Update train.py

* Create train.py

* Improved model+EMA checkpointing (ultralytics#2292)

* Enhanced model+EMA checkpointing

* update

* bug fix

* bug fix 2

* always save optimizer

* ema half

* remove model.float()

* model half

* carry ema/model in fp32

* rm model.float()

* both to float always

* cleanup

* cleanup

* Improved model+EMA checkpointing 2 (ultralytics#2295)

* Fix labels being missed when image extension appears twice in filename (ultralytics#2300)

* W&B entity support (ultralytics#2298)

* W&B entity support

* shorten wandb_entity to entity

Co-authored-by: Jan Hajek <jan.hajek@gmail.com>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* Avoid mutable state in Detect

* Update yolo and remove .to(device)

Co-authored-by: Oleg Boiko <oboiko@chegg.com>
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Co-authored-by: train255 <thanhdd.it@gmail.com>
Co-authored-by: ab-101 <56578530+ab-101@users.noreply.github.com>
Co-authored-by: Transigent <wbdsmith@optusnet.com.au>
Co-authored-by: NanoCode012 <kevinvong@rocketmail.com>
Co-authored-by: Daniel Khromov <danielkhromov@gmail.com>
Co-authored-by: VdLMV <jaap@vdlmv.nl>
Co-authored-by: Jaap van de Loosdrecht <jaap.van.de.loosdrecht@nhlstenden.com>
Co-authored-by: Yann Defretin <kinoute@gmail.com>
Co-authored-by: Aditya Lohia <64709773+aditya-dl@users.noreply.github.com>
Co-authored-by: Shivam Swanrkar <ss8464@nyu.edu>
Co-authored-by: xiaowo1996 <429740343@qq.com>
Co-authored-by: Iden Craven <iden.craven@gmail.com>
Co-authored-by: Jan Hajek <toretak@users.noreply.github.com>
Co-authored-by: Jan Hajek <jan.hajek@gmail.com>
  • Loading branch information
17 people authored Feb 26, 2021
1 parent d1681aa commit 8caa475
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/yolo.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def forward(self, x):
self.grid[i] = self._make_grid(nx, ny).to(x[i].device)

y = x[i].sigmoid()
y[..., 0:2] = (y[..., 0:2] * 2. - 0.5 + self.grid[i].to(x[i].device)) * self.stride[i] # xy
y[..., 0:2] = (y[..., 0:2] * 2. - 0.5 + self.grid[i]) * self.stride[i] # xy
y[..., 2:4] = (y[..., 2:4] * 2) ** 2 * self.anchor_grid[i] # wh
z.append(y.view(bs, -1, self.no))

Expand Down

0 comments on commit 8caa475

Please sign in to comment.