Skip to content

Add GH Action to build and publish Docker images #1390

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

Merged
merged 8 commits into from
Oct 21, 2020

Conversation

trsvchn
Copy link
Collaborator

@trsvchn trsvchn commented Oct 18, 2020

Fixes #1305

Description:

Adds GitHub Action that triggers on push to master docker folder or releases to build and publish Docker images

Check list:

  • New tests are added (if a new feature is added)
  • New doc strings: description and/or example code are in RST format
  • Documentation is updated (if required)

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 18, 2020

@trsvchn thanks a lot for the PR !
I wonder if you could test it somehow on your fork or somewhere else ?
When specified runs-on: ubuntu-latest does it have docker installed to build images ?
A reminder for myself: create secrets for username/tokens

I propose to add temporary on: pull-request, after buliding images, add a command like docker images to list all built images. Finally, try to publish with correct username and incorrect token (set by me) such that it should only fail on pushing. Such that we can "ensure" correctness of the GH action. What do you think ?

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 Sure, I am going to try it on my fork

When specified runs-on: ubuntu-latest does it have docker installed to build images ?

Yes, It has docker preinstalled, since jobs run inside a virtual machine, here is I created demo repo,:

https://github.com/trsvchn/docker-playground-action/runs/1274842834?check_suite_focus=true#step:3:1

In addition, there are some docker images already:

https://github.com/trsvchn/docker-playground-action/runs/1274842834?check_suite_focus=true#step:4:1

You just need to use runs-on: ubuntu-latest.

You can run docker container inside VM, like this:

  hello-docker-container:
    name: Try to run container
    runs-on: ubuntu-latest
    container: python:3

Here is the workflow file

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

@trsvchn sounds good ! Thanks the info, good to know that we are nothing to setup to run with a docker 👍

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

I propose to add temporary on: pull-request, after buliding images, add a command like docker images to list all built images. Finally, try to publish with correct username and incorrect token (set by me) such that it should only fail on pushing. Such that we can "ensure" correctness of the GH action. What do you think ?

I am experimenting inside my fork, and this is nice, because I can turn-off all other workflows and work only with docker workflow.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

UPDATE: run: cd docker doesn't work, you need use working-directory: ./docker on each step.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

OK, the action is configured but Horovod build failed:
https://github.com/trsvchn/ignite/runs/1275008864?check_suite_focus=true#step:3:1615

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

OK, the action is configured

Nice !

@trsvchn let me check what is the issue there with Horovod build.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

Yeah, just saw it :)

++ docker run --rm -it pytorchignite/base:latest -c 'python -c "import torch; import ignite; print(torch.version + "-" + ignite.version, end="")"'
the input device is not a TTY

Probably, we can find another more proper way to fetch the version :)

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

Probably, we can find another more proper way to fetch the version :)

Yeah, definitely) same for msdp

++ docker run --rm -it pytorchignite/msdp-apex-base:latest -c 'python -c "import torch; import ignite; print(torch.version + "-" + ignite.version, end="")"'
the input device is not a TTY

  • image_tag=
    Error: Process completed with exit code 1.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 I think we just need to use -i instead of -it

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

@trsvchn I left a comment to the latest commit about removing one of -c. Maybe, to iterate faster you can disable building part and check docker run --rm -i pytorchignite/${image_name}:latest ..., as there is a version on hub.docker it could pull the latest version.

Seems like main is built and the fail is at push

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 -i did the thing!

https://github.com/trsvchn/ignite/runs/1275326281?check_suite_focus=true#step:4:1

docker images | grep pytorchignite
  shell: /bin/bash -e {0}
pytorchignite/apex-nlp                               1.6.0-0.4.2                   cb179b3a5c46        Less than a second ago   3.87GB
pytorchignite/apex-nlp                               latest                        cb179b3a5c46        Less than a second ago   3.87GB
pytorchignite/apex-vision                            1.6.0-0.4.2                   798acfbca85e        21 seconds ago           4.38GB
pytorchignite/apex-vision                            latest                        798acfbca85e        21 seconds ago           4.38GB
pytorchignite/apex                                   1.6.0-0.4.2                   2e30b5a737e6        About a minute ago       3.73GB
pytorchignite/apex                                   latest                        2e30b5a737e6        About a minute ago       3.73GB
pytorchignite/nlp                                    1.6.0-0.4.2                   77cc4d16ea86        14 minutes ago           3.82GB
pytorchignite/nlp                                    latest                        77cc4d16ea86        14 minutes ago           3.82GB
pytorchignite/vision                                 1.6.0-0.4.2                   f7a6f1db205a        14 minutes ago           4.33GB
pytorchignite/vision                                 latest                        f7a6f1db205a        14 minutes ago           4.33GB
pytorchignite/base                                   1.6.0-0.4.2                   97f5a9931a28        16 minutes ago           3.68GB
pytorchignite/base                                   latest                        97f5a9931a28        16 minutes ago           3.68GB

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

I read your comment, this works fine:

image_tag=`docker run --rm -i pytorchignite/${image_name}:latest -c 'python -c "import torch; import ignite; print(torch.__version__ + \"-\" + ignite.__version__, end=\"\")"'`

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

I read your comment, this works fine:

image_tag=`docker run --rm -i pytorchignite/${image_name}:latest -c 'python -c "import torch; import ignite; print(torch.__version__ + \"-\" + ignite.__version__, end=\"\")"'`

Yes, let's keep it like that. I checked also locally and without the first -c it does not work. So, let's keep it as you did.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

I read your comment, this works fine:

image_tag=`docker run --rm -i pytorchignite/${image_name}:latest -c 'python -c "import torch; import ignite; print(torch.__version__ + \"-\" + ignite.__version__, end=\"\")"'`

Yes, let's keep it like that. I checked also locally and without the first -c it does not work. So, let's keep it as you did.

yes here is a proof)

Or you can change it to -i if you have input piped into the docker command that doesn't come from a TTY. If you have something like xyz | docker ... or docker ... <input in your command line, do this.

Error “The input device is not a TTY”

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 So, I am going to update the PR with -i and configured workflow, but I will comment out the horovod for now and I will add on: pull_request to check the action in action)

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

@trsvchn could you try to build locally a single horovod image on CPU only infra, please ? If you have a similar issue than probably we can not build horovod without a GPU...

@vfdev-5 So, I am going to update the PR with -i and configured workflow, but I will comment out the horovod for now and I will add on: pull_request to check the action in action)

Sounds good !

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@trsvchn could you try to build locally a single horovod image on CPU only infra, please ? If you have a similar issue than probably we can not build horovod without a GPU...

Yes! I have a such machine, but it takes some time)

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

I also added secrets to use with push

steps:
  - name: Hello world action
    env: # Or as an environment variable
      DOCKER_USER: ${{ secrets.DOCKER_USER }}
      DOCKER_TOKEN: ${{ secrets.DOCKER_TOKEN }}

Currently, the token is set incorrect to check the bash script.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

I also added secrets to use with push

Great! Can I add them to yml?

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

I also added secrets to use with push

Great! Can I add them to yml?

Yes, please, it probably should be like the code above.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 I've got the same issue for Horovod on the local CPU-only machine:

On GH Action VM:

Building wheels for collected packages: horovod, psutil, pyyaml
  Building wheel for horovod (setup.py): started
  Building wheel for horovod (setup.py): finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /opt/conda/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-oxm96qf0/setup.py'"'"'; __file__='"'"'/tmp/pip-req-build-oxm96qf0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-wzpzp2o8
       cwd: /tmp/pip-req-build-oxm96qf0/
Complete output (1071 lines):

...

  ERROR: Failed building wheel for horovod
  Running setup.py clean for horovod
  Building wheel for psutil (setup.py): started
  Building wheel for psutil (setup.py): finished with status 'done'
  Created wheel for psutil: filename=psutil-5.7.2-cp37-cp37m-linux_x86_64.whl size=283600 sha256=f25940592581464e8aa4df7b656ab65e0f705724a328898ead7b8d98d692e34d
  Stored in directory: /tmp/pip-ephem-wheel-cache-td4yfx19/wheels/2d/43/97/00701864a7bee6d9e1a52dd682537dcbf1d013d0e2e6f0c1f1
  Building wheel for pyyaml (setup.py): started
  Building wheel for pyyaml (setup.py): finished with status 'done'
  Created wheel for pyyaml: filename=PyYAML-5.3.1-cp37-cp37m-linux_x86_64.whl size=44619 sha256=7a77d79a9bf41dfeb91eadb3523a249b613f07762cad6c2c02b364fa5fac70e6
  Stored in directory: /tmp/pip-ephem-wheel-cache-td4yfx19/wheels/5e/03/1e/e1e954795d6f35dfc7b637fe2277bff021303bd9570ecea653
Successfully built psutil pyyaml
Failed to build horovod
ERROR: Failed to build one or more wheels
The command '/bin/sh -c apt-get update && apt-get install -y git &&         git clone --recursive --depth 1 --branch v0.20.0 https://github.com/horovod/horovod.git /horovod &&         conda install -y cmake=3.16 nccl=2.7 -c conda-forge &&         cd /horovod &&         HOROVOD_GPU_OPERATIONS=NCCL HOROVOD_NCCL_LINK=SHARED HOROVOD_WITHOUT_MPI=1 HOROVOD_WITH_PYTORCH=1 pip wheel --no-cache-dir . &&         rm -rf /var/lib/apt/lists/*' returned a non-zero code: 1

On Local CPU-only machine:

Building wheels for collected packages: horovod, psutil, pyyaml
  Building wheel for horovod (setup.py): started
  Building wheel for horovod (setup.py): still running...
  Building wheel for horovod (setup.py): still running...
  Building wheel for horovod (setup.py): finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /opt/conda/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-l59s03l0/setup.py'"'"'; __file__='"'"'/tmp/pip-req-build-l59s03l0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-jnlf3nk7
       cwd: /tmp/pip-req-build-l59s03l0/
  Complete output (1071 lines):

...

  ERROR: Failed building wheel for horovod
  Running setup.py clean for horovod
  Building wheel for psutil (setup.py): started
  Building wheel for psutil (setup.py): finished with status 'done'
  Created wheel for psutil: filename=psutil-5.7.2-cp37-cp37m-linux_x86_64.whl size=283599 sha256=abbe06e81ff93895397fb1b9f69e9b1b50852ef72ea21c2752fec635d093b8b3
  Stored in directory: /tmp/pip-ephem-wheel-cache-6ltpp9lt/wheels/2d/43/97/00701864a7bee6d9e1a52dd682537dcbf1d013d0e2e6f0c1f1
  Building wheel for pyyaml (setup.py): started
  Building wheel for pyyaml (setup.py): finished with status 'done'
  Created wheel for pyyaml: filename=PyYAML-5.3.1-cp37-cp37m-linux_x86_64.whl size=44619 sha256=8f11f852a6ac2f25a88dc82baf24ccf0bd94cad7d8bd926b73bd68a4b2fba7b7
  Stored in directory: /tmp/pip-ephem-wheel-cache-6ltpp9lt/wheels/5e/03/1e/e1e954795d6f35dfc7b637fe2277bff021303bd9570ecea653
Successfully built psutil pyyaml
Failed to build horovod
ERROR: Failed to build one or more wheels
The command '/bin/sh -c apt-get update && apt-get install -y git &&         git clone --recursive --depth 1 --branch v0.20.0 https://github.com/horovod/horovod.git /horovod &&         conda install -y cmake=3.16 nccl=2.7 -c conda-forge &&         cd /horovod &&         HOROVOD_GPU_OPERATIONS=NCCL HOROVOD_NCCL_LINK=SHARED HOROVOD_WITHOUT_MPI=1 HOROVOD_WITH_PYTORCH=1 pip wheel --no-cache-dir . &&         rm -rf /var/lib/apt/lists/*' returned a non-zero code: 1

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 19, 2020

@trsvchn thanks a lot for reproducing the issue ! I saw in the logs that the issue is related to generating some cuda kernels: https://github.com/trsvchn/ignite/runs/1275008864?check_suite_focus=true#step:3:961
Let's try to figure out if we could fix it. Otherwise, we have to build it on Circle CI with GPU support... :(

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 19, 2020

@vfdev-5 At least, for now, main and msdp work well, here is logs from latest test on the forked repo

https://github.com/trsvchn/ignite/runs/1276022256?check_suite_focus=true#step:5:1

here push all log (with invalid tokens)

https://github.com/trsvchn/ignite/runs/1276304424?check_suite_focus=true#step:5:9

@trsvchn trsvchn force-pushed the docker-push-action branch from 452b7bc to 4ee7b5e Compare October 19, 2020 16:11
@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 20, 2020

@trsvchn I tested building hvd-base image on two machines: a) ~cpu only and b) with CUDA_VISIBLE_DEVICES="" docker build .... Both are passing. Let's check again here with updated horovod branch to 0.20.3.

@vfdev-5 vfdev-5 changed the title ADD GH Action to build and publish Docker images Add GH Action to build and publish Docker images Oct 20, 2020
@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

@trsvchn I tested building hvd-base image on two machines: a) ~cpu only and b) with CUDA_VISIBLE_DEVICES="" docker build .... Both are passing. Let's check again here with updated horovod branch to 0.20.3.

@vfdev-5
Sounds great! I can test it on my fork, what changes are required?

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

@trsvchn the diff is

-        git clone --recursive --depth 1 --branch v0.20.0 https://github.com/horovod/horovod.git /horovod && \
+        git clone --recursive --depth 1 --branch v0.20.3 https://github.com/horovod/horovod.git /horovod && \

in

        modified:   docker/hvd/Dockerfile.hvd-apex
        modified:   docker/hvd/Dockerfile.hvd-base

Yeah, let's see if it passes on the CI.

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

@vfdev-5 YES! Now it works!

https://github.com/trsvchn/ignite/runs/1286774229?check_suite_focus=true#step:6:1

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

That's awesome ! So, let's update this PR. I'm thinking if it is good if we could keep images building on PR but no push to the docker hub and we rebuild them and push on push/master github event. Rebuilding images on push/master github event is not very eco solution though.

@trsvchn trsvchn force-pushed the docker-push-action branch from 8155ecb to 4097c50 Compare October 21, 2020 14:05
@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

That's awesome ! So, let's update this PR. I'm thinking if it is good if we could keep images building on PR but no push to the docker hub and we rebuild them and push on push/master github event. Rebuilding images on push/master github event is not very eco solution though.

Yes that makes sense, we can do smth like:

      - if github.event_name == 'push'
        name: Push all PyTorch-Ignite Docker images
        env:
          DOCKER_USER: ${{ secrets.DOCKER_USER }}
          DOCKER_TOKEN: ${{ secrets.DOCKER_TOKEN }}
        working-directory: ./docker
        run: |
          chmod +x ./push_all.sh
          ./push_all.sh

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

@trsvchn thanks! Let's do it like that

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

@vfdev-5 I have an idea, what if split this workflow into 3 additional with builds triggered only with changes in specific dirs, for example:

This one just builds Horovod images on PR, push/master and changes in hvd dir:

name: Build only Horovod flavoured PyTorch-Ignite images 

on:
  push:
    branches:
      - master
    paths:
      - docker/hvd/**
  pull_request:
    paths:
      - docker/hvd/**

jobs:
  build:
    name: Build all Horovod flavoured PyTorch-Ignite images
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v2
      - name: Build all Horovod flavoured PyTorch-Ignite images
        working-directory: ./docker
        run: |
          chmod +x ./hvd/build_all.sh
          ./hvd/build_all.sh

      - if github.event_name == 'push'
        # push hvd only images

The same for main and msdp. (just builds)

Then we just need to adjust existing workflow to start only on releases, and this one will push to docker hub

name: Build And Publish Docker Images

on:
  release:
    types: [published]

What do you think?

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

@trsvchn this would be nice, however I do not know how to pass built images from different workflows as we have to upload somewhere the artifacts ?

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

@trsvchn this would be nice, however I do not know how to pass built images from different workflows as we have to upload somewhere the artifacts ?

Yeah, and we have quite large artifacts :(

Yes, proposed solution just decreases number of builds per workflow

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

Maybe we can reconfigure push_all such that it could push only what we need ?

Btw, CI still does not build images. I was also thinking to reduce the number of running CI actions here : #1269 but seems like the PR on it got stuck

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

Btw, CI still does not build images.

Interesting, and why it works in the forked repo

@vfdev-5
Copy link
Collaborator

vfdev-5 commented Oct 21, 2020

I think the issue is here

- if github.event_name == 'push'
   name: Push all PyTorch-Ignite Docker images

which probably would look like (to verify)

- name: Push all PyTorch-Ignite Docker images
   if: github.event_name == 'push'

@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

I think the issue is here

- if github.event_name == 'push'
   name: Push all PyTorch-Ignite Docker images

which probably would look like (to verify)

- name: Push all PyTorch-Ignite Docker images
   if: github.event_name == 'push'

Yes, I think you are right

Copy link
Collaborator

@vfdev-5 vfdev-5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@trsvchn Thanks a lot for the PR ! I think it is perfect for the first iteration. I'll merge it once docker token is updated and we can push updated images then. If you'd like to setup 3 workflows to build only modified docker image in another PR, it would be awesome !

@vfdev-5 vfdev-5 merged commit 465e621 into pytorch:master Oct 21, 2020
@trsvchn
Copy link
Collaborator Author

trsvchn commented Oct 21, 2020

@trsvchn Thanks a lot for the PR ! I think it is perfect for the first iteration. I'll merge it once docker token is updated and we can push updated images then.

@vfdev-5 Yeah I think it's a good start! :)

If you'd like to setup 3 workflows to build only modified docker image in another PR, it would be awesome !

Sure! I would love to do that!

vfdev-5 added a commit to vfdev-5/ignite that referenced this pull request Nov 24, 2020
* Update TQDM to > 4.48.0 (pytorch#1339)

* Fix tqdm 4.49.0 tests.

* update requirements.

* Use distutils instead of packaging for getting package version.

* Reformat code.

* Reformat using black 19.10b0.

Co-authored-by: vfdev <[email protected]>

* Activate mypy in ignite.utils (pytorch#1352)

* Activate mypy in ignite.utils

* Add missing torch package to lint stage

* Move mypy check to test stage

Co-authored-by: vfdev <[email protected]>

* Exposed EventEnum in docs and added import statement in its examples (pytorch#1345) (pytorch#1353)

* Update Shpinx to v3.1. (pytorch#1356)

Fixes pytorch#1272

* Update README.md

* Update doc of examples for Trains fileserver setup (pytorch#1360)

* update doc for trains fileserver setup

* replace github issue by documentation

Co-authored-by: Desroziers <[email protected]>

* Updated commit fix (pytorch#1361) (pytorch#1364)

* Updated commit fix

* Update code-style.yml

Co-authored-by: rex_divakar <[email protected]>

* added tuple type to mixins.py (pytorch#1365)

* added tuple type to mixins.py

* allow mypy to pass through base file

* fixed linting issues

Co-authored-by: vfdev <[email protected]>

* Activate mypy in ignite.distributed (pytorch#1355)

* Activate mypy in ignite.distributed

* Fix tests & py3.5 inline type hints

* Remove typing,overload

* Fix multiple typing issues

* Fix typing issues

* Fix TPU test

Co-authored-by: vfdev <[email protected]>

* Improve typing for ignite.handlers module (1343) (pytorch#1349)

* Improve typing for ignite.handlers module (1343)

* autopep8 fix

* Fix typing for py35, remove handlers block from mypy.ini

* Add exception to ModelCheckpoint when saving last checkpoint

* Add test for ModelCheckpoint with redefined save_handler case

* autopep8 fix

Co-authored-by: AutoPEP8 <>
Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>
Co-authored-by: trsvchn <[email protected]>

* [3] [contrib/metrics] setup typing in contrib part of the library (pytorch#1363)

* [3] [contrib/metrics] setup typing in contrib part of the library

* review changes

* Update gpu_info.py

Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>

* [2] [contrib/handlers] setup typing in contrib part of the library (pytorch#1362)

* [2] [contrib/handlers] setup typing in contrib part of the library

* Fix a typo in tqdm logger

* review comments

* Update mlflow_logger.py

* Update neptune_logger.py

* review changes

* review changes

Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>

* [1] [contrib/engines] setup typing in contrib part of the library  (pytorch#1351)

* setup typing for contribute/engine part of the code

* revert doc string changes

* Update common.py

Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>

* Update PULL_REQUEST_TEMPLATE.md

* Disable cross-ref links for type annotations (pytorch#1374)

* Added reinit__is_reduced and sync_all_reduce docs in metrics doc (pytorch#1373)

* added links to reinit__is_reduced and sync_all_reduce decorators in metrics documentation

* updated order in list of metrics

* deleted decorators from metric list

* Update metrics.rst

Co-authored-by: vfdev <[email protected]>

* warning if current device index is lower than current local rank (pytorch#1335) (pytorch#1376)

* warning if current device index is lower than current local rank (pytorch#1335)

* warning if current device index is lower than current local rank

* Updated code and tests

* Fixed formatting

* Updated code and tests for horovod
- fixed failing test

* Updated tests

Co-authored-by: vfdev-5 <[email protected]>

* Removed debug prints

* Fixed failing hvd tests

Co-authored-by: Sai Sandeep Mutyala <[email protected]>

* Github Actions workflow CI for horovod on CPU (pytorch#1377)

* Initial commit

* Update hvd-tests.yml

* Update hvd-tests.yml

* Update hvd-tests.yml

* trigger GitHub actions

* removed examples

* trigger GitHub actions

* Improve typing of distributed.comp_modules.utils.all_gather (pytorch#1370)

* Improve typing of distributed.comp_modules.utils.all_gather

* Fix all_gather gloo test

* Fix XLA test

Co-authored-by: vfdev <[email protected]>

* Removed state.restart method (pytorch#1385)

* Activate mypy in ignite.engine (pytorch#1379)

* Activate mypy in ignite.engine

* Fix missing import

* Fix typing issues with nighty build

* Fix PR findings

Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>

* add acknowledgment for IFPEN (pytorch#1387)

Co-authored-by: Desroziers <[email protected]>

* Fix collections DeprecationWarning (pytorch#1388)

* Remove deprecated CustomPeriodicEvent from nb example, fix tb OutputHadler (pytorch#1389)

* Update checkpoint.py (pytorch#1394)

* Add GH Action to build and publish Docker images (pytorch#1390)

* ADD GH Action to build and publish Docker images

* Configure GH action for Docker build

* Fix image_tag fetching

* Fix identation for main steps

* Add token envs for GH docker action, fix push all tag_image

* Switch to horovod 0.20.3

* Push images on push events

* Fix if conditional

* Toctrees for classes and methods using sphinx autosummary (pytorch#1393)

* Implement autosummary patch for autolisting

* Fix css for autogenerated tables via autosummary

* Improve autolist feature

* Add toctrees for methods and classes for ignite

* Better import for autolist

* Add toctrees for methods and classes for contrib package

* Fix CSS for autosummary table row height

* Fix warnings raised by toctree

* Remove all deprecated args, kwargs for v0.5.0 (pytorch#1396) (pytorch#1397)

* Remove all deprecated args, kwargs for v0.5.0 (pytorch#1396)

* Improve deprecation message of setup_any_logging (pytorch#1396)

* Update setup.cfg

* Remove module members w/o docstrings from autolist toc tables (pytorch#1401)

* Add --color=yes in pytest config (pytorch#1402)

* removes styling of function descriptions as requested in pytorch#1256 (pytorch#1399)

* removes styling of function descriptions as requested in pytorch#1256

* reverts modifications to the example files

* Skip circle ci and GA builds (pytorch#1400)

* [WIP] Skip circle ci and GA builds

* Fixes swissknife version

* Replaced swissknife by sh script

* [skip ci] Updated trigger_if_modified.sh script
- excluded docs from github actions
- added 1.6.0 to pytorch-version-tests

* Fixes pytorch#1408, XLA failing tests (pytorch#1412)

- Issue is related to xla nightly
- Probably related to pytorch/xla#2576

* Added Mypy check as github action (pytorch#1418)

* Added Mypy check to as github action

* Removed py3.5

* Activate mypy in ignite.metrics (pytorch#1391)

* Activate mypy in ignite.metrics

* remove num_examples check

* fix CR issues

* remove init defaults in Accuracy

* Remove None assignments in __init__

* improved typing connected with mypy issues

Co-authored-by: vfdev <[email protected]>

* Update README.md

Badge travis org -> com

* add tolerance for tpu in r2 and canberra tests (pytorch#1414)

* add tolerance for tpu

* autopep8 fix

* Reverted test_canberra_metric.py as unnecessary

* Update test_r2_score.py

* Update test_r2_score.py

Co-authored-by: Desroziers <[email protected]>
Co-authored-by: sdesrozis <[email protected]>
Co-authored-by: vfdev <[email protected]>

* Activate mypy ignite contrib metrics (pytorch#1419)

* Activate mypy in ignite.contrib.metrics

* Add missing type hints in ignite.contrib.metrics

* Add missing type hints

* Contributing guide (pytorch#1424)

* Add materials on how to setup dev env in CONTRIBUTING guide pytorch#1395
- first draft of first-time contributor guide

* Add materials on how to setup dev env in CONTRIBUTING guide pytorch#1395
- add in Table of Contents

* Add materials on how to setup dev env in CONTRIBUTING guide pytorch#1395
- fix table of contents link

* Add materials on how to setup dev env in CONTRIBUTING guide pytorch#1395
- rollback README.md, remove IDE setting

* Update CONTRIBUTING.md

Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>

* replace Number type with float; remove unneeded type ignores (pytorch#1425)

Co-authored-by: vfdev <[email protected]>

* Update README.md

* Added new time profiler `HandlersTimeProfiler` which allows per handler time profiling (pytorch#1398)

* added new HandlersTimeProfiler with handler level details and added tests for HandlersTimeProfiler (pytorch#1346)

* updated docs and docstring for HandlersTimeProfiler (pytorch#1346)

* updated HandlersTimeProfiler to support any events and updated detach mechanism of profiler (pytorch#1346)

* updated HandlersTimeProfiler with code improvements and implemented csv export method (pytorch#1346)

* updated HandlersTimeProfiler to handle event handler bundle better (pytorch#1346)

* HandlersTimeProfiler: added threshold for filtering profiled time for handlers attached to event with filters (pytorch#1346)

* HandlersTimeProfiler: add tests and type hints (pytorch#1398)

* HandlersTimeProfiler: use FloatTensor for list to tensor conversion (pytorch#1398)

* HandlersTimeProfiler: use torch.tensor for list to tensor conversion (pytorch#1398)

* HandlersTimeProfiler: remove unnecessary import (pytorch#1398)

* HandlersTimeProfiler: move tensor conversion in compute_basic_stats (pytorch#1398)

Co-authored-by: vfdev <[email protected]>

* Fix HandlersTimeProfiler example rendering (pytorch#1428)

* Fix HandlersTimeProfiler example rendering

* Fix WARNINGs: Title underline too short

* Add horizontal scrollbars for examples instead of font-size tweaks

* Enable horizontal scrollbars for examples globally

* Save model with same filename (pytorch#1423)

* save model with same filename

* Update checkpoint.py

* use elif

* refactor to have only one comprehension list

* refactoring

* improve test

* autopep8 fix

Co-authored-by: Desroziers <[email protected]>
Co-authored-by: vfdev <[email protected]>
Co-authored-by: sdesrozis <[email protected]>

* Some docs nit picking (pytorch#1435)

* enable extra flags for stricter type checking (pytorch#1433)

* Fixes pytorch#1426 - distrib cpu tests on win (pytorch#1429)

* Fixes pytorch#1426 - distrib cpu tests on win

* Skip distributed/tpu/multinode_distributed if SKIP_DISTRIB_TESTS=1

* replaced sh by bash

* Update pytorch-version-tests.yml

* Updated files to ignore for GitHub Actions CI (pytorch#1441)

* Added windows gpu test to circle ci (pytorch#1440)

* [WIP] Added windows gpu test to circle ci

* Updated windows config

* Updated conda installation

* Updated miniconda install command

* Removed conda installation

* Updated configuration

* Adding max_iters as an optional arg in Engine run (pytorch#1381)

* initial draft, adding max_iters as optional args in run

* fixed typo

* minor bug fixes

* resolving failing tests

* fixed out-of-place conditional

* typo fix

* updated docstring for 'run'

* added initial tests

* (WIP) restructured creating a new state with max_iters

* updated tests & docstrings

* initial draft, adding max_iters as optional args in run

* fixed typo

* minor bug fixes

* resolving failing tests

* fixed out-of-place conditional

* typo fix

* updated docstring for 'run'

* added initial tests

* (WIP) restructured creating a new state with max_iters

* updated tests & docstrings

* added test to check _is_done

* updating engine loop condition

* autopep8 fix

* linting issues

* fixed mypy errors

* fixed formatting

* minor fix & add test for larger max_iters

* removed unused typechecking

Co-authored-by: thescripted <[email protected]>
Co-authored-by: vfdev <[email protected]>

* Updated circleci trigger_if_modified.sh if on master

* Fix failing distributed ci (pytorch#1445)

* Setup random free port for distrib ci

* autopep8 fix

Co-authored-by: vfdev-5 <[email protected]>

* Added torch.cuda.manual_seed_all(seed) (pytorch#1444)

* fix ReduceOp typing issue (pytorch#1447)

* Update README.md

* Updated miniconda setup (pytorch#1449)

* Fixed broken coverage (pytorch#1451)

* Fixed broken coverage

* Updated hvd-tests.yml

* Migrated nightly build/release to GitHub Actions (pytorch#1448) (pytorch#1450)

* Added nightly build/release action

* Updated yml

* Updated to conda-incubator/setup-miniconda@v2

* Reverted modifications in other actions

* Migrated nightly build/release to GitHub Actions (pytorch#1448)

* Added nightly build/release action

* Updated yml

* Updated to conda-incubator/setup-miniconda@v2

* Reverted modifications in other actions

* Fix PyPi upload

* Finalized binaries-nightly-release.yml

* Updated README

* [contributing] add syncing up with the upstream (pytorch#1452)

* Update setup.cfg

* [contributing] add syncing up with the upstream

* Apply suggestions from code review

Co-authored-by: vfdev <[email protected]>

* Update CONTRIBUTING.md

Co-authored-by: vfdev <[email protected]>

* [ci] create docs.yml

* install torch

* Activate MyPy in ignite.contrib.engines (pytorch#1416)

* Activate mypy in ignite.contrib.engines

* Fix review comments

* fix extra event too

* Update to fix strict errors

* Update quickstart.rst (pytorch#1460)

* Update quickstart.rst

Plz have a look if I am going correct or not. ###rewording sentences to simplify the understanding

* Update docs/source/quickstart.rst

Co-authored-by: vfdev <[email protected]>

* Update quickstart.rst

* Update quickstart.rst

* Update docs/source/quickstart.rst

Co-authored-by: vfdev <[email protected]>

* Update quickstart.rst

Final commit is done. You can review it.

Co-authored-by: vfdev <[email protected]>

* [docs] intersphinx update in conf.py

* [docs] add missing function in handlers docs (pytorch#1463)

* Update setup.cfg

* [docs] missing function in handlers docs

* [docs] add ignite favicon (pytorch#1462)

* Update setup.cfg

* [docs] add ignite favicon

* Add missing classes and links for docs (pytorch#1461)

* Update CONTRIBUTING.md

* Update concepts.rst (pytorch#1465)

* setup toml, yaml, prettier in pre-commit (pytorch#1468)

* Update setup.cfg

* [pre-commit] setup yaml in pre-commit hook

* [pre-commit] setup toml prettier

* [docs] make GIF look good on mobile (pytorch#1470)

* Update setup.cfg

* [docs] make gif fit on mobile

* Update index.rst

* use .. raw:: html

* Update index.rst

Co-authored-by: vfdev <[email protected]>

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* [docs] add submodule in engine.rst (pytorch#1464)

* Update setup.cfg

* [docs] add submodule in engine

* [docs] add suggestions, contrib engine docs and 45% width

* Update ignite_theme.css

* [metrics] speed up SSIM tests (pytorch#1467)

* Update setup.cfg

* [metrics] update ssim

* use np.allclose instead of torch.allclose

* Apply suggestions from code review

* extract into _test_ssim

* extract into scripts

* fix path

* fix path

* fix path

* good to go!

* [ci] universal conda build (pytorch#1471)

* Update setup.cfg

* rm conda_build_config

* rm conda_build_config

* Update docs.yml

* Update install_docs_deps.sh

Co-authored-by: vcarpani <[email protected]>
Co-authored-by: Anton Grübel <[email protected]>
Co-authored-by: Harsh Patel <[email protected]>
Co-authored-by: Théo Dumont <[email protected]>
Co-authored-by: Sylvain Desroziers <[email protected]>
Co-authored-by: Desroziers <[email protected]>
Co-authored-by: rex_divakar <[email protected]>
Co-authored-by: Benjamin Kinga <[email protected]>
Co-authored-by: Taras Savchyn <[email protected]>
Co-authored-by: trsvchn <[email protected]>
Co-authored-by: RaviTeja Pothana <[email protected]>
Co-authored-by: Josseline Perdomo <[email protected]>
Co-authored-by: Sai Sandeep Mutyala <[email protected]>
Co-authored-by: Ramesht Shukla <[email protected]>
Co-authored-by: botbotbot <[email protected]>
Co-authored-by: Jeff Yang <[email protected]>
Co-authored-by: Sergey Epifanov <[email protected]>
Co-authored-by: sdesrozis <[email protected]>
Co-authored-by: zhxxn <[email protected]>
Co-authored-by: François COKELAER <[email protected]>
Co-authored-by: thescripted <[email protected]>
Co-authored-by: vfdev-5 <[email protected]>
Co-authored-by: Rostyslav Zatserkovnyi <[email protected]>
Co-authored-by: Afzal <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Automatic docker build and publishing
2 participants