-
Notifications
You must be signed in to change notification settings - Fork 74
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
How to load a pytorch model with model analyzer #699
Comments
Hi @benhgm, by default when Model Analyzer is run |
Hi @tgerdesnv thanks for the tip! To clarify, the command that gives the 'ModuleNotFoundError' error does not include the To provide some context, Maybe my experience with docker is still not so good, but here are some questions I have:
Thanks for your time and help, greatly appreciate it. |
Support for custom local docker images was not added unit the 23.03 release. Can you try running on that (or a newer version) and let me know if you are still seeing an issue. Thanks. |
Hi @nv-braf I have changed to use the 23.03 release. When I start up the local docker image instance, I get an error in my triton log file,
|
@benhgm Are you able to move to a newer version of triton server, ideally 23.03 to match your SDK version (or move both to the latest 23.05 release)? As you have observed, using different versions between the two can cause incompatibilities. |
@tgerdesnv thanks for the advice! I tried that and was able to run a full analysis on my ensemble model. I got some very nice results and report, but there is now one small error/glitch that I see, where the model analyzer reported that From the message, I guess this is because I ran the analysis over a multi-GPU instance, and if I set the --gpus flag to a specific GPU UUID, I will be able to get these metrics. I will try it out and update if I face the same error. Otherwise, how can I enable GPU metrics reporting even on a multi-GPU instance? |
This warning occurs when a measurement returning from Perf Analyzer does not contain a GPU metric, in this case, the amount of memory used by the GPU, when it was expected. |
@nv-braf hello, I tried by setting |
Are measurements being taken? Are the charts/data being outputted correctly at the end of profile? If so, then it's probably safe to ignore this warning message. |
Have you specified CPU_ONLY anywhere in the original configuration? Do the resulting output model configurations have KIND_CPU or KIND_GPU under My concern if you are getting no GPU metrics is that nothing is actually running on the GPU. |
Hi @tgerdesnv you make a good point. I realised that although I had put KIND_GPU for all my models, in my pre and post-processing models, I did not explicitly pass the models to GPU using a However, my main inference model (a CNN) has always been set to run in GPU. Which I am puzzled over as to why no GPU metrics were recorded for that. |
Can you answer @nv-braf 's question? Are measurements being taken? Are the charts/data being outputted correctly at the end of profile? If so, then it's probably safe to ignore this warning message. Those warnings may show up if any of the models are running entirely on the CPU. |
Hi @tgerdesnv @nv-braf my apologies, I missed out on the other question. Yes I am getting measurements on the latency and throughput, those are fine. I was just wondering how to make the GPU metrics appear. @tgerdesnv I understand what you mean. However, if in an ensemble model, for example, where I have a pipeline of pre processing model -> CNN -> post processing model and only the CNN is on GPU, should I expect GPU metrics to be recorded from the CNN side even though the pre and post processing models are on CPU? |
As long as you have not set the |
Hi @nv-braf yes I confirm that I did not use the |
i am running the examples/add_sub with local model , and with cpu instances but i am getting follwoing error log in docker container root@cfbe7ff7cf1e:/app/ma# model-analyzer profile |
Hi, I am trying to use model analyzer to analyze an ensemble model that contains two python models and 1 ONNX model. The python models using pytorch to perform some preprocessing and postprocessing functions.
However, when I use the following command, I get a "ModuleNotFoundError: no module named 'torch'" error.
model-analyzer profile \ --model-repository=/model_repository \ --profile-models=ensemble_model --triton-launch-mode=docker \ --triton-http-endpoint=localhost:8000 --triton-grpc-endpoint=localhost:8003 --triton-metrics-url=localhost:8002 \ --output-model-repository-path=/model_analyzer_outputs/ \ --override-output-model-repository \ --run-config-search-mode quick \ --triton-output-path triton_log.txt \ --triton-docker-image devel
How do i make sure that the docker container spun up by model analyzer has pytorch installed?
The text was updated successfully, but these errors were encountered: