caillonantoine / msprior

155 stars 10 forks source link

method prior not found ! #8

Open robinmeier opened 1 year ago

robinmeier commented 1 year ago

i trained my prior with

msprior train --config decoder_only --db_path /home/prod/rave2/RAVE/runs/laoprior/ --name laos-market-1-prior --pretrained_embedding /home/prod/rave2/RAVE/runs/laos-market-1_fe77618ebd/laos-market-1_fe77618ebd.ts

and exported it with

msprior export --run /home/prod/rave2/RAVE/runs/laos-market-1-prior/ --continuous

but when i load the model in nn~ i get the following error

method prior not found ! and method decode not found !

is exporting for real-time use in max possible? amidoinitright? the underlying model laos-market-1_fe77618ebd_streaming.ts seems to be working ok (just rave, not msprior) with nn~

futile-device commented 1 year ago

I am having a similar problem.

I have used the following steps:

  1. Trained a RAVE model using v3/wasserstein (which works fine in Max when exported with streaming)
  2. Exported the model without streaming: rave export --run /notebooks/content/training/runs/NK_DISC_02_f2269a85fa --nostreaming
  3. Preprocessed the audio for msprior: msprior preprocess --audio NKORE_CHUNKS_AUDIO --out_path ./NKORE_PRIOR_DATA2 --rave NK_DISC_02.ts
  4. Trained the msprior model:msprior train --config recurrent --db_path ./NKORE_PRIOR_DATA2 --name NK_PRIOR_04 --pretrained_embedding ./NKORE_PRIOR_DATA2/NK_DISC_02.ts
  5. Exported the msprior model: msprior export --run /notebooks/runs/NK_PRIOR_04 --continuous --batch_size 64

This produces a .ts file, but it only has the 'forward' method ie., not only does it not have a 'prior' method, it no longer has a 'decode' or 'encode' method!!

One log line that may be relevant is:

W1013 09:05:48.906991 140217669043008 attention.py:370] pretrained_embedding is only compatible with discrete rave models, skiping

Which happens both during train and export.

I thought this might have been due to training with v3, so I tried again using a RAVE model trained with discrete/wasserstein config but had exactly the same problem: same log line about not being compatible with pretrained_embeddings and no 'prior', 'encode' or 'decode' methods once exported.

futile-device commented 1 year ago

For those that come after:

Thanks to ZZ on the RAVE Discord I believe I got confused by looking at a version of the Max nn~ help patch which uses 'prior' as the method, but as of this version of msprior (1.1.3) the patch setup is different - it's as per the image in the readme.md now.