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

Loading model fails for book/06.label_semantic_roles #1887

Closed
sanjaymeena opened this issue Apr 25, 2017 · 9 comments
Closed

Loading model fails for book/06.label_semantic_roles #1887

sanjaymeena opened this issue Apr 25, 2017 · 9 comments

Comments

@sanjaymeena
Copy link

Hello,

  • docker image : paddlepaddle/paddle:0.10.0rc3
  • demo : book/06.label_semantic_roles

Issue : Can train model successfully using the provided train.py and the program saves the parameters.
I tried loading the saved parameters using :

from  paddle.v2.parameters import  Parameters 
f="params_pass_2.tar.gz"
parameters=Parameters.from_tar(f)

It fails with following error :
image

@luotao1
Copy link
Contributor

luotao1 commented Apr 25, 2017

you can use following codes to load the saved parameters:

with gzip.open('params.tar.gz', 'r') as f:
    parameters = Parameters.from_tar(f)

@sanjaymeena
Copy link
Author

Hi, I am training a Semantic role labeling model on 20k chinese sentences in CONLL2005 format.

docker image : paddlepaddle/paddle:0.10.0rc3
demo : book/06.label_semantic_roles

I am getting following error . Can you help me decipher what may be going wrong. I checked and data format is correct and works for small amount of data ~100 sentences.

image

@gangliao
Copy link
Contributor

gangliao commented Apr 27, 2017

Hi, @sanjaymeena

Why not fetch book docker image directly ?https://github.com/PaddlePaddle/book/blob/develop/README.en.md

In this book image, 06.label_semantic_roles has already been verified.

@sanjaymeena
Copy link
Author

sanjaymeena commented Apr 28, 2017

I had tried following images few times before as well just now :

  • docker.paddlepaddle.org/book
  • docker.paddlepaddle.org/book:0.10.0rc2

I get the same error no module named evaluator :( what is the solution for this?

image

@gangliao
Copy link
Contributor

gangliao commented Apr 28, 2017

please fetch docker.paddlepaddle.org/book:0.10.0rc3, I update it now.

@sanjaymeena You can also run Jupter notebook, because our regression test only covers *.ipynb

@sanjaymeena
Copy link
Author

okay. I will try the jupyter notebook as it is still giving me following error :
image

  • I wanted to share that this error is systematic and is occurring when the sentence is the last sentence in the data. The train.py runs till the end of the file data and then while loading next batch throws me the error.
  • I will have double checked the conll05 format of my data and it is the same as present in demo program. I will try jupyter to make sure if it is related to paddle or my data.
    Many thanks for prompt response! have been stuck since many days :(

@sanjaymeena
Copy link
Author

@gangliao I can run the train.py with my data. Turns out problem was with some syntax in data. Thanks for updated book:0.10.0rc3.

@sanjaymeena
Copy link
Author

Hi, I still got this error using : book:0.10.0rc3. This was after 26th pass. So probably means something wrong with framework??

image

@wanghaoshuang
Copy link
Contributor

About float point exception: #3076

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

No branches or pull requests

5 participants