FRB extraction details
Hi, Everybody! If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data? d. -- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Hi Dave,
That's how it works by default, except at the boundaries of pixels that
don't line up with cell boundaries, where it computes partial
contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that
possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Sorry, I should clarify-- I tried doing
frb=proj( (W1,W2), (dx1, dx2)) and it complained that the second value wasn't a string. Is there a way to tell the frb that the tuple isn't a (value, unit) pair?
Thanks!
d.
On Mon, Apr 20, 2015 at 1:31 PM, David Collins
Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
wrote: Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
On Mon, Apr 20, 2015 at 10:32 AM, David Collins
Sorry, I should clarify--
I tried doing
frb=proj( (W1,W2), (dx1, dx2)) and it complained that the second value wasn't a string. Is there a way to tell the frb that the tuple isn't a (value, unit) pair?
This should be accounted for internally. If it's not doing that right now it's should be a straightforward fix. Can you create a short example that's not working for you and file an issue about it, or if you're feeling ambitious, submit a PR with a fix? That said, I think a tuple like `((3, 'pc'), (2, 'pc'))` will work.
Thanks! d.
On Mon, Apr 20, 2015 at 1:31 PM, David Collins
wrote: Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
wrote: Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer.
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
proj = ds.proj("density","z") Delta = (0.1,'code_length') dx = (1./512,'code_length') frb=proj.to_frb(Delta,dx) works great! frb=proj.to_frb( [Delta, Delta],[dx,dx]) raceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 22, in <module> frb=proj.to_frb( [Delta, Delta],[dx,dx]) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py",
Delta = ds.arr([0.1,0.1],'code_length') dx = ds.arr([1./512, 1./512], 'code_length') frb=proj.to_frb( Delta, dx) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 26, in <module> frb=proj.to_frb( Delta, dx) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py",
Hi, Nathan and Everybody--
I've tried several iterations of quantities with and without units and keep
getting errors. Here are the things I've tried, perhaps there's something
dumb I'm doing. I won't have any free space for deeper debugging for a few
weeks, but I can look for a fix then. Low priority, I can simply flag out
the zeros for now, but this is where I"m at right now:
Thanks a ton!
line 909, in to_frb
width = self.ds.quan(w, input_units = u)
File
"/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py",
line 1153, in __new__
raise RuntimeError("YTQuantity values must be numeric")
RuntimeError: YTQuantity values must be numeric
Also I tried using a ds.arr:
line 909, in to_frb
width = self.ds.quan(w, input_units = u)
File
"/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py",
line 1155, in __new__
dtype=dtype)
File
"/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py",
line 308, in __new__
input_array.units = Unit(input_units, registry=registry)
File
"/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/unit_object.py",
line 169, in __new__
% (unit_expr, type(unit_expr)))
yt.units.unit_object.UnitParseError: Unit representation must be a string
or sympy Expr. 0.1 code_length has type
On Mon, Apr 20, 2015 at 10:32 AM, David Collins
wrote: Sorry, I should clarify--
I tried doing
frb=proj( (W1,W2), (dx1, dx2)) and it complained that the second value wasn't a string. Is there a way to tell the frb that the tuple isn't a (value, unit) pair?
This should be accounted for internally. If it's not doing that right now it's should be a straightforward fix. Can you create a short example that's not working for you and file an issue about it, or if you're feeling ambitious, submit a PR with a fix?
That said, I think a tuple like `((3, 'pc'), (2, 'pc'))` will work.
Thanks! d.
On Mon, Apr 20, 2015 at 1:31 PM, David Collins
wrote: Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
wrote: Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer.
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
On Mon, Apr 20, 2015 at 10:57 AM, David Collins
Hi, Nathan and Everybody--
I've tried several iterations of quantities with and without units and keep getting errors. Here are the things I've tried, perhaps there's something dumb I'm doing. I won't have any free space for deeper debugging for a few weeks, but I can look for a fix then. Low priority, I can simply flag out the zeros for now, but this is where I"m at right now:
Thanks a ton!
proj = ds.proj("density","z") Delta = (0.1,'code_length') dx = (1./512,'code_length') frb=proj.to_frb(Delta,dx) works great! frb=proj.to_frb( [Delta, Delta],[dx,dx]) raceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 22, in <module> frb=proj.to_frb( [Delta, Delta],[dx,dx]) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py", line 909, in to_frb width = self.ds.quan(w, input_units = u) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 1153, in __new__ raise RuntimeError("YTQuantity values must be numeric") RuntimeError: YTQuantity values must be numeric
Delta = ds.arr([0.1,0.1],'code_length') dx = ds.arr([1./512, 1./512], 'code_length') frb=proj.to_frb( Delta, dx) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 26, in <module> frb=proj.to_frb( Delta, dx) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py",
Also I tried using a ds.arr: line 909, in to_frb width = self.ds.quan(w, input_units = u) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 1155, in __new__ dtype=dtype) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 308, in __new__ input_array.units = Unit(input_units, registry=registry) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/unit_object.py", line 169, in __new__ % (unit_expr, type(unit_expr))) yt.units.unit_object.UnitParseError: Unit representation must be a string or sympy Expr. 0.1 code_length has type
.
Any chance you can create issues for these examples so we don't drop them?
On Mon, Apr 20, 2015 at 1:36 PM, Nathan Goldbaum
wrote: On Mon, Apr 20, 2015 at 10:32 AM, David Collins
wrote: Sorry, I should clarify--
I tried doing
frb=proj( (W1,W2), (dx1, dx2)) and it complained that the second value wasn't a string. Is there a way to tell the frb that the tuple isn't a (value, unit) pair?
This should be accounted for internally. If it's not doing that right now it's should be a straightforward fix. Can you create a short example that's not working for you and file an issue about it, or if you're feeling ambitious, submit a PR with a fix?
That said, I think a tuple like `((3, 'pc'), (2, 'pc'))` will work.
Thanks! d.
On Mon, Apr 20, 2015 at 1:31 PM, David Collins
wrote: Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
wrote:
Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: > Hi, Everybody! > > If I make an FRB and have the resolution that of the finest zones, > how doe the coarser zones get filled? Is it possible for them to be forced > to be piecewise-constant sampling of the coarse data? > > d. > > -- > -- Sent from a computer. > _______________________________________________ > yt-users mailing list > yt-users@lists.spacepope.org > http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org >
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer.
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Done and done.
Thanks!
d.
On Mon, Apr 20, 2015 at 2:05 PM, Nathan Goldbaum
On Mon, Apr 20, 2015 at 10:57 AM, David Collins
wrote: Hi, Nathan and Everybody--
I've tried several iterations of quantities with and without units and keep getting errors. Here are the things I've tried, perhaps there's something dumb I'm doing. I won't have any free space for deeper debugging for a few weeks, but I can look for a fix then. Low priority, I can simply flag out the zeros for now, but this is where I"m at right now:
Thanks a ton!
proj = ds.proj("density","z") Delta = (0.1,'code_length') dx = (1./512,'code_length') frb=proj.to_frb(Delta,dx) works great! frb=proj.to_frb( [Delta, Delta],[dx,dx]) raceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 22, in <module> frb=proj.to_frb( [Delta, Delta],[dx,dx]) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py", line 909, in to_frb width = self.ds.quan(w, input_units = u) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 1153, in __new__ raise RuntimeError("YTQuantity values must be numeric") RuntimeError: YTQuantity values must be numeric
Delta = ds.arr([0.1,0.1],'code_length') dx = ds.arr([1./512, 1./512], 'code_length') frb=proj.to_frb( Delta, dx) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "tmp.py", line 26, in <module> frb=proj.to_frb( Delta, dx) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/data_objects/data_containers.py",
Also I tried using a ds.arr: line 909, in to_frb width = self.ds.quan(w, input_units = u) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 1155, in __new__ dtype=dtype) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/yt_array.py", line 308, in __new__ input_array.units = Unit(input_units, registry=registry) File "/home/dcollins4096/local-yt-2014-08-27/src/yt-hg/yt/units/unit_object.py", line 169, in __new__ % (unit_expr, type(unit_expr))) yt.units.unit_object.UnitParseError: Unit representation must be a string or sympy Expr. 0.1 code_length has type
. Any chance you can create issues for these examples so we don't drop them?
On Mon, Apr 20, 2015 at 1:36 PM, Nathan Goldbaum
wrote: On Mon, Apr 20, 2015 at 10:32 AM, David Collins
wrote: Sorry, I should clarify--
I tried doing
> frb=proj( (W1,W2), (dx1, dx2)) and it complained that the second value wasn't a string. Is there a way to tell the frb that the tuple isn't a (value, unit) pair?
This should be accounted for internally. If it's not doing that right now it's should be a straightforward fix. Can you create a short example that's not working for you and file an issue about it, or if you're feeling ambitious, submit a PR with a fix?
That said, I think a tuple like `((3, 'pc'), (2, 'pc'))` will work.
Thanks! d.
On Mon, Apr 20, 2015 at 1:31 PM, David Collins
wrote: Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins < dcollins4096@gmail.com> wrote:
Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: > Hi Dave, > > That's how it works by default, except at the boundaries of pixels > that don't line up with cell boundaries, where it computes partial > contributions. That can be turned off by setting antialias to false. > > Matt > > On Mon, Apr 20, 2015, 10:42 AM David Collins
> wrote: > >> Hi, Everybody! >> >> If I make an FRB and have the resolution that of the finest zones, >> how doe the coarser zones get filled? Is it possible for them to be forced >> to be piecewise-constant sampling of the coarse data? >> >> d. >> >> -- >> -- Sent from a computer. >> _______________________________________________ >> yt-users mailing list >> yt-users@lists.spacepope.org >> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org >> > > _______________________________________________ > yt-users mailing list > yt-users@lists.spacepope.org > http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org > > -- -- Sent from a computer.
-- -- Sent from a computer.
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
On Mon, Apr 20, 2015 at 10:31 AM, David Collins
Hi, Matt and Everybody--
I have another dumb question. If I want a non-square FRB, is that possible?
Yes, by specifying a tuple for the width.
d.
On Mon, Apr 20, 2015 at 12:38 PM, David Collins
wrote: Great. Thanks, Matt!
d.
On Mon, Apr 20, 2015 at 11:44 AM, Matthew Turk
wrote: Hi Dave,
That's how it works by default, except at the boundaries of pixels that don't line up with cell boundaries, where it computes partial contributions. That can be turned off by setting antialias to false.
Matt
On Mon, Apr 20, 2015, 10:42 AM David Collins
wrote: Hi, Everybody!
If I make an FRB and have the resolution that of the finest zones, how doe the coarser zones get filled? Is it possible for them to be forced to be piecewise-constant sampling of the coarse data?
d.
-- -- Sent from a computer. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- -- Sent from a computer.
-- -- Sent from a computer.
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
participants (3)
-
David Collins
-
Matthew Turk
-
Nathan Goldbaum