Last active
August 14, 2020 10:28
-
-
Save chuongmep/55fdb0312b7bb749dba293f94142411a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) 2014, Nathan Miller | |
# The Proving Ground, http://TheProvingGround.org | |
import clr | |
clr.AddReference('ProtoGeometry') | |
from Autodesk.DesignScript.Geometry import * | |
#The input to this node will be stored in the IN[0] variable. | |
input = IN[0] | |
if not hasattr(input, "__iter__"): | |
input = [input] | |
cleanlist = [] | |
for i in input: | |
if hasattr(i, "__iter__"): | |
for ii in i: | |
if not (i is None): | |
cleanlist.append(i) | |
else: | |
if not (i is None): | |
cleanlist.append(i) | |
#Assign your output to the OUT variable | |
OUT = cleanlist |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment