<div dir="ltr">Yeah, that sounds good, Nathan.  I think we're probably mostly ready to go with this, but I know Britton wanted to hold off on this until people were back at their desks in January, which is basically this week.  I'd say update your PR as you need to, but don't yet merge, but I think your naming scheme is the way to go.  Sound OK?</div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jan 4, 2015 at 3:09 PM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span class="">On Sun, Jan 4, 2015 at 2:56 PM, John ZuHone <span dir="ltr"><<a href="mailto:jzuhone@gmail.com" target="_blank">jzuhone@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word">I think that the fact that we have two equally fairly complex naming schemes here is a sign that we need to have a better way of organizing fields in different coordinate systems, but in the absence of a clear proposal for this I guess I would go with Option #1. </div></blockquote><div><br></div></span><div>Well they're basically the same, just different a small difference in ordering.</div><div><br></div><div>Matt had an idea earlier in the thread based on context managers, but I'm not sure how that would necessarily ease accessing these fields, since we need to name them somehow, and asking for the 0th basis vector in the cylindical polar coordinate system is a bit less satisfying (to me) than asking for the cylindrical_radius component.</div><div><br></div><div>OK, so that's 5 votes in favor of my proposed naming scheme.  Would it be ok for me to update my open PR to implement the rest of the naming scheme?</div><div><br></div><div><a href="https://bitbucket.org/yt_analysis/yt/pull-request/1381/particle-position-and-velocity-fields-for/diff" target="_blank">https://bitbucket.org/yt_analysis/yt/pull-request/1381/particle-position-and-velocity-fields-for/diff</a><br></div><div><div class="h5"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div><div><div><br></div><div><div><blockquote type="cite"><div>On Jan 3, 2015, at 5:30 PM, Andrew Myers <<a href="mailto:atmyers2@gmail.com" target="_blank">atmyers2@gmail.com</a>> wrote:</div><br><div><div dir="ltr">I think both conventions are good, but I slightly prefer #1 (Nathan's naming) for being closer to what is done for Cartesian vector fields. </div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Jan 3, 2015 at 11:03 AM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Hi all,<div><br></div><div>Since this is one of the blockers for 3.1, I'd like to bump this thread.  It looks like we're now at 3 votes for my proposal and 2 votes for Cameron's proposal.</div><div><br></div><div>It would be great if a few more people could weigh in.  Take a look at Cameron's e-mail near the top of this thread if you need a reminder.</div><span><font color="#888888"><div><br></div><div>-Nathan</div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 29, 2014 at 1:52 PM, Ben Thompson <span dir="ltr"><<a href="mailto:bthompson2090@gmail.com" target="_blank">bthompson2090@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div>Hey all.<br><br></div>Nathan, thank you for setting this up, Cameron thank you for clearly outlining the naming conventions, and sorry to you all if I have been a bit quiet recently.<br><br></div>I am for option #1 which to me feels a bit more natural to go particle -> vector field -> coordinate system -> coordinate<br><br></div>As Britton has said, it would be best to finalise a decision in the new year (maybe at the end of the first full week? say the 8th?).<br><br></div>This PR in question also corrects numerical computation in the particle_spherical co-ordinate system too as well as updatin the field naming YTEP, so is also important to get out in it's own right.<span><font color="#888888"><br><br></font></span></div><span><font color="#888888">Ben<br><div><div><div><div><br><br><br><br></div></div></div></div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Dec 24, 2014 at 5:14 AM, Sam Skillman <span dir="ltr"><<a href="mailto:samskillman@gmail.com" target="_blank">samskillman@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hi all, I agree with Britton here that it would be good to table this until folks have time to read through this carefully. Thanks, Sam<div><div><br><br><div class="gmail_quote">On Tue Dec 23 2014 at 2:40:41 PM Britton Smith <<a href="mailto:brittonsmith@gmail.com" target="_blank">brittonsmith@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">I choose option #1.<div><br></div><div>Also, let's not be too quick to make big decisions here.  Many people are on break right now and so are unavailable, or are wanting to be.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Dec 23, 2014 at 3:42 PM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>On Tue, Dec 23, 2014 at 1:33 PM, Matthew Turk <span dir="ltr"><<a href="mailto:matthewturk@gmail.com" target="_blank">matthewturk@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Hi Cameron,<div class="gmail_extra"><br><div class="gmail_quote"><span>On Tue, Dec 23, 2014 at 11:56 AM, Cameron Hummels <span dir="ltr"><<a href="mailto:chummels@gmail.com" target="_blank">chummels@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Hi Nathan,<div><br></div><div>Thanks for your hard work on this PR (along with Ben Thompson).  The naming convention that I suggested in the issue a few weeks back (<a href="https://bitbucket.org/yt_analysis/yt/issue/947/consistent-field-naming-for-spherical-and" style="font-size:13px" target="_blank">https://bitbucket.org/yt_analysis/yt/issue/947/consistent-field-naming-for-spherical-and</a>) and in the discussion on your PR also matches with past convention.  It is slightly different than what you propose, but seems (to me at least) to be more easy to read because the adjective comes before the noun (e.g. spherical position) instead of the reverse (e.g. position spherical).</div><div><br></div></div></blockquote><div><br></div></span><div>I'm neutral to both of these, in that I am broadly neutral about the increasingly nested set of modifiers.  If forced, I think I'd go with your proposed convention.</div></div></div></div></blockquote><div><br></div></span><div>That's two votes against my convention (Cameron and Matt).  If no one else pipes up in favor of my convention in the next day or so, I'll go ahead and create a YTEP PR and update my PR to match.  This means we need to deprecate fewer fields, so it's probably simpler in the end...</div><span><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>What would be a lot nicer, in my opinion, would be if we had a way to do this more generically.  Like,</div><div><br></div><div>with data_object.rotate( ... ):</div><div>    prof1d = create_profile(data_object, "particle_position_x", "particle_mass")</div></div></div></div></blockquote><div><br></div></span><div>This is a much nicer syntax.  We should consider this for a future release.  If someone puts together a prototype for using data objects with context managers like this, I think we can have a big usability win for a lot of use cases.</div><div><br></div><div>Unfortunately we would probably still need to accept the names with modifiers for backward compatibility.</div><div><div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>and then just get rid of all the nested modified field names.  But I don't really think this is feasible.</div><div><br></div><div>-Matt</div><div><div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div></div><div>Where proposed naming convention #1 is:</div><div><br></div><div><span style="font-size:13px">(field_type, "<particle?>_<position/velocity>_<coordinate_system</span><span style="font-size:13px">>_<coordinate>") e.g. ('all', 'particle_position_spherical_phi')</span><br></div><div><span style="font-size:13px"><br></span></div><div><span style="font-size:13px">Proposed naming convention #2 is:</span></div><div><span style="font-size:13px"><br></span></div><div><span style="font-size:13px">(field_type, "<particle?>_<coordinate_system</span><span style="font-size:13px">>_<position/velocity>_<coordinate>") </span><span style="font-size:13px">e.g. ('all', 'particle_spherical_position_phi')</span><span style="font-size:13px"><br></span></div><div><br></div><div>Here are all of the relevant gas and particle fields each convention:</div><div><br></div><div><b>Cartesian</b> (convention #1 & #2 are the same)</div><span><div><br></div><div>('index', 'x')</div></span><div>('index', 'y')</div><div>('index', 'z')</div><span><div>('gas', 'velocity_x')</div></span><div>('gas', 'velocity_y')</div><div>('gas', 'velocity_z')</div><div><br></div><div>('all', 'particle_position_x')</div><div><div>('all', 'particle_position_y')</div></div><div><div>('all', 'particle_position_z')</div></div><div><div>('all', 'particle_velocity_x')</div></div><div><div>('all', 'particle_velocity_y')</div></div><div><div>('all', 'particle_velocity_z')</div></div><div><br></div><div>Convention #1 & #2 differ for the fields of cartesian position relative to the 'center' and 'normal' field parameters for the origin and z-vector:</div><div><br></div><div>#1 vs #2</div><div>('all', 'particle_position_relative_x')  vs. ('all', 'particle_relative_position_x')</div><div><div>('all', 'particle_position_relative_y')  vs. ('all', 'particle_relative_position_y')</div></div><div><div>('all', 'particle_position_relative_z')  vs. ('all', 'particle_relative_position_z')</div></div><div><div>('all', 'particle_velocity_relative_x')  vs. ('all', 'particle_velocity_position_x')</div><div>('all', 'particle_velocity_relative_y')  vs. ('all', 'particle_velocity_position_y')</div><div>('all', 'particle_velocity_relative_z')  vs. ('all', 'particle_velocity_position_z')</div><div><br></div><div><b>Spherical</b>:</div><div>#1 vs #2</div><div><br></div><div>('index', 'spherical_phi')</div><span><div>('index', 'spherical_radius')</div></span><span><div>('index', 'spherical_theta')</div></span><div>('gas', 'velocity_spherical_phi') vs      ('gas', 'spherical_velocity_phi')</div><div>('gas', 'velocity_spherical_theta') vs   ('gas', 'spherical_velocity_theta')</div><div>('gas', 'velocity_spherical_radius') vs ('gas', 'spherical_velocity_radius')</div><div><br></div><div>('all', 'particle_position_spherical_phi') vs      ('all', 'particle_spherical_position_phi')</div><div><div><div>('all', 'particle_position_spherical_theta') vs   ('all', 'particle_spherical_position_theta')</div></div></div></div><div><div>('all', 'particle_position_spherical_radius') vs ('all', 'particle_spherical_position_radius')</div><div><div><div>('all', 'particle_velocity_spherical_phi') vs       ('all', 'particle_spherical_velocity_phi')</div><div>('all', 'particle_velocity_spherical_theta') vs    ('all', 'particle_spherical_velocity_theta')</div></div><div><div>('all', 'particle_velocity_spherical_radius') vs  ('all', 'particle_spherical_velocity_radius')</div><div><br></div><div><b>Cylindrical</b>:</div><div>#1 vs #2</div><div><br></div><div><div>('index', 'cylindrical_phi') </div><div>('index', 'cylindrical_radius')</div><div>('index', 'cylindrical_theta')</div><div>('gas', 'velocity_cylindrical_phi') vs      ('gas', 'cylindrical_velocity_phi')</div><div>('gas', 'velocity_cylindrical_theta') vs   ('gas', 'cylindrical_velocity_theta')</div><div>('gas', 'velocity_cylindrical_radius') vs ('gas', 'cylindrical_velocity_radius')</div></div><div><br></div><div><div><div>('all', 'particle_position_cylindrical_phi') vs      ('all', 'particle_cylindrical_position_phi')</div><div>('all', 'particle_position_cylindrical_theta') vs   ('all', 'particle_cylindrical_position_theta')</div></div><div><div>('all', 'particle_position_cylindrical_radius') vs ('all', 'particle_cylindrical_position_radius')</div><div><div><div>('all', 'particle_velocity_cylindrical_phi') vs       ('all', 'particle_cylindrical_velocity_phi')</div><div>('all', 'particle_velocity_cylindrical_theta') vs    ('all', 'particle_cylindrical_velocity_theta')</div></div><div>('all', 'particle_velocity_cylindrical_radius') vs  ('all', 'particle_cylindrical_velocity_radius')</div></div></div></div><div><br></div><div><br></div><div><div>So what does the community think would be the best system here?  #1 or #2?  Either way it goes, I think this is a big improvement over the previous naming convention that had general inconsistencies.</div><div><br></div></div></div></div></div><div>Cameron</div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>On Tue, Dec 23, 2014 at 11:01 AM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div><div dir="ltr">Hi all,<div><br></div><div>I've just issued a pull request that bears some developer discussion.</div><div><br></div><div>Right now yt is a bit of a wild west in terms of the field naming convention for fields that reference a coordinate system.  See for example, see issue 947:</div><div><br></div><div><a href="https://bitbucket.org/yt_analysis/yt/issue/947/consistent-field-naming-for-spherical-and" target="_blank">https://bitbucket.org/yt_analysis/yt/issue/947/consistent-field-naming-for-spherical-and</a></div><div><br></div><div>I'd like to propose a naming convention for fields that reference a coordinate system.  Gas and particle fields should be of the form:</div><div><br></div><div>(field_type, "<particle?>_<vector_field_name>_<coordinate>")</div><div><br></div><div>while index fields for coordinates should be of the form:</div><div><br></div><div>("index", "<coordinate>")</div><div><br></div><div>This fits within our existing field naming convention for cartesian coordinates, e.g.:</div><div><br></div><div>("gas", "velocity_x")</div><div>(ptype, "particle_velocity_y")</div><div><br></div><div>as well as our convention for index coordinate fields, e.g.:</div><div><br></div><div>("index", "x")</div><div>("index", "spherical_theta")</div><div><br></div><div>This means that index fields do not need to explicitly reference themselves as positions.  So we *won't* have field names like:</div><div><br></div><div>("index", "position_x")</div><div><br></div><div>I don't like the above construction because it's a bit redundant ("index" implies that we are talking about a position or something similar).</div><div><br></div><div>Some existing field names will need to be changed to fit this.  In particular, some of the index fields will need to be renamed to be more verbose ("index", "spherical_r") becomes ("index", "spherical_radius") and (ptype, "particle_spherical_position_radius") becomes (ptype, "particle_position_spherical_radius").</div><div><br></div><div>Wherever an existing field name needs to change, I propose we mark the existing field name for deprecation, stub it out, and make it an alias for the field with the new field name.  In a future release, we can then remove the deprecated fields.</div><div><br></div><div>I've implemented this for the particle fields (for the most part) in PR 1378:</div><div><br></div><div><a href="https://bitbucket.org/yt_analysis/yt/pull-request/1378" target="_blank">https://bitbucket.org/yt_analysis/yt/pull-request/1378</a><br></div><div><br></div><div>I'm happy to update the field naming YTEP if this proposed field naming scheme gets approval in this thread.</div><div><br></div><div>What do you all think?  Question, concerns?</div><span><font color="#888888"><div><br></div><div>-Nathan</div><div><br></div><div><br></div></font></span></div>
<br></div></div><span>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></span></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div>Cameron Hummels<div>Postdoctoral Researcher</div><div>Steward Observatory</div><div>University of Arizona</div><div><a href="http://chummels.org/" target="_blank">http://chummels.org</a></div></div>
</font></span></div></div>
<br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div></div></div><br></div></div>
<br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div></div></div><br></div></div>
<br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div><br></div>
______________________________<u></u>_________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/<u></u>listinfo.cgi/yt-dev-spacepope.<u></u>org</a><br>
</blockquote></div>
</div></div><br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div><br></div>
_______________________________________________<br>yt-dev mailing list<br><a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br><a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br></div></blockquote></div><br></div></div></div></div><br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org" target="_blank">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div></div></div><br></div></div>
<br>_______________________________________________<br>
yt-dev mailing list<br>
<a href="mailto:yt-dev@lists.spacepope.org">yt-dev@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Cameron Hummels<div>Postdoctoral Researcher</div><div>Steward Observatory</div><div>University of Arizona</div><div><a href="http://chummels.org" target="_blank">http://chummels.org</a></div></div>
</div>