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

About the module train #32

Open
xxxmmm00 opened this issue Mar 23, 2022 · 7 comments
Open

About the module train #32

xxxmmm00 opened this issue Mar 23, 2022 · 7 comments

Comments

@xxxmmm00
Copy link

Hello!Do you train your model on GPU? During training, I found that the code only runs on the CPU. Now I want to put the code on the GPU. Is there any way?

@sharathadavanne
Copy link
Owner

If you have a compatible GPU, Keras should automatically train on it.
Check this issue - https://stackoverflow.com/questions/45662253/can-i-run-keras-model-on-gpu

@xxxmmm00
Copy link
Author

Thank you very much for your help

@xxxmmm00
Copy link
Author

Sorry, now the code can run on GPU, but the computer memory occupation rate increases gradually with the code running until it crashes. I can't solve this problem. Is there any way to effectively solve this problem?

@muuda
Copy link

muuda commented Apr 6, 2023

Sorry, now the code can run on GPU, but the computer memory occupation rate increases gradually with the code running until it crashes. I can't solve this problem. Is there any way to effectively solve this problem?

Hello, can you tell me how to train with gpu? I have been groping for a day without solving this problem. My Python version is 3.7 and cuda version is 11.2. What version should I use for tensorflow and keras? Is an updated version required? Do I need to change the code after updating the version? Thank you very much for your help!!!

@xxxmmm00
Copy link
Author

xxxmmm00 commented Apr 6, 2023

Because it has been a long time, I can't remember clearly. You need to download the GPU version of TensorFlow and the corresponding cudatoolkit version, and the model code can be trained on the GPU without making changes. The code definitely needs to be changed. If you have configured a higher version of TensorFlow, corresponding solutions to these issues can be found in other communities.

@muuda
Copy link

muuda commented Apr 6, 2023

Because it has been a long time, I can't remember clearly. You need to download the GPU version of TensorFlow and the corresponding cudatoolkit version, and the model code can be trained on the GPU without making changes. The code definitely needs to be changed. If you have configured a higher version of TensorFlow, corresponding solutions to these issues can be found in other communities.

Thank you! I will try it

@muuda
Copy link

muuda commented Apr 30, 2023

Sorry, now the code can run on GPU, but the computer memory occupation rate increases gradually with the code running until it crashes. I can't solve this problem. Is there any way to effectively solve this problem?

Sorry to bother you again. I also encountered this problem. How did you solve it at that time? Thank you very much for your help.

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

3 participants