<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Parameter I/O Add-in Question in Fusion API and Scripts Forum</title>
    <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10274155#M8972</link>
    <description>&lt;P&gt;Hi &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/10314739"&gt;@joecamisa&lt;/a&gt;&amp;nbsp;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I haven't used the Parameter I/O Add-in, but if you can modify it, changing the timeline.markerPosition Property might help.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-d0cede26-e905-45b4-b30d-8f244670c1f7" target="_blank" rel="noopener"&gt;https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-d0cede26-e905-45b4-b30d-8f244670c1f7&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I drew a circle on the sketch to create a diameter constraint and ran the following script&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;# 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) -&amp;gt; str:
        return '{:.3f}'.format(time.time() - self.t)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here are the results.&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;As it is:45.503
Move MarkerPosition:29.732&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have a feeling that more complex data would have a bigger effect.&lt;/P&gt;</description>
    <pubDate>Wed, 28 Apr 2021 06:54:27 GMT</pubDate>
    <dc:creator>kandennti</dc:creator>
    <dc:date>2021-04-28T06:54:27Z</dc:date>
    <item>
      <title>Parameter I/O Add-in Question</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10273639#M8971</link>
      <description>&lt;P&gt;I am using the Parameter I/O add-in with great success.&amp;nbsp; This is an excellent add-in!&amp;nbsp; This add-in has enabled me to create a model with 500 dimensions driven by a single User Parameter.&amp;nbsp; My question: is there anyway to speed the import process?&amp;nbsp; Import takes about 25 minutes for a model with 500&amp;nbsp; dimensions.&amp;nbsp; &amp;nbsp;Seems like the model is being updated for each parameter imported - is there a way to hold off on Compute until all parameters have been imported?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any guidance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Joe Camisa&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Apr 2021 01:01:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10273639#M8971</guid>
      <dc:creator>joecamisa</dc:creator>
      <dc:date>2021-04-28T01:01:59Z</dc:date>
    </item>
    <item>
      <title>Re: Parameter I/O Add-in Question</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10274155#M8972</link>
      <description>&lt;P&gt;Hi &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/10314739"&gt;@joecamisa&lt;/a&gt;&amp;nbsp;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I haven't used the Parameter I/O Add-in, but if you can modify it, changing the timeline.markerPosition Property might help.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-d0cede26-e905-45b4-b30d-8f244670c1f7" target="_blank" rel="noopener"&gt;https://help.autodesk.com/view/fusion360/ENU/?guid=GUID-d0cede26-e905-45b4-b30d-8f244670c1f7&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I drew a circle on the sketch to create a diameter constraint and ran the following script&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;# 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) -&amp;gt; str:
        return '{:.3f}'.format(time.time() - self.t)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here are the results.&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;As it is:45.503
Move MarkerPosition:29.732&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have a feeling that more complex data would have a bigger effect.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Apr 2021 06:54:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10274155#M8972</guid>
      <dc:creator>kandennti</dc:creator>
      <dc:date>2021-04-28T06:54:27Z</dc:date>
    </item>
    <item>
      <title>Re: Parameter I/O Add-in Question</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10275240#M8973</link>
      <description>&lt;P&gt;I think you can do what&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3787950"&gt;@kandennti&lt;/a&gt;&amp;nbsp;suggests without changing any code.&amp;nbsp; Just move the timeline marker to the beginning of the timeline before you run the Parameter I/O command, run the command, and then move the marker back to where it was.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Apr 2021 13:42:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10275240#M8973</guid>
      <dc:creator>BrianEkins</dc:creator>
      <dc:date>2021-04-28T13:42:06Z</dc:date>
    </item>
    <item>
      <title>Re: Parameter I/O Add-in Question</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10276299#M8974</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3787950"&gt;@kandennti&lt;/a&gt;&amp;nbsp;and &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/5741855"&gt;@BrianEkins&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Your suggestions have worked!&amp;nbsp; &amp;nbsp;I found that I needed to move the timeline marker back to just AFTER the sketch with the dimensions to be exported, made proportional in a spreadsheet and reimported as User Parameter based (fx) dimensions.&amp;nbsp; The import took less than one minute vs 20 minutes without moving the timeline marker.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is a great help for my work process and is GREATLY APPREACIATED.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you both.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope soon I will learn enough to contribute guidance as you both have.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Apr 2021 19:16:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/parameter-i-o-add-in-question/m-p/10276299#M8974</guid>
      <dc:creator>joecamisa</dc:creator>
      <dc:date>2021-04-28T19:16:14Z</dc:date>
    </item>
  </channel>
</rss>

