<div dir="ltr"><div>> <span style="color:rgb(33,33,33)">I don't think it should be relegated to the "officially discouraged" ghetto of `.legacy_index`</span></div><div><br></div>The way I read it, the new spelling lof that would be the explicit but not discouraged `image.vindex[rr, cc]`.<div><br></div><div>> <span style="color:rgb(33,33,33)">I would reserve warnings for the cases where the current behavior is something no one really wants, like mixing slices and integer arrays.</span> <br><br>These are the cases that would only be available under `legacy_index`.<div><br></div><div>Eric</div></div></div><br><div class="gmail_quote"><div dir="ltr">On Mon, 25 Jun 2018 at 23:54 Robert Kern <<a href="mailto:robert.kern@gmail.com">robert.kern@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Mon, Jun 25, 2018 at 11:29 PM Andrew Nelson <<a href="mailto:andyfaff@gmail.com" target="_blank">andyfaff@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Tue, 26 Jun 2018 at 16:24, Juan Nunez-Iglesias <<a href="mailto:jni.soma@gmail.com" target="_blank">jni.soma@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><u></u>





<div><div>> Plain indexing arr[...] should return an error for ambiguous cases. [...] This includes every use of vectorized indexing with multiple integer arrays.<br></div>
<div><br></div>
<div>This line concerns me. In scikit-image, we often do:<br></div>
<div><br></div>
<div>rr, cc = coords.T  # coords is an (n, 2) array of integer coordinates<br></div>
<div>values = image[rr, cc]<br></div>
<div><br></div>
<div>Are you saying that this use is deprecated? Because we love it at scikit-image. I would be very very very sad to lose this syntax.</div></div></blockquote><div><br></div><div> I second Juan's sentiments wholeheartedly here.</div></div></div></blockquote></div><div><br></div></div><div dir="ltr">And thirded. This should not be considered deprecated or discouraged. As I mentioned in the previous iteration of this discussion, this is the behavior I want more often than the orthogonal indexing. It's a really common way to work with images and other kinds of raster data, so I don't think it should be relegated to the "officially discouraged" ghetto of `.legacy_index`. It should not issue warnings or (eventual) errors. I would reserve warnings for the cases where the current behavior is something no one really wants, like mixing slices and integer arrays.</div><div dir="ltr"><br clear="all"><div><br></div>-- <br><div dir="ltr" class="m_-4094986491375501952m_-4044838253844029202gmail_signature" data-smartmail="gmail_signature">Robert Kern</div></div>
_______________________________________________<br>
NumPy-Discussion mailing list<br>
<a href="mailto:NumPy-Discussion@python.org" target="_blank">NumPy-Discussion@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/numpy-discussion" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/numpy-discussion</a><br>
</blockquote></div>