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

Prediction failure with training models generated with icenet<0.2.7 #59

Open
bnubald opened this issue Jan 6, 2025 · 0 comments
Open
Assignees
Labels
bug Something isn't working
Milestone

Comments

@bnubald
Copy link
Contributor

bnubald commented Jan 6, 2025

The following issue needs accounting for in the prediction scripts:

icenet-ai/icenet#236

Error copied across from this issue:

[10-04-24 12:19:04 :DEBUG   ] - Creating converter from 3 to 5
Traceback (most recent call last):
  File "/data/hpcdata/users/jambyr/miniconda3/envs/icenet/bin/icenet_predict", line 33, in <module>
    sys.exit(load_entry_point('icenet', 'console_scripts', 'icenet_predict')())
  File "/data/hpcdata/users/jambyr/icenet/icenet2/icenet/model/predict.py", line 198, in main
    predict_forecast(
  File "/data/hpcdata/users/jambyr/icenet/icenet2/icenet/model/predict.py", line 66, in predict_forecast
    network.load_weights(network_path)
  File "/data/hpcdata/users/jambyr/miniconda3/envs/icenet27/lib/python3.8/site-packages/keras/src/utils/traceback_utils.py", line 70, in error_handler
    raise e.with_traceback(filtered_tb) from None
  File "/data/hpcdata/users/jambyr/miniconda3/envs/icenet27/lib/python3.8/site-packages/keras/src/backend.py", line 4361, in _assign_value_to_variable
    variable.assign(value)
ValueError: Cannot assign value to variable ' conv2d_8/kernel:0': Shape mismatch.The variable shape (3, 3, 368, 736), and the assigned value shape (737, 368, 3, 3) are incompatible.

This needs a legacy flag (-l) added as an argument for the following statement if trying to run prediction with a training model generated using icenet<0.2.7:

icenet_predict -v -n {{ run.arg_filter_factor }} $PREDICT_STATIC_ARGS \{% if run.arg_testset == "true" %}

Issue is caused by a change in rounding in convolution operation in v0.2.7.

@bnubald bnubald added the bug Something isn't working label Jan 6, 2025
@bnubald bnubald added this to the v0.2.9 milestone Jan 6, 2025
@bnubald bnubald self-assigned this Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant