Skip to content

Instantly share code, notes, and snippets.

@briochemc
Forked from alexgolec/neighbors_matrix.py
Created December 4, 2018 06:26
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save briochemc/10aa206ce081191d09a2904fa1ed0489 to your computer and use it in GitHub Desktop.
Save briochemc/10aa206ce081191d09a2904fa1ed0489 to your computer and use it in GitHub Desktop.
NEIGHBORS_MAP = {
0: (0, 0, 0, 0, 1, 0, 1, 0, 0, 0),
1: (0, 0, 0, 0, 0, 0, 1, 0, 1, 0),
2: (0, 0, 0, 0, 0, 0, 0, 1, 0, 1),
3: (0, 0, 0, 0, 1, 0, 0, 0, 1, 0),
4: (1, 0, 0, 1, 0, 0, 0, 0, 0, 1),
5: (0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
6: (1, 1, 0, 0, 0, 0, 0, 1, 0, 0),
7: (0, 0, 1, 0, 0, 0, 1, 0, 0, 0),
8: (0, 1, 0, 1, 0, 0, 0, 0, 0 ,0),
9: (0, 0, 1, 0, 1, 0, 0, 0, 0, 0),
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment