windows 10 pro: try to run torchserve, get Could not find or load main class org.pytorch.serve.ModelServer
Brand new win10 pro install install pre-requisites
build .mar for densenet
attempt to run: torchserve --start --ncs --model-store model_store --models densenet161.mar
C:\Users\lessw>Error: Could not find or load main class org.pytorch.serve.ModelServer Caused by: java.lang.ClassNotFoundException: org.pytorch.serve.ModelServer
Versions:
java -version java version "1.8.0_251" Java(TM) SE Runtime Environment (build 1.8.0_251-b08) Java HotSpot(TM) Client VM (build 25.251-b08, mixed mode)
import torch torch.version '1.5.0'
Did see a number of issues related to this, but all seem to be related to running buildable version. I did pip install for all items.
@lessw2020 : TorchServe is currently certified on Ubuntu and MacOS only.
True, but PyTorch 1.50 works perfectly on it and I don't think this issue is Windows specific.
WSL2 is available on WinPro and docker images build and work fine.
You can close it as OS not supported if there is no plan to support Windows (though again, why have PyTorch support Windows but not PyTorch serve? :)
True, but PyTorch 1.50 works perfectly on it and I don't think this issue is Windows specific. WSL2 is available on WinPro and docker images build and work fine. You can close it as OS not supported if there is no plan to support Windows (though again, why have PyTorch support Windows but not PyTorch serve? :)
@lokeshgupta1975 @chauhang - Could you please comment here.
I guess this is turning into two items but for some feedback:
1 - Is there a script or similar I can run to attempt to build/instantiate the missing class? (that would delimit if it's really an OS issue).
2 - To be clear, I'm not planning to deploy on Windows, but given that PyTorch works perfectly on Windows (vs Mac has zero Nvidia GPU support), I still expect I can test run and code against PyTorch serve models on same machine to prep for deployment on AWS.
I do have a Mac, but making it so PyTorch goes end to end from dev/train/deploy-prep without flipping from Windows for GPU support to train, then to Mac for Serve support to prep the Serve model, and then to AWS/linux for production would be obviously a better story.
Thanks much!