Hi @joecamisa .
I haven't used the Parameter I/O Add-in, but if you can modify it, changing the timeline.markerPosition Property might help.
https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-d0cede26-e905-45b4-b30d-8f244670c1f7
I drew a circle on the sketch to create a diameter constraint and ran the following script
# Fusion360API Python script
import adsk.core, adsk.fusion, traceback
import time
def run(context):
ui = None
try:
global _app, _ui
app = adsk.core.Application.get()
ui = app.userInterface
des :adsk.fusion.Design = app.activeProduct
prm = des.allParameters.itemByName('d1')
# As it is
sw = stopwatch()
sw.start()
test(prm)
print(f'As it is:{sw.lap()}')
# Move MarkerPosition
sw.start()
tl = des.timeline
markerPos = tl.markerPosition
tl.moveToBeginning()
test(prm)
tl.markerPosition = markerPos
print(f'Move MarkerPosition:{sw.lap()}')
except:
if ui:
ui.messageBox('Failed:\n{}'.format(traceback.format_exc()))
def test(prm, count = 500):
for v in range(count):
prm.value = v
class stopwatch():
def __init__(self):
self.t = 0
def start(self):
self.t = time.time()
def lap(self) -> str:
return '{:.3f}'.format(time.time() - self.t)
Here are the results.
As it is:45.503
Move MarkerPosition:29.732
I have a feeling that more complex data would have a bigger effect.