handwriting icon indicating copy to clipboard operation
handwriting copied to clipboard

Priming handwriting style when sampling

Open billhart opened this issue 8 years ago • 1 comments

Thanks for this project, its much faster and way easier to get working than the rnnlib versions were (and faster than the tensorflow version too).

I've got everything working nicely, but have been looking through the code trying to figure out how to 'prime' the sampling of the model with a particular handwriting style as Graves describes. It seems as though this is happening in your sampling script - could you give me some pointers for where to look >

thanks

billhart avatar Nov 22 '16 06:11 billhart

Thanks for your interest!

At the moment, this feature is not implemented and unfortunately I don't have anymore time to spend on this project. Here are a few guidelines of how I would do it:

  • change the dataset loader and generators to also output an integer describing the id of the writer: https://github.com/adbrebs/handwriting/blob/master/data.py
  • add a theano tensor variable corresponding to the id and give it as input to all the monitor and sampling objects. https://github.com/adbrebs/handwriting/blob/master/main_cond.py#L71 be sure that the order of the inputs given to the monitors is the same as the data generator outputs
  • change the model itself to integrate the id of the writer: https://github.com/adbrebs/handwriting/blob/master/model.py#L210 as described in Graves' paper.

adbrebs avatar Nov 22 '16 14:11 adbrebs