<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div id="yui_3_16_0_ym19_1_1484664971332_16905"></div><div style="margin:6px 0px 0px;color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;" id="yui_3_16_0_ym19_1_1484664971332_16915"><code style="font-family:menlo,;" id="yui_3_16_0_ym19_1_1484664971332_16916">if type(axis) == type(None) or axis > 0:</code></div><div id="yui_3_16_0_ym19_1_1484664971332_16917"><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_16958"><br id="yui_3_16_0_ym19_1_1484664971332_16918" clear="none"></div><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_16957">is not as idiomatic as:</div><br><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_17112"><code style="font-family:menlo,;font-size:12.6px;padding:2px 4px;color:rgb(199,37,78);background-color:rgb(249,242,244);border-radius:3px;white-space:pre-wrap;word-wrap:normal;margin-top:0px;" id="yui_3_16_0_ym19_1_1484664971332_17073">if axis is None or axis > 0:</code><span style="color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;font-size:14px;" id="yui_3_16_0_ym19_1_1484664971332_17074"> </span></div><div dir="ltr"><br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_17022">But this is totally fine too:<br></div><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_17038"><br></div><div id="yui_3_16_0_ym19_1_1484664971332_17029"><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_17037"><code style="font-family:menlo,;font-size:12.6px;padding:2px 4px;color:rgb(199,37,78);background-color:rgb(249,242,244);border-radius:3px;white-space:pre-wrap;word-wrap:normal;margin-top:0px;" id="yui_3_16_0_ym19_1_1484664971332_17030">if axis and axis > 0:</code><span style="color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;font-size:14px;" id="yui_3_16_0_ym19_1_1484664971332_17031"> <br id="yui_3_16_0_ym19_1_1484664971332_17032"></span></div></div><div dir="ltr" id="yui_3_16_0_ym19_1_1484664971332_16956"><br id="yui_3_16_0_ym19_1_1484664971332_16918" clear="none"></div></div><div id="yui_3_16_0_ym19_1_1484664971332_16812"> </div><div class="signature" id="yui_3_16_0_ym19_1_1484664971332_16919">S++</div> <div class="qtdSeparateBR"><br><br></div><div class="yahoo_quoted" style="display: block;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir="ltr"><font size="2" face="Arial"> On Sunday, January 15, 2017 9:50 PM, Andrew Maclean <andrew.amaclean@gmail.com> wrote:<br></font></div> <blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; margin-top: 5px; padding-left: 5px;"> <br><br> <div class="y_msg_container"><div id="yiv3645097601"><div><div dir="ltr">Sorry Ken I forgot to include you.<div><br clear="none"></div><div>I can't test it as I don't have MPI installed but there are two approaches:</div><div>1:<div style="margin:0px;color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;"><code style="font-family:menlo,;">if axis and axis > 0:</code> </div><div style="margin:0px;color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;">This should work. It seems to me that you want to return the result of impl.op() if axis > 0.</div>2:<div style="margin:6px 0px 0px;color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;">If the <strong style="margin-top:0px;">or</strong> is correct then you can use:</div><div style="margin:6px 0px 0px;color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;"><code style="font-family:menlo,;">if type(axis) == type(None) or axis > 0:</code></div></div><div class="yiv3645097601gmail_extra"><br clear="none"><div class="yiv3645097601yqt4739705124" id="yiv3645097601yqt88464"><div class="yiv3645097601gmail_quote">On Mon, Jan 16, 2017 at 8:41 AM, Andrew Maclean <span dir="ltr"><<a rel="nofollow" shape="rect" ymailto="mailto:andrew.amaclean@gmail.com" target="_blank" href="mailto:andrew.amaclean@gmail.com">andrew.amaclean@gmail.com</a>></span> wrote:<br clear="none"><blockquote class="yiv3645097601gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div dir="ltr">Unfortunately I don't have MPI installed so I can't test it.</div><div class="yiv3645097601m_7023432184253920345HOEnZb"><div class="yiv3645097601m_7023432184253920345h5"><div class="yiv3645097601gmail_extra"><br clear="none"><div class="yiv3645097601gmail_quote">On Mon, Jan 16, 2017 at 8:17 AM, Andrew Maclean <span dir="ltr"><<a rel="nofollow" shape="rect" ymailto="mailto:andrew.amaclean@gmail.com" target="_blank" href="mailto:andrew.amaclean@gmail.com">andrew.amaclean@gmail.com</a>></span> wrote:<br clear="none"><blockquote class="yiv3645097601gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div dir="ltr">Hi Ken,<div>   I think the fix is this:</div><div><br clear="none"></div><div><code style="font-family:menlo,;">if axis and axis > 0:</code><span style="color:rgb(92,93,94);font-family:-apple-system, blinkmacsystemfont,;"> </span></div>This should work. It seems to me that you want to return the result of impl.op() if axis > 0.<br clear="none"><br clear="none">Regards<br clear="none">   Andrew<div><div class="yiv3645097601gmail_extra"><br clear="none"><div class="yiv3645097601gmail_quote"><blockquote class="yiv3645097601gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex;">---------- Forwarded message ----------<br clear="none">From: Ken Martin <<a rel="nofollow" shape="rect" ymailto="mailto:ken.martin@kitware.com" target="_blank" href="mailto:ken.martin@kitware.com">ken.martin@kitware.com</a>><br clear="none">To: VTK Developers <<a rel="nofollow" shape="rect" ymailto="mailto:vtk-developers@vtk.org" target="_blank" href="mailto:vtk-developers@vtk.org">vtk-developers@vtk.org</a>><br clear="none">Cc: <br clear="none">Date: Sat, 14 Jan 2017 17:07:17 -0500<br clear="none">Subject: [vtk-developers] Anyone know Python? (and can look at a dashboard failure)<br clear="none"><div dir="ltr"><div><br clear="none"></div><div>The buildbots are pretty clean except we have one failing test on eeloo related to Python<br clear="none"></div><div><br clear="none"></div><div><a rel="nofollow" shape="rect" target="_blank" href="https://open.cdash.org/testDetails.php?test=516490674&build=4724245">https://open.cdash.org/testDet ails.php?test=516490674&build= 4724245</a></div><div><br clear="none"></div><div>It fails comparing a None to an int while other machines running that test pass. So I suspect it has something to do with the build/version/settings of python on it. I tried fixing the None int comparison but then it moved to a different failure, once again reminding me that python still lacks the elegant grace of Visual Basic (I am so baiting python users with that one)</div><div><br clear="none"></div><div><a rel="nofollow" shape="rect" target="_blank" href="https://gitlab.kitware.com/vtk/vtk/merge_requests/2359">https://gitlab.kitware.com/vtk /vtk/merge_requests/2359</a></div><div><br clear="none"></div><div>Anyone have a thought on what the right fix is?</div><div><br clear="none"></div><div>Thanks!</div><div>Ken<br clear="all"><div><br clear="none"></div>-- <br clear="none"><div class="yiv3645097601m_7023432184253920345m_8577259833820698672m_-2281178649223897747gmail-m_-1086856794735311128gmail_signature">Ken Martin PhD<div>Chairman & CFO<br clear="none">Kitware Inc.<br clear="none">28 Corporate Drive<br clear="none">Clifton Park NY 12065<br clear="none"><a rel="nofollow" shape="rect" href="">518 371 3971</a><div><br clear="none"></div><div><span style="font-size:10pt;font-family:tahoma, sans-serif;">This communication,
including all attachments, contains confidential and legally privileged
information, and it is intended only for the use of the addressee.  Access to this email by anyone else is
unauthorized. If you are not the intended recipient, any disclosure, copying,
distribution or any action taken in reliance on it is prohibited and may be
unlawful. If you received this communication in error please notify us
immediately and destroy the original message. 
Thank you.</span></div></div></div>
</div></div>
<br clear="none">______________________________ _________________<br clear="none">
Powered by <a rel="nofollow" shape="rect" target="_blank" href="http://www.kitware.com/">www.kitware.com</a><br clear="none">
<br clear="none">
Visit other Kitware open-source projects at <a rel="nofollow" shape="rect" target="_blank" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensou rce/opensource.html</a><br clear="none">
<br clear="none">
Search the list archives at: <a rel="nofollow" shape="rect" target="_blank" href="http://markmail.org/search/?q=vtk-developers">http://markmail.org/search/?q= vtk-developers</a><br clear="none">
<br clear="none">
Follow this link to subscribe/unsubscribe:<br clear="none">
<a rel="nofollow" shape="rect" target="_blank" href="http://public.kitware.com/mailman/listinfo/vtk-developers">http://public.kitware.com/mail man/listinfo/vtk-developers</a><span class="yiv3645097601m_7023432184253920345m_8577259833820698672HOEnZb"><font color="#888888"><br clear="none"></font></span></blockquote></div><span class="yiv3645097601m_7023432184253920345m_8577259833820698672HOEnZb"><font color="#888888"><br clear="none"><br clear="all"></font></span><div><br clear="none"></div>-- <br clear="none"><div class="yiv3645097601m_7023432184253920345m_8577259833820698672m_-2281178649223897747gmail_signature">______________________________ _____________<br clear="none">Andrew J. P. Maclean<br clear="none"><br clear="none">______________________________ _____________</div>
</div></div></div>
</blockquote></div><br clear="none"><br clear="all"><div><br clear="none"></div>-- <br clear="none"><div class="yiv3645097601m_7023432184253920345m_8577259833820698672gmail_signature">______________________________ _____________<br clear="none">Andrew J. P. Maclean<br clear="none"><br clear="none">______________________________ _____________</div>
</div>
</div></div></blockquote></div></div><br clear="none"><br clear="all"><div><br clear="none"></div>-- <br clear="none"><div class="yiv3645097601m_7023432184253920345gmail_signature">______________________________ _____________<br clear="none">Andrew J. P. Maclean<br clear="none"><br clear="none">______________________________ _____________</div>
</div></div></div></div><br><div class="yqt4739705124" id="yqt40557">_______________________________________________<br clear="none">Powered by www.kitware.com<br clear="none"><br clear="none">Visit other Kitware open-source projects at <a shape="rect" href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br clear="none"><br clear="none">Search the list archives at: <a shape="rect" href="http://markmail.org/search/?q=vtk-developers" target="_blank">http://markmail.org/search/?q=vtk-developers</a><br clear="none"><br clear="none">Follow this link to subscribe/unsubscribe:<br clear="none"><a shape="rect" href="http://public.kitware.com/mailman/listinfo/vtk-developers" target="_blank">http://public.kitware.com/mailman/listinfo/vtk-developers</a><br clear="none"><br clear="none"></div><br><br></div> </blockquote> </div> </div>  </div></div></body></html>