This uses the same code as my knot generator, but the knots are replaced with lines. Inspired by this: https://en.wikipedia.org/wiki/Truchet_tiles