Skip to content
This repository has been archived by the owner on Jul 7, 2023. It is now read-only.

seq2edits_textnorm NotImplementedError #1894

Open
cingtiye opened this issue Aug 6, 2021 · 0 comments
Open

seq2edits_textnorm NotImplementedError #1894

cingtiye opened this issue Aug 6, 2021 · 0 comments

Comments

@cingtiye
Copy link

cingtiye commented Aug 6, 2021

Description

I am very happy to see that seq2edits code can open source. I printed the “problems.available()“ of tensor2ten and found that there are 12 PROBLEMs about seq2edits. I selected "PROBLEM = "seq2edits_gec"" and run the following code:

$ PROBLEM = "seq2edits_gec"
$ t2t-datagen \
  --data_dir=$DATA_DIR \
  --tmp_dir=$TMP_DIR \
  --problem=$PROBLEM \
  --t2t_usr_dir=$USR_DIR

Error logs:

File "*/tensor2tensor/data_generators/text_problems.py", line 360, in generate_data
    if self.is_generate_per_split:
  File "*/tensor2tensor/data_generators/text_problems.py", line 89, in is_generate_per_split
    raise NotImplementedError()
NotImplementedError

So, I checked "*/tensor2tensor/data_generators/seq2edits.py" and found that there is no implementation of the function "is_generate_per_split" in all classes of seq2edits.py, and there is also no implementation of the function "generate_samples".

How can I implement the two keys functions of "is_generate_per_split" and "generate_samples" in seq2edits.py.

I am very much looking forward to getting a reply.
Thanks.

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

No branches or pull requests

1 participant