<!-- 
RSS generated by JIRA (8.3.4#803005-sha1:1f96e09b3c60279a408a2ae47be3c745f571388b) at Sat Feb 10 16:35:05 JST 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>PFS-JIRA</title>
    <link>https://pfspipe.ipmu.jp/jira</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>8.3.4</version>
        <build-number>803005</build-number>
        <build-date>13-09-2019</build-date>
    </build-info>


<item>
            <title>[INSTRM-1401] Populate target table</title>
                <link>https://pfspipe.ipmu.jp/jira/browse/INSTRM-1401</link>
                <project id="10300" key="INSTRM">Instrument control development</project>
                    <description>&lt;p&gt;Please:&lt;/p&gt;

&lt;ul&gt;
	&lt;li&gt;Populate the target table based on historical Sept eng run data.&lt;/li&gt;
	&lt;li&gt;Load the target table based on the most recent targets prior to the next run.&lt;/li&gt;
&lt;/ul&gt;
</description>
                <environment></environment>
        <key id="18246">INSTRM-1401</key>
            <summary>Populate target table</summary>
                <type id="3" iconUrl="https://pfspipe.ipmu.jp/jira/secure/viewavatar?size=xsmall&amp;avatarId=10518&amp;avatarType=issuetype">Task</type>
                                            <priority id="10000" iconUrl="https://pfspipe.ipmu.jp/jira/images/icons/priorities/medium.svg">Normal</priority>
                        <status id="10002" iconUrl="https://pfspipe.ipmu.jp/jira/images/icons/statuses/generic.png" description="The issue is resolved, reviewed, and merged">Done</status>
                    <statusCategory id="3" key="done" colorName="green"/>
                                    <resolution id="10000">Done</resolution>
                                        <assignee username="chyan">chyan</assignee>
                                    <reporter username="hassan">hassan</reporter>
                        <labels>
                            <label>EngRun</label>
                    </labels>
                <created>Fri, 15 Oct 2021 12:13:09 +0000</created>
                <updated>Wed, 19 Jan 2022 03:36:36 +0000</updated>
                            <resolved>Wed, 19 Jan 2022 03:36:36 +0000</resolved>
                                                                        <due></due>
                            <votes>0</votes>
                                    <watches>3</watches>
                                                                <comments>
                            <comment id="23345" author="chyan" created="Thu, 21 Oct 2021 00:35:26 +0000"  >&lt;p&gt;The ics_cobraCharmer produces the trajectory for all the moves.   We should be able to insert those information into database. &lt;/p&gt;</comment>
                            <comment id="24830" author="chyan" created="Wed, 27 Oct 2021 16:27:30 +0000"  >&lt;p&gt;A branch of fpsActor is pushed to GitHub to address this ticket.&lt;/p&gt;</comment>
                            <comment id="24869" author="chyan" created="Thu, 28 Oct 2021 16:38:08 +0000"  >&lt;p&gt;Talked to Chih-Yi today and he pointed out there are two way to implement this.  One solution is obviously in fpsActor and another one in down to the function of moveThetaPhi in CobraCoach.py since it calculate the angle for theta, phi for each iteration before the move. &lt;/p&gt;</comment>
                            <comment id="25062" author="chyan" created="Sun, 14 Nov 2021 10:33:13 +0000"  >&lt;p&gt;Turns out this is more complicated than what I thought. &#160;The reason is addressed here. &#160;cobra_target contains information from different levels &lt;b&gt;BOFORE&lt;/b&gt; the cobra is actually moving. &#160;It require visited, iteration (FPS), cobra location in mm (FPS), target location in mm (FPS), motor map information (cobraCoach), theta and phi angle (cobraCoach), theta and phi steps (cobraCharmer), theta and phi on-time (FPGA). &#160; To insert only predicted angle is easy. &#160;However, to input all those information at once is not straight-forward. &#160;A possible implementation is passing an object all the way down to FPGA level and write information in every step.&lt;/p&gt;</comment>
                            <comment id="25063" author="chyan" created="Sun, 14 Nov 2021 11:34:19 +0000"  >&lt;p&gt;Two branches in ics_fpsActor and ics_cobraCharmer is pushed for populating target table. &#160;This version only populated the information in cobraCharmer level. &#160;We need to think about how to get information down to FPGA level (steps and on-time).&lt;/p&gt;</comment>
                            <comment id="30289" author="chyan" created="Thu, 6 Jan 2022 09:54:03 +0000"  >&lt;p&gt;I would need help from &lt;a href=&quot;https://pfspipe.ipmu.jp/jira/secure/ViewProfile.jspa?name=kiyoto.yabe&quot; class=&quot;user-hover&quot; rel=&quot;kiyoto.yabe&quot;&gt;Kiyoto Yabe&lt;/a&gt; regarding the database prime key issue.   Currently, the cobra_target table is populated with (pfs_visit_id, iteration, cobra_id) because cobra_match table requires those information (prime key referencing). So, I may need a function that only updating the opdb table instead of writing.   &lt;/p&gt;</comment>
                            <comment id="30290" author="kiyoto.yabe" created="Thu, 6 Jan 2022 13:12:07 +0000"  >&lt;p&gt;Maybe I don&apos;t understand what you want to do, but do you want to (for example) insert information other than (pfs_visit_id, iteration, cobra_id) into cobra_target after populating cobra_match table? Could you tell me example use cases?&lt;/p&gt;

&lt;p&gt;There is opdb.update method already implemented, but it&apos;s not fully tested. I&apos;ll check it to see whether it works properly.&lt;/p&gt;</comment>
                            <comment id="30291" author="chyan" created="Thu, 6 Jan 2022 18:06:12 +0000"  >&lt;p&gt;I tried db.update function, but it did not work. &#160;There are two places I need to update the cobra_target table. &#160;The first place is in &lt;a href=&quot;https://github.com/Subaru-PFS/ics_mcsActor/blob/cb520471ece7c294f0633d922685ce58cf5dc6a6/python/mcsActor/Commands/McsCmd.py#L842&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;ics_mcsActor&lt;/a&gt;.  We need it before writing to cobra_match table.  So, in MCS we only write three columns.   However, we need update this table when we gather more information on where the cobra will go.  I did some work arounds.  The target table is populated and tested with bench system.&lt;/p&gt;</comment>
                            <comment id="30306" author="kiyoto.yabe" created="Tue, 11 Jan 2022 02:53:48 +0000"  >&lt;p&gt;Perhaps I missed the discussion point in the last meeting, but does simply swapping the relationship between `cobra_target` and `cobra_match` solve the issue? I mean (pfs_visit_id, iteration, cobra_id) of `cobra_target` refers `cobra_match`, so that you don&apos;t need to populate `cobra_target` first. This relationship looks a bit strange to me, but it is probably OK practically.&lt;/p&gt;</comment>
                            <comment id="30307" author="chyan" created="Tue, 11 Jan 2022 05:40:40 +0000"  >&lt;p&gt;Thanks for the comment, let me talk to Craig first.  Then we decided how to do it.  I think this is because cobra_match needs a reference from somewhere.  Therefore, a pre-existed table is required.&lt;/p&gt;</comment>
                            <comment id="30308" author="kiyoto.yabe" created="Tue, 11 Jan 2022 05:51:29 +0000"  >&lt;p&gt;Thank you, I got the problem.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10000">
                    <name>Blocks</name>
                                                                <inwardlinks description="is blocked by">
                                        <issuelink>
            <issuekey id="22582">INSTRM-1497</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10003">
                    <name>Relates</name>
                                            <outwardlinks description="relates to">
                                        <issuelink>
            <issuekey id="18230">INSTRM-1388</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10500" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                            <customfield id="customfield_10010" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|02qpuc:i6001gr068fhw9qo4o0ry8y</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10005" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="123">PreEngRun4</customfieldvalue>
    <customfieldvalue id="124">EngRun3Cleanup</customfieldvalue>
    <customfieldvalue id="128">PreEngRun05 A</customfieldvalue>
    <customfieldvalue id="129">PreEngRun05 B</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10002" key="com.atlassian.jira.plugin.system.customfieldtypes:float">
                        <customfieldname>Story Points</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                        </customfields>
    </item>
</channel>
</rss>