Matt had a proposal to support general grids, and somewhere inbetween that and what yt does now are logical Cartesian curvilinear / quadralaterial grids (some people use eta and xi for the coordinate names in 2-d for these). Should those types of grids be address in the field naming proposal or Matt's unstructured proposal (technically, these are structured, but ...)
perhaps off topic for this, but should yt know about the type of discretization for the grid -- i.e. finite-difference vs. finite-volume, and should that be indicated in the field name somehow? The only place I see this really coming into play is in creating derived fields -- at the moment everything is second-order accurate for a finite-volume code, but if someone has a higher-order code they might care about the accuracy that the conversions are done to, and perhaps yt should know about the discretization.
On Tue, Dec 23, 2014 at 2:01 PM, Nathan Goldbaum <nathan12343@gmail.com> wrote:_______________________________________________Hi all,I've just issued a pull request that bears some developer discussion.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:I'd like to propose a naming convention for fields that reference a coordinate system. Gas and particle fields should be of the form:(field_type, "<particle?>_<vector_field_name>_<coordinate>")while index fields for coordinates should be of the form:("index", "<coordinate>")This fits within our existing field naming convention for cartesian coordinates, e.g.:("gas", "velocity_x")(ptype, "particle_velocity_y")as well as our convention for index coordinate fields, e.g.:("index", "x")("index", "spherical_theta")This means that index fields do not need to explicitly reference themselves as positions. So we *won't* have field names like:("index", "position_x")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).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").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.I've implemented this for the particle fields (for the most part) in PR 1378:I'm happy to update the field naming YTEP if this proposed field naming scheme gets approval in this thread.What do you all think? Question, concerns?-Nathan
yt-dev mailing list
yt-dev@lists.spacepope.org
http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
--Michael ZingaleAssociate ProfessorDept. of Physics & Astronomy • Stony Brook University • Stony Brook, NY 11794-3800phone: 631-632-8225e-mail: Michael.Zingale@stonybrook.edu
_______________________________________________
yt-dev mailing list
yt-dev@lists.spacepope.org
http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org