Skip to content

F821 undefined name 'keras' #21287

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

Open
wrpalaia opened this issue May 15, 2025 · 2 comments
Open

F821 undefined name 'keras' #21287

wrpalaia opened this issue May 15, 2025 · 2 comments

Comments

@wrpalaia
Copy link

wrpalaia commented May 15, 2025

##[debug]Evaluating condition for step: 'Lint with flake8'
##[debug]Evaluating: success()
##[debug]Evaluating success:
##[debug]=> true
##[debug]Result: true
##[debug]Starting: Lint with flake8
##[debug]Loading inputs
##[debug]Loading env
Run # stop the build if there are Python syntax errors or undefined names
##[debug]/usr/bin/bash -e /home/runner/work/_temp/a13946[2](https://github.com/wrpalaia/neuralforest/actions/runs/15050291809/job/42303699780#step:5:2)8-0932-4995-95df-3317c85c626f.sh
./train.py:7[3](https://github.com/wrpalaia/neuralforest/actions/runs/15050291809/job/42303699780#step:5:3):9: F821 undefined name 'keras'
    y = keras.utils.to_categorical(y_original, num_classes=n_classes)
        ^
1     F821 undefined name 'keras'
1
Error: Process completed with exit code 1.
##[debug]Finishing: Lint with flake[8](https://github.com/wrpalaia/neuralforest/actions/runs/15050291809/job/42303699780#step:5:8)
@sachinprasadhs
Copy link
Collaborator

Have you installed Keras and importing Keras in your env?

Can you provide some sample reproducible code to replicate the reported behavior. Thanks!

@wrpalaia
Copy link
Author

I have deleted everything and will try again. This is a novel design. I expect "issues".

Thank you.

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

No branches or pull requests

2 participants