serve icon indicating copy to clipboard operation
serve copied to clipboard

install torchserve from repository (pytorch/torchserve:0.5.3-cpu version mismatching issue)

Open klae01 opened this issue 2 years ago • 2 comments

Description

In the current implementation, at the time of docker build, a Docker image with the latest version of torchserve installed is created regardless of the version of the repository.

I change implementations to install torchserve from source.

Fixes https://github.com/pytorch/serve/issues/1736

Type of change

  • [x] Bug fix (non-breaking change which fixes an issue)

Feature/Issue validation/testing

Compare the expected torchserve version and torchserve version of docker images obtained using pip list|grep "torchserve "|awk '{printf $2}'.

Checklist:

  • [x] Did you have fun?
  • [ ] Have you added tests that prove your fix is effective or that this feature works?
  • [ ] Has code been commented, particularly in hard-to-understand areas?
  • [ ] Have you made corresponding changes to the documentation?

klae01 avatar Jul 18 '22 08:07 klae01

Thank you! Two quick comments here, we probably need same solution to work for workflow and model archiver as well, I see in your pip list the latest version of model archiver is there

The other point is at this point I'm not sure why we need several dockerfiles and am wondering if we can converge on a single one and keep binary sizes small using multi stage builds

msaroufim avatar Jul 18 '22 16:07 msaroufim

I add install torch-model-archiver part as well. I think the link to the homepage at pypi needs to be updated. I didn't know where to install this until I checked the link.

And the second point you want is that the binary size to be small while single-stage build, right? (I'm not sure if I understand correctly) In my experiments on this case, I found that build without multi-stage was a few MB larger. If the current docker file in maintenance is not a problem as a legacy, I think you can leave it.

klae01 avatar Jul 19 '22 09:07 klae01

Actually after looking at this more closely this is fine, we recommend our dev images for developers

msaroufim avatar Oct 03 '22 02:10 msaroufim