{'fraction_non_alphanumeric': 0.01730103806228374, 'fraction_numerical': 0.0057670126874279125, 'mean_word_length': 5.728682170542636, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Learning geometric graph grammars

We introduce geometric graph grammars, demonstrate how they can generate geometric structures, and introduce an algorithm for their automatic learning (inverse procedural modeling). Our approach extends the concept of graph grammars to allow for coding not only topological data, but also geometry. Forward modeling generates geometric graphs and considers various strategies for node connectivity. Inverse procedural modeling performs learning of geometric graphs, by discovering repeated structures and their connectivity. These structures are encoded into geometric graph grammar rewriting rules. We demonstrate usability of our approach on an example using urban networks. Graph learning is reasonably fast; in our implementation, learning of a road network with 72k vertices and 100k edges is performed in less than one minute.