MCPcopy Create free account
hub / github.com/Notgnoshi/generative / interpret

Method interpret

generative/lsystem/interpreter.py:64–68  ·  view source on GitHub ↗

Interpret the given tokens as 3D Turtle commands.

(self, tokens: Tokens)

Source from the content-addressed store, hash-verified

62 yield char
63
64 def interpret(self, tokens: Tokens) -> Lines:
65 """Interpret the given tokens as 3D Turtle commands."""
66 for line in self._interpret(tokens):
67 if line is not None:
68 yield line
69
70 def _interpret(self, tokens: Tokens) -> Lines:
71 if self.commandset == "default":

Callers 12

mainFunction · 0.95
test_forwardMethod · 0.80
test_forward_no_drawMethod · 0.80
test_yawMethod · 0.80
test_draw_no_drawMethod · 0.80
test_pitchMethod · 0.80
test_rollMethod · 0.80
test_flipMethod · 0.80
test_stackMethod · 0.80

Calls 1

_interpretMethod · 0.95

Tested by 11

test_forwardMethod · 0.64
test_forward_no_drawMethod · 0.64
test_yawMethod · 0.64
test_draw_no_drawMethod · 0.64
test_pitchMethod · 0.64
test_rollMethod · 0.64
test_flipMethod · 0.64
test_stackMethod · 0.64