-
Notifications
You must be signed in to change notification settings - Fork 283
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
Trouble with compiling my keras_model_sequential() #1421
Comments
We no longer recommend installing keras with conda - please run the following commands to install keras (please note the '3' in 'keras3'): install.packages("keras3")
## or, to install the development version
# remotes::install_github("rstudio/keras")
reticulate::install_python()
keras3::install_keras() There is no need to call The S3 classes of the keras objects can change between releases, and the most likely cause of the issue is that there is a mismatch between the version of the R package installed, and the version of the underlying keras package. |
When i try this method it stops at reticulate::install_python() with the following error:
The Way i am installing it right now is the only thing that has worked so far... |
Can you install git as the error message suggests? https://git-scm.com/download/win Alternatively, you can install python manually from www.python.org/downloads. Note that the latest release is still too new for the backends, python 3.11 is the latest that is supported. |
So i tried everything, and your way of installing works as well. But now i see that more often than not i get this error when i try to create a model:
This is very frustrating, because its difficult to recreate this error, as sometimes when i install everything the first, or first couple of models work, but when i recreate the same models without changing the code, they suddenly turn up this error.... Have you ever seen this before? Do you have any ideas what could be the cause of this? |
This is my Traceback: `── Python Exception Message ──────────────────────────────── ── R Traceback ─────────────────────────────────────────────
See
[[2]] [[3]] [[4]] [[5]] [[6]] [[7]] [[8]] [[9]] [[10]] [[11]] |
This error was fixed with a recent release of Also, for new code today, I'd recommend using |
Automatically closed because there has not been a response for 30 days. When you're ready to work on this further, please comment here and the issue will automatically reopen. |
Hey, i am fairly new to keras on R. I am now working through the Deep Learning with R book and in the first couple of chapters there is already a load of Errors for me.
So ive figured out how to install keras and tensorflow, like this:
Then i can import the mnist dataset normally.
After this i use the
keras_model_sequential()
function like this:When i then try to compile() it the following error code appears:
So i figured that the class which is produced by my
keras_model_sequential()
must be different from keras.engine.training.Model, which would be expected as per documentation.When i call
summary(model1)
the following appears:When i call
class(model1)
there are multiple results:How do i get
keras_model_sequential()
to produce the correct class? I figure thats my problem.. Or what else could be my problem?The text was updated successfully, but these errors were encountered: