{'fraction_non_alphanumeric': 0.024886877828054297, 'fraction_numerical': 0.0022624434389140274, 'mean_word_length': 4.6075949367088604, '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}}
The Embroidery Problem

We consider the problem of embroidering a design pattern, given by a graph G, using a single minimum length thread. We give an exact polynomial-time algorithm for the case that G is connected. If G has multiple connected components, then we show that the problem is NP-hard and give a polynomial-time 2-approximation algorithm. We also present results for special cases of the problem with various objective functions.