Conchylicultor / MusicGenerator

Experiment diverse Deep learning models for music generation with TensorFlow
Apache License 2.0
324 stars 80 forks source link

Finds no model #6

Open Eumi opened 7 years ago

Eumi commented 7 years ago

I get this error when i type in "main.py --test --sample_length 500"

Warning: No model found in 'C:\save/model'. Please train a model before trying to predict The End! Thanks for using this program

but theres something in there..i allready trained it and it saved ..and theres something in the folder =/ pls help im so close.

Conchylicultor commented 7 years ago

What is the content of C:\save/model exactly ?

Eumi commented 7 years ago

the folders "progression, test and train" than files named "checkpoint", "model.ckpt.data-00000-of-00001","model.ckpt.index" , "model.ckpt.meta" and "params"

"model.ckpt.data-00000-of-00001" , shouldnt that be a higher number? i let it run to 4000 epochs . In "progression" are files named "4000-test-0" and so on.

Eumi commented 7 years ago

my training data in cmd looksl ike this.

------- Epoch 5 (lr=0.0001) ------- Subsampling the songs (train)... Shuffling the dataset... Generating batches... Subsampling the songs (test)... Shuffling the dataset... Generating batches... Training: 100%|##########################################################################| 1/1 [00:02<00:00, 2.07s/it] Epoch finished in 0:00:02.071642

Eumi commented 7 years ago

also when i delete the "save" folder from C:\ i get the error message File "C:\python35\lib\site-packages\tensorflow\python\framework\errors_impl.py", line 469, in raise_exception_on_not_ok_status pywrap_tensorflow.TF_GetCode(status)) tensorflow.python.framework.errors_impl.NotFoundError: Failed to create a directory: C:/save/model\train

i did that by hand and created the folder model (in save folder) and opened it ....and in the folder model i created train ...than i run main.py and it puts stuff in it. ...maybe that is an error as well idk ...i have no idea of programming sry =,O

i really hope you can help me with this hopefully last problem! I also made an administrator account and it failed....than i tried to change root_dir but it has the same error =,O

seriously, i would be so grateful if u know how i can fix this =)

Eumi commented 7 years ago

same problem with linux .... but i figured out my graphic card is not this ..3.0 ready for cuda ..wich it would need to run it =O only 2.3 or so ..is that the problem?

Conchylicultor commented 7 years ago

I think there is a bug with this version of the program due to TF 1.0 new saver format.

On Tue, Apr 11, 2017, 19:57 Eumi notifications@github.com wrote:

same problem with linux .... but i figured out my graphic card is not this ..3.0 ready for cuda ..wich it would need to run it =O only 2.3 or so ..is that the problem?

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/Conchylicultor/MusicGenerator/issues/6#issuecomment-293346839, or mute the thread https://github.com/notifications/unsubscribe-auth/AIoNO1yV1kRkMg5JdKWSGFGvW5raf7joks5ru78ZgaJpZM4M5bAB .

Eumi commented 7 years ago

so i cant do anything? or do i need to use another version of tensorflow and than its fixed? i just have it installed for this program only

Conchylicultor commented 7 years ago

You can try this hack: create an empty file named "model.ckpt" inside the "save/model/" directory where your model files are.

Even if this works, I think you're putting too​ much effort into this. You can only be disappointed when you will see the results, as I already told you.

On Tue, Apr 11, 2017, 20:29 Eumi notifications@github.com wrote:

so i cant do anything? or do i need to use another version of tensorflow and than its fixed? i just have it installed for this program only

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/Conchylicultor/MusicGenerator/issues/6#issuecomment-293357854, or mute the thread https://github.com/notifications/unsubscribe-auth/AIoNO37XzujyMyRXPGHci6pfDeyZzv5Xks5ru8aSgaJpZM4M5bAB .

Eumi commented 7 years ago

HAHA !! it works =D im so lucky thanks <3 ..you are right the output is not so good for now ...but it definitely does something ... i had a look at the midi files (one of them) and it definitely looks like chords ...i am impressed and very thankful for your help =D ( i saved my progress before i started to play around with it, and imported it back) this is awesome...and only the fact that it is working now is already a relief =) i will try different inputs with it (already figured out a way how i can download midi files and edit them so the program imports them =) ) great work! thumbs up for u!

erikamenezes commented 7 years ago

Creating the model.ckpt file leads to some music being generated. But what does this mean? Is it learning from the files that have been used for training? Shouldn't it be using the checkpoint file that has been saved during training instead?

patalanov commented 6 years ago

@erikamenezes yes, this is frustrating. it is a beautiful program, but it goes to waste when saver format is outdated. the owner should update it.

on composer.py I've changed this constant:

self.MODEL_EXT = '.meta'

and inside _main_test() (line 327), I did this:

saver = tf.train.import_meta_graph('save/model/model.ckpt.meta')
saver.restore(self.sess, tf.train.latest_checkpoint('save/model/.'))

this seems to work, still depending on further investigation on results.

my tensorflow version for this environment is 1.2, and some minor tweaks in tf syntax were also necessary.