I have a python script for sorting by x,y location of pile foundations. Now this is working perfectly fine for a entire project. But when I have a project with multiple house blocks, in one revit file, I want to start the count with 1 for every house block. So I thought lets use group by key node and give that as input for the python script and I wanted to use ‘use levels’ option, but that is not possible with a python script.
Has anyone an idea how to deal with this? Python script is below.
from Autodesk.DesignScript.Geometry import *
#The inputs to this node will be stored as a list in the IN variables.
dataEnteringNode = IN
list_el = IN
orientation = IN
output = 
if orientation == True:
output = sorted(list_el, key=lambda list_el:(list_el, list_el), reverse=True)
output = sorted(list_el, key=lambda list_el:(list_el, list_el), reverse=False)
#Assign your output to the OUT variable.
OUT = zip(*output)