Skip to content
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 run GPU trained caffe model in CPU mode? #15

Open
AmarendarAndhe opened this issue May 12, 2021 · 0 comments
Open

How to run GPU trained caffe model in CPU mode? #15

AmarendarAndhe opened this issue May 12, 2021 · 0 comments

Comments

@AmarendarAndhe
Copy link

Hi,

I have used caffe framework for training text detection model using GPU mode. There are 4 such models are running simultaneously for 4 different use-cases. Running more than 2 models giving me CUDA memory error, so i increased compute power of my AWS EC2 instance to g4dn.12xlarge which costing me much higher and it is going beyond my budget.

So i am trying to inferencing this GPU trained caffe model to run in CPU mode and throw output so that my cost will be minimum. Please note training the model in GPU mode is done, i just wanted to use this model to run in CPU mode or CPU EC2 instance and get the output.

I tried below option:

Step 1:
Made changes in file "psroi_pooling_layer.cpp" as mentioned in below link and saved it.
https://github.com/daijifeng001/caffe-rfcn/pull/10/files

Step 2:
Set "caffe.set_mode_cpu()" and ran the script and getting error like "check failure stack trace"
Changes in code:
image

Error screen-shot:
image

Please let me know where I am doing wrong or do I need to perform some additional steps?

Your quick response and help will be much appreciated.

Thank you,
Amar

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant