Skip to content

Commit

Permalink
Fixed try/except.
Browse files Browse the repository at this point in the history
  • Loading branch information
senthurayyappan committed Oct 11, 2020
1 parent 6978f66 commit b36cb08
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
:target: https://discord.gg/tpq7Yuv
:alt: Discord

|
What is Generative design?
--------------------------
Expand Down
6 changes: 4 additions & 2 deletions visualizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,12 @@ def marchthecubes(inp_path, output_path, resolution=100, density_thresh=0.1):
data = 0.0 * grid
# mask??

for _index in enumerate(data_indices):
for _index in data_indices:
try:
data[_index[0]][_index[1]][_index[2]] = 1

except:
pass

vertices, faces, normals, _ = measure.marching_cubes(data)
vertices = vertices + lower_bound + 0.5
vertices = 10 * vertices/resolution - 5
Expand Down

0 comments on commit b36cb08

Please sign in to comment.