


{"id":244744,"date":"2022-12-23T00:41:39","date_gmt":"2022-12-23T00:41:39","guid":{"rendered":"\/forum\/forums\/topic\/lumopt-issue\/"},"modified":"2022-12-23T00:41:39","modified_gmt":"2022-12-23T00:41:39","slug":"lumopt-issue","status":"closed","type":"topic","link":"https:\/\/innovationspace.ansys.com\/forum\/forums\/topic\/lumopt-issue\/","title":{"rendered":"LumOpt Issue"},"content":{"rendered":"<p>Hello,<\/p>\n<p>I am trying to work through several of the LumOpt examples.I am running through a Jupyter Notebook (through anaconda) as recommended here (https:\/\/lumopt.readthedocs.io\/en\/latest\/install.html). I am using the current v222 api as opposed to the clone from github which uses a previous version.<\/p>\n<p>-I can successfully import lumapi within the notebook, and run the gui through &#8220;fdtd = lumapi.FDTD()&#8221;.<\/p>\n<p>Two issues come up with plotter.py&nbsp;<\/p>\n<p>1)&nbsp;<\/p>\n<pre>C:\\Program Files\\Lumerical\\v222\\api\\python\\lumopt\\utilities\\plotter.py:61: <br>UserWarning: Matplotlib is currently using module:\/\/matplotlib_inline.backend_inline, which is a non-GUI backend, so cannot show the figure.\n  self.fig.show()<br><br>I dont think(?) this is a huge issue as the optimzation runs. %matplotlib inline is usually the recommended backend. <br><em>Is there a way to fix this?<\/em><br>------------------------------------------------------------------------------------------------------------------------------------------------<br>2) <\/pre>\n<pre>File <span class=\"ansi-green-intense-fg ansi-bold\">C:\\Program Files\\Lumerical\\v222\\api\\python\\lumopt\\utilities\\plotter.py:29<\/span>, in <span class=\"ansi-cyan-fg\">SnapShots.finish<\/span><span class=\"ansi-blue-intense-fg ansi-bold\">(self)<\/span>\n<span class=\"ansi-green-fg\">     28<\/span> <span class=\"ansi-bold\">def<\/span> finish(self):\n<span class=\"ansi-green-intense-fg ansi-bold\">---&gt; 29<\/span>     <span class=\"ansi-yellow-bg\">self<\/span><span class=\"ansi-yellow-bg\">.<\/span><span class=\"ansi-yellow-bg\">_frame_sink<\/span>().close()\n\n<span class=\"ansi-red-intense-fg ansi-bold\">AttributeError<\/span>: 'SnapShots' object has no attribute '_frame_sink'<br><br>The WDMsplitter.py script runs fine from the Lumerical GUI, but this error is always thrown through a notebook. <br><em>How should I address this to do interactive python development?<\/em><br><br><\/pre>\n","protected":false},"template":"","class_list":["post-244744","topic","type-topic","status-closed","hentry","topic-tag-api","topic-tag-inverse-design-2","topic-tag-lumopt-1","topic-tag-python"],"aioseo_notices":[],"acf":[],"custom_fields":[{"0":{"_bbp_subscription":["862","2592"],"_bbp_author_ip":["23.220.96.181"]," _bbp_last_reply_id":["0"]," _bbp_likes_count":["0"],"_btv_view_count":["1729"],"_bbp_topic_status":["unanswered"],"_bbp_status":["publish"],"_bbp_topic_id":["244744"],"_bbp_forum_id":["27833"],"_bbp_engagement":["862","2592"],"_bbp_voice_count":["2"],"_bbp_reply_count":["6"],"_bbp_last_reply_id":["245445"],"_bbp_last_active_id":["245445"],"_bbp_last_active_time":["2023-01-03 21:16:50"]},"test":"schinta3jhu-edu"}],"_links":{"self":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics\/244744","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics"}],"about":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics\/244744\/revisions"}],"wp:attachment":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/media?parent=244744"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}