Better HN
topnewbestaskshowjobs
Log inSign up

sjv

183 karma · joined Jun 10, 2019 (7y ago) · 17 submissions

Submissions

comment 6y ago · link · parent

I implemented the network from scratch in vanilla javascript. The file is just a custom binary file containing the names, shapes, and weights of the network parameters. If you have more specific questions, feel free to ask them.

comment 6y ago · link · parent

The dataset is from the IAM On-Line Handwriting Database. I've linked my github, which has my email, on my profile.

comment 6y ago · link · parent

Outputs are sampled from a probability distribution, and increasing the legibility effectively concentrates probability density around more likely outcomes. So you're correct that it's just altering variation. The general technique is referred to as 'adjusting the temperature of the sampling distribution'.

comment 6y ago · link · parent

Hey HN — This is a simple web app that allows you to enter text and watch as an in-browser neural network generates the corresponding handwriting in real time. I’m happy to hear feedback or answer questions about how it works!

5.

Show HN: Generate realistic handwriting with neural networks [demo](calligrapher.ai ↗)

66 points · by sjv · 6y ago · 19 comments

comment 6y ago · link · parent

The value is almost entirely as a technical demo of current machine learning techniques. Handwritten fonts will always be a more reliable way to create synthetic handwriting, so I don't see this as something that will be used as anything other than a toy.

comment 6y ago · link · parent

Hey HN — This is a simple web app that allows you to enter text and watch as an in-browser neural network generates the corresponding handwriting in real time. I’m happy to hear feedback or answer questions about how it works!

8.

Show HN: A realistic handwriting generator, directly in the browser [demo](calligrapher.ai ↗)

4 points · by sjv · 6y ago · 4 comments

comment 6y ago · link · parent

Yes, it's mostly based on that. Primary difference is that this model adds an inference model (VAE style), which allows you to a) sample style vectors from a latent distribution b) do so more efficiently than the priming mechanism described in that paper.

comment 6y ago · link · parent

It's not intentionally slowed down. The sampling process is computationally heavy and you'll notice improved performance when running it on better hardware. There are many algorithmic ways to speed up neural network computation and I'm fairly sure I could speed things up by an order of magnitude or two if I invested some time into it.

comment 6y ago · link · parent

The model was trained on a relatively small dataset which has few occurrences of the letter x, almost none of which are in cursive. As you've found, asking the model to write out an x in a cursive style can totally derail the generation process.

comment 6y ago · link · parent

Non-statistical methods of imitating handwriting are always fairly easy to identify as synthetic due to the uniformity of strokes and unnatural kerning (among other things). Even methods which incorporate random variations don't hide these artifacts sufficiently well. In my opinion, the only way to generate synthetic handwriting which is convincingly real is to use statistical methods (i.e. machine learning) to model all variation which is present in real handwriting. I've implemented a neural network in javascript which does exactly this - https://seanvasquez.com/handwriting-generation/. You can play around with it and find a few weaknesses, but in general I find that it can produce handwriting which is indistinguishable from real handwriting.

comment 6y ago · link · parent

This problem was more or less solved with neural networks in 2013, see https://arxiv.org/abs/1308.0850. I've implemented a similar model in javascript that you can interact with: https://seanvasquez.com/handwriting-generation/

comment 6y ago · link · parent

Perhaps something like this? https://seanvasquez.com/handwriting-generation

15.

Show HN: Handwriting generation with an in-browser recurrent neural network(seanvasquez.com ↗)

2 points · by sjv · 6y ago · discuss