Instally Pytorch with Caffe2

Hi Pytorch Community,

What I’m looking to do is probably a little unconventional but it’s for my fourth year project and I know it’s possible but just want to know the best way of going about it.

Basically, I have exported a pytorch model in caffe2 format that I now want to run inferences within an AWS Lambda function. I came across some articles online that said it is possible to install pytorch with caffe2 inside it that will work with python 3.x.

I see that the installer tool tells me to install “pip install torch==1.7.1+cpu torchvision==0.8.2+cpu torchaudio===0.7.2 -f https://download.pytorch.org/whl/torch_stable.html” but does this come with caffe2? Once I ran this and then tried to install caffe2 I was getting errors correlating with pytorch not being installed properly but install pytorch through pip worked smoothly