syntext icon indicating copy to clipboard operation
syntext copied to clipboard

Thanks for your repo

Open shining-love opened this issue 5 years ago • 4 comments
trafficstars

Hello, how do I generate a text image of a fixed length character sequence?How to generate text image with fixed image size?

shining-love avatar Jun 25 '20 15:06 shining-love

for fix-length text, its easy, you can fix the max length & min length to same value, like:

config.xxx.yml:

MAX_LENGTH : 4                  # 可能的最大长度(字符数)
MIN_LENGTH : 4                  # 可能的最小长度(字符数)

for fixed size image, currently it is not supprted. you can resize them to a fix size or padding them, when you try to train some models. normally, you need different size of image for data diversity. but this is a good feature advice, i can later consider to add it.

Thanks for you attention for this project.

piginzoo avatar Jun 26 '20 03:06 piginzoo

for fix-length text, its easy, you can fix the max length & min length to same value, like:

config.xxx.yml:

MAX_LENGTH : 4                  # 可能的最大长度(字符数)
MIN_LENGTH : 4                  # 可能的最小长度(字符数)

hankd size image, currently it is not supprted. you can resize them to a fix size or padding them, when you try to train some models. normally, you need different size of image for data diversity. but this is a good feature advice, i can later consider to add it.

Thanks for you attention for this project.

Thanks for your reply!I had tried to set MAX_LENGTH and MIN_LENGTH 10.It is strange that the result length is 5 instead of 10.

shining-love avatar Jun 26 '20 04:06 shining-love

i test it with max=min=10, the result is ok, so, you can try again.

below is my runtime config file: config.alphabeta.yml.zip

and the command is : bin/run.sh --dir data/output --worker 3 --num 100 --config config/config.alphabeta.yml

you can try again, if you found any bugs, its appreciated to issue to me.

piginzoo avatar Jun 26 '20 04:06 piginzoo

i test it with max=min=10, the result is ok, so, you can try again. below is my runtime config file: config.alphabeta.yml.zip and the command is : bin/run.sh --dir data/output --worker 3 --num 100 --config config/config.alphabeta.yml you can try again, if you found any bugs, its appreciated to issue to me.

OK nice guys,I‘ll try it in this way.

shining-love avatar Jun 26 '20 09:06 shining-love