bi-att-flow icon indicating copy to clipboard operation
bi-att-flow copied to clipboard

absl.flags._exceptions.UnrecognizedFlagError: Unknown command line flag 'new_emb_mat'

Open yexing514 opened this issue 5 years ago • 2 comments

I am trying to get the repo working in TF1.7. I was able to get the training done with the help of dev branch for TF 1.4. But I failed in testing. If I set it flags.DEFINE_integer("new_emb_mat", 0, "embedding matrix"), I got result F1 0.74 and accuracy 0.629. Is it normal? What value should we pass to new_emb_mat?

The error I got originally was :

Traceback (most recent call last): File "/anaconda/envs/py35/lib/python3.5/runpy.py", line 193, in _run_module_as_main "main", mod_spec) File "/anaconda/envs/py35/lib/python3.5/runpy.py", line 85, in _run_code exec(code, run_globals) File "/home/adminye/bi-att-flow/basic/cli.py", line 128, in tf.app.run() File "/anaconda/envs/py35/lib/python3.5/site-packages/tensorflow/python/platform/app.py", line 126, in run _sys.exit(main(argv)) File "/home/adminye/bi-att-flow/basic/cli.py", line 125, in main m(config) File "/home/adminye/bi-att-flow/basic/main.py", line 26, in main _test(config) File "/home/adminye/bi-att-flow/basic/main.py", line 143, in _test config.new_emb_mat = new_emb_mat File "/anaconda/envs/py35/lib/python3.5/site-packages/tensorflow/python/platform/flags.py", line 88, in setattr return self.dict['__wrapped'].setattr(name, value) File "/anaconda/envs/py35/lib/python3.5/site-packages/absl/flags/_flagvalues.py", line 496, in setattr return self._set_unknown_flag(name, value) File "/anaconda/envs/py35/lib/python3.5/site-packages/absl/flags/_flagvalues.py", line 374, in _set_unknown_flag raise _exceptions.UnrecognizedFlagError(name, value) absl.flags._exceptions.UnrecognizedFlagError: Unknown command line flag 'new_emb_mat'

yexing514 avatar Jul 16 '18 18:07 yexing514

flags.DEFINE_integer("new_emb_mat", 0, "new_emb_mat")

kumsantosh avatar Nov 01 '18 18:11 kumsantosh

flags.DEFINE_integer("new_emb_mat", 0, "new_emb_mat")

He asked What value should we pass to new_emb_mat?

JaneShenYY avatar Apr 10 '19 02:04 JaneShenYY