# Stroke Extraction to recreate Chinese characters

I was going through the project lists of Andrew NG from his Stanford machine learning course and I found a project based on recreation of calligraphic characters. To do so firstly we need to extract strokes from characters and I can only understand it in bits and pieces and I cannot understand at all how to implement it in matlab.

I also read the research paper that the stroke extraction method is based on. But I did not understand that too like there were some terms that I could not understand. And not to mention I can't understand just how to implement all the pixel related operations mentioned. I am a beginner in image processing. Ss please any help is appreciated.

Quoting some lines from the paper:

We use the direction contribution of the segments to estimate the degree for each pixel on the thick-line image. Given a binary image, for each black pixel $p(r,c)$, let $D_k(r,c)$ denote the orientation distance between the pixel and the boundary point along the $k$th quantized orientation, where $k = 1, 2, \dots, M$, and $M$ is an integer that denotes the quantization number from $0^\circ$ to $360^\circ$ . The orientation distance is called point-to-boundary orientation distance (PBOD). The distribution of the PBODs contains information about the degree of each pixel. We can easily tell that the PBODs along the quantized orientations of the branches are much larger than that along other quantized orientation. So, to estimate the degree of each pixel, we need only calculate the number of the crests of the distribution of all the PBODs of the pixel. Figure 2 shows some cases of the distribution. The resolution of quantization is $3^\circ$.

What is quantisation and orientation distance, and how to implement these in matlab?

• The programming questions are off-topic here. Also questions should be self-contained. After reading your question the relevant part boils down to: "What is quantisation?" and "What is orientation distance?", but there should be one question per post. To help you understand the ideas, we would like you to say what have you tried and where did you get stuck, because writting yet another definition is futile. If there are some additional phrases that you do not understand, you have to write them (because we have no clue what you are talking about). – Evil Jun 30 '17 at 5:12
• What research have you done? Your first question is answered here:en.wikipedia.org/wiki/Quantization. If your question can be answered in the obvious place on Wikipedia (e.g., by searching for that word on Wikipedia), you probably should do more research before asking in the future. – D.W. Jun 30 '17 at 5:15
• Orientation distance is the distance between a point and a set (in this case, the boundary) along a specific direction. That is, it is how much you have to go, from the point and in the given direction, until you hit the set. – Yuval Filmus Jun 30 '17 at 8:33