Closed nakuldes closed 1 year ago
The context for this commit can be found here: https://github.com/gramineproject/examples/pull/52
Looks like you're using an old version of PyTorch/TorchVision?
We are using the default version comes with 18.04 and centos as well as RHEL. It passes for Ubuntu 20.04 & Ubuntu 22.04 but fails for all other configurations
So what do we do? Revert that change? What would be a good way to fix this warning and preserve the behavior for older versions of PyTorch?
I wouldn't care, we're dropping 18.04 support now and also, these are only examples. If someone insists on using outdated software then they can just use that older commit which works on 18.04 ¯\_(ツ)_/¯
@mkow
It is not they are using outdated software, and this issue is only limited to Ubuntu 18.04.
This issue is among Ubuntu 18.04, Centos 8 and RHEL as well, and they come with Python3.6 In order to upgrade torchvision, we also need to upgrade Python as well. the latest version of torchvision requires Python3.7 and above
It is not they are using outdated software
Ubuntu 18.04, Centos 8
...?
Looks like the really correct solution would be to check the version of torchvision
(in that download-pretrained-model.py
Python script), and based on the version (a) do the old stuff, (b) do the new stuff.
This change will go in v1.5 version where we will not have support for Ubuntu 18.04, IMO, that should be fine. We see the same issue in Curated-Apps also that we can fix by using example repo v1.4
This change will go in v1.5 version where we will not have support for Ubuntu 18.04, IMO, that should be fine.
But the problem seems to be with CentOS 8 and RHEL 8. And RHEL 8 has end-of-life in 2031 (!) for example: https://access.redhat.com/product-life-cycles/?product=Red%20Hat%20Enterprise%20Linux,OpenShift%20Container%20Platform%204
So it looks like we do need to support the older version of PyTorch/TorchVision.
And RHEL 8 has end-of-life in 2031
This doesn't mean that we'll support RHEL for the next 9 years. We support only decently modern distros.
This doesn't mean that we'll support RHEL for the next 9 years. We support only decently modern distros.
Well, I don't know, the currently discussed snippet (the required change to support both old and new PyTorches) is ~5 lines of code. It's such a small matter, and it breaks PyTorch + Gramine for more than one folks, that we could support it.
Let me just submit a PR that does it.
Here is my trivial PR: https://github.com/gramineproject/examples/pull/56
@anjalirai-intel Could you test my PR?
@mkow @jkr0103 What do you think? Looks like a trivial change.
@dimakuv I validated the PR and we were able to download successfully and run pytorch. Tested it across Ubuntu 18.04, Ubuntu 20.04, CentOS 8 & RHEL. It was successful.
LGTM
Well, I don't know, the currently discussed snippet (the required change to support both old and new PyTorches) is ~5 lines of code. It's such a small matter, and it breaks PyTorch + Gramine for more than one folks, that we could support it.
If you want to spend time on this then ok, but 18.04 and similar will break in a moment anyways, because Gramine is dropping support for them.
...but 18.04 and similar will break in a moment anyways, because Gramine is dropping support for them.
Hm. I feel like we'll make many people unhappy about it (and I'm mainly thinking RHEL 8 now). On the other hand, this will be about Gramine dependencies, and there should be workarounds in those old distros. So we'll make life harder for people who use RHEL 8, but I guess they'll still be able to use newer Gramine versions (albeit with some tricks).
With recent commit https://github.com/gramineproject/examples/commit/2e41bcd1d1887a364fced4bd220e654c9ae41ff0 We're not able to download model for pytorch. It fails with below error
python3 download-pretrained-model.py
On reverting the changes back, the model is getting successfully downloaded. python3 download-pretrained-model.py