error when running the example.
daxiongshu opened this issue · comments
Thank you very much for the doc and codes. I have this error when running the example, uci_census.py.
python uci_census.py --run=train --model_type=calibrated_linear --output_dir=. --quantiles_dir=. --train_epochs=600 --batch_size=1000 --hparams=learning_rate=1e-2
And I got this error:
tensorflow.python.framework.errors_impl.NotFoundError: ./quantiles/age.txt
I made a dir quantiles
but I can't figure out what is the age.txt coming from.
I placed the adult.data/test in the same dir as the .py file and changed the default train/test path.
Thank you very much!
Hi! Did you create quantiles statistics? Before running the above command, try this first
python uci_census.py --run=train --model_type=calibrated_linear --output_dir=. --quantiles_dir=. --train_epochs=600 --batch_size=1000 --hparams=learning_rate=1e-2 --create_quantiles
This is only needed when you run the script first time. After that, you don't need to add --create_quantiles flag anymore, and quantiles statistics should be available under ./quantiles directory.
The comment in the docstring
https://github.com/tensorflow/lattice/blob/master/examples/uci_census.py
actually explains why we need to do this :).
Could you try again?
Yeah, It works! Thank you very much!
Sorry for missing this important information in the comments.
Best regards,
No worries! Glad that it works!!