Giter VIP home page Giter VIP logo

Comments (6)

titu1994 avatar titu1994 commented on August 11, 2024

The dataset is a available, but you are trying to evaluate a model without first training it, so it cannot find the weight file.

You need to uncomment the train function and train a model first.

from mlstm-fcn.

joe-hu avatar joe-hu commented on August 11, 2024

Thank you for your help! i uncommented hte train function in arem_model , however i got the same error:
Train on 43 samples, validate on 39 samples
Epoch 1/600

  • 8s - loss: 2.1344 - acc: 0.1163 - val_loss: 1.1761 - val_acc: 0.4615

Epoch 00001: loss improved from inf to 2.13436, saving model to ./weights/AReM_weights.h5
Traceback (most recent call last):
File "E:/program/MLSTM-FCN-master/arem_model.py", line 195, in
train_model(model, DATASET_INDEX, dataset_prefix='AReM', epochs=600, batch_size=128)
File "E:\program\MLSTM-FCN-master\utils\keras_utils.py", line 162, in train_model
class_weight=class_weight, verbose=2, validation_data=(X_test, y_test))
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\keras\engine\training.py", line 1039, in fit
validation_steps=validation_steps)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\keras\engine\training_arrays.py", line 217, in fit_loop
callbacks.on_epoch_end(epoch, epoch_logs)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\keras\callbacks.py", line 79, in on_epoch_end
callback.on_epoch_end(epoch, logs)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\keras\callbacks.py", line 444, in on_epoch_end
self.model.save_weights(filepath, overwrite=True)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\keras\engine\network.py", line 1120, in save_weights
with h5py.File(filepath, 'w') as f:
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\h5py_hl\files.py", line 394, in init
swmr=swmr)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python37\lib\site-packages\h5py_hl\files.py", line 176, in make_fid
fid = h5f.create(name, h5f.ACC_TRUNC, fapl=fapl, fcpl=fcpl)
File "h5py_objects.pyx", line 54, in h5py._objects.with_phil.wrapper
File "h5py_objects.pyx", line 55, in h5py._objects.with_phil.wrapper
File "h5py\h5f.pyx", line 105, in h5py.h5f.create
OSError: Unable to create file (unable to open file: name = './weights/AReM_weights.h5', errno = 2, error message = 'No such file or directory', flags = 13, o_flags = 302)

i am looking forward for your help

from mlstm-fcn.

titu1994 avatar titu1994 commented on August 11, 2024

Try creating a directory called weights and training a model then.

from mlstm-fcn.

joe-hu avatar joe-hu commented on August 11, 2024

thank you for your kind reply. i am a newbie in Python. Could you please point me to create a directory called weights in detail. i have no ideal about it.

from mlstm-fcn.

titu1994 avatar titu1994 commented on August 11, 2024

The weights cannot be created because there is no weights folder at the root of the project. Just create a new folder called weights.

from mlstm-fcn.

joe-hu avatar joe-hu commented on August 11, 2024

it worked for me! thank you very much!

from mlstm-fcn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.