Abstract
Current software tools for computer generation of Persian calligraphy can be mostly described as conventional fonts and typesetting software, which basically neglect the ‘variations’ of real calligraphy performed by hand, in terms of personalization to different calligraphers’ styles, as well as their statistical characteristics. In this paper, we address the problem of natural-looking Persian calligraphy synthesis via a machine learning based approach, at the level of subwords. Given images of samples written by a calligrapher, we train a parametric model to imitate the style. The core idea is to make use of templates (fonts) as a source of background knowledge, and learn a probabilistic mapping from them to personal styles of calligraphers, which is posed as transformation of attributed graphs using neural networks with sliding windows. This can be understood as adding ‘naturalness’ to a Persian calligraphy font, in essence. We report both objective and subjective evaluations, including the model performance in writer (calligrapher) identification task and Visual Turing Test. The results of the latter suggest that humans are unable to distinguish the calligraphy synthesized by our approach from real calligraphy in many cases.
Similar content being viewed by others
References
Kelk, Persian Calligraphy Software. http://sinasoft.com/kelk.html (2019)
New Version of IranNastaliq Font. https://irfont.ir/fonts. (2019)
Tasmeem Full Pack For Indesign CC. http://winsoft-international.com/product/tasmeem-full-pack-for-indesign-cc/ (2019)
Aksan, E., Pece, F., Hilliges, O.: DeepWriting: Making digital ink editable via deep generative modeling. In: Proceedings of the 2018 CHI Conference on Human Factors in Computing Systems, p. 205. ACM (2018)
Berio, D., Akten, M., Leymarie, F.F., Grierson, M., Plamondon, R.: Calligraphic stylisation learning with a physiologically plausible model of movement and recurrent neural networks. In: Proceedings of the 4th International Conference on Movement Computing, p. 25. ACM (2017)
Bishop, C.M.: Mixture density networks, Technical Report, Aston University, Birmingham (1994)
Bulacu, M., Schomaker, L.: Text-independent writer identification and verification using textural and allographic features. IEEE Trans. Pattern Anal. Mach. Intell. 29(4), 701–717 (2007)
Clouse, D.S., Giles, C.L., Horne, B.G., Cottrell, G.W.: Time-delay neural networks: representation and induction of finite-state machines. IEEE Trans. Neural Netw. 8(5), 1065–1070 (1997)
Dinges, L., Al-Hamadi, A., Elzobi, M.: An approach for arabic handwriting synthesis based on active shape models. In: Proceedings of the international conference on document analysis and recognition, ICDAR, pp. 1260–1264 (2013)
Dolinský, J., Takagi, H.: Analysis and modeling of naturalness in handwritten characters. IEEE Trans. Neural Netw. 20(10), 1540–1553 (2009)
Elarian, Y., Abdel-Aal, R., Ahmad, I., Parvez, M.T., Zidouri, A.: Handwriting synthesis: classifications and techniques. Int. J. Document Anal. Recogn. 17(4), 455–469 (2014)
Fouladi, K., Araabi, B.N.: Toward automatic development of handwritten personal Farsi/Arabic OpenType\({\textregistered }\) fonts. Int. J. Document Anal. Recogn. 18(3), 249–262 (2015)
Fouladi, K., Araabi, B.N., Kabir, E.: A fast and accurate contour-based method for writer-dependent offline handwritten Farsi/Arabic subwords recognition. Int. J. Document Anal. Recogn. 17(2), 181–203 (2014)
Gonzalez, R.C., Woods, R.E.: Digital Image Processing. Prentice-Hall, Upper Saddle (2008)
Graves, A.: Generating sequences with recurrent neural networks. arXive preprint arXiv:1308.0850, pp. 1–43 (2013). http://arxiv.org/abs/1308.0850
Huszár, F.: How (not) to train your generative model: Scheduled sampling, likelihood, adversary? arXiv preprint arXiv:1511.05101 (2015)
Lake, B.M., Salakhutdinov, R., Tenenbaum, J.B.: Human-level concept learning through probabilistic program induction. Science 350(6266), 1332–1338 (2015)
Lyu, P., Bai, X., Yao, C., Zhu, Z., Huang, T., Liu, W.: Auto-Encoder Guided GAN for Chinese Calligraphy Synthesis. In: Document Analysis and Recognition (ICDAR), 2017 14th IAPR International Conference on, vol. 1, pp. 1095–1100. IEEE (2017)
Mash’Al, M., Sadri, J.: Persian calligraphy using genetic algorithm. In: 1st Iranian Conference on Pattern Recognition and Image Analysis, PRIA 2013 (2013)
Naz, S., Umar, A.I., Ahmad, R., Ahmed, S.B., Shirazi, S.H., Siddiqi, I., Razzak, M.I.: Offline cursive Urdu-Nastaliq script recognition using multidimensional recurrent neural networks. Neurocomputing 177, 228–241 (2016)
Plamondon, R., Guerfali, W.: The generation of handwriting with delta-lognormal synergies. Biol. Cybern. 78(2), 119–132 (1998)
Ratanamahatana, C.A., Keogh, E.: Everything you know about dynamic time warping is wrong. In: Third workshop on mining temporal and sequential data. Citeseer (2004)
Sadikoglu, F., Soroush, B.: Intelligent system for Persian calligraphy learning. Procedia Comput. Sci. 102, 555–561 (2016)
Srihari, S.N., Cha, S.H., Arora, H., Lee, S.: Individuality of handwriting: a validation study. In: Proceedings of the international conference on document analysis and recognition, ICDAR, pp. 106–109 (2001)
Theis, L., van den Oord, A., Bethge, M.: A note on the evaluation of generative models. In: International conference on learning representations (2016)
Toomarian, N., Barhen, J.: Fast temporal neural learning using teacher forcing. In: Neural Networks, 1991., IJCNN-91-Seattle international joint conference on, vol. 1, pp. 817–822. IEEE (1991)
Van Ness, J.: On the dominance of non-parametric Bayes rule discriminant algorithms in high dimensions. Pattern Recogn. 12(6), 355–368 (1980)
Yaghmaei, F.: Discovering writing habits and using them to synthesize Persian handwritten words [in Persian]. J. Mach. Vis. Image Process. (2016)
Zamani, P., Williams, B., Soltanian-Zadeh, H.: Extracting Motion Primitives from Persian Handwriting [in Persian]. In: 14th Iranian Conference on Biomedical Engineering (2007)
Zhang, Y., Zhang, Y., Cai, W.: Separating style and content for generalized style transfer. In: Proceedings of the IEEE conference on computer vision and pattern recognition, vol. 1 (2018)
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
A Appendix: Pseudocode for extracting segments
A Appendix: Pseudocode for extracting segments
Rights and permissions
About this article
Cite this article
Ahmadian, A., Fouladi, K. & Araabi, B.N. Model-based Persian calligraphy synthesis via learning to transfer templates to personal styles. IJDAR 23, 183–203 (2020). https://doi.org/10.1007/s10032-020-00353-1
Received:
Revised:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10032-020-00353-1