Hi all,
I'm having trouble adding text through a callback onto a phase plot.
I tried this code:
pc.add_phase_sphere(r200[j],'kpc',["Density","Temperature","CellMassMsun"],weight = None)
pc.set_zlim(1.0e-2,1.0e5)
pc.set_xlim(1.0e-30,5.0e-19)
pc.set_ylim(10.0,1.0e7)
pc.plots[-1].modify["text"]([0.92,0.92],redshift_string)
pc.save("output_%(file_num)s_branch_%yt-users(a)lists.spacepope.org(br)i"
% {"file_num":fn,"axis":ax,"br":branch_index[j]})
And I get this error:
Traceback (most recent call last):
File "test_phase_plots.py", line 41, in <module>
pc.save("output_%(file_num)s_branch_%(br)i" %
{"file_num":fn,"axis":ax,"br":branch_index[j]})
File
"/share/home/01112/tg803911/yt_17May2011/yt-x86_64/src/yt-hg/yt/visualization/plot_collection.py", line 157, in save
override=override, force_save=force_save))
File
"/share/home/01112/tg803911/yt_17May2011/yt-x86_64/src/yt-hg/yt/visualization/plot_types.py", line 108, in save_image
self._redraw_image()
File
"/share/home/01112/tg803911/yt_17May2011/yt-x86_64/src/yt-hg/yt/visualization/plot_types.py", line 903, in _redraw_image
self._run_callbacks()
File
"/share/home/01112/tg803911/yt_17May2011/yt-x86_64/src/yt-hg/yt/visualization/plot_types.py", line 800, in _run_callbacks
cb(self)
File
"/share/home/01112/tg803911/yt_17May2011/yt-x86_64/src/yt-hg/yt/visualization/plot_modifications.py", line 910, in __call__
y = plot.image._A.shape[1] * self.pos[1]
IndexError: tuple index out of range
The error arises in the save command, but the problem only happens when
I add the modify["text"] command. Any ideas?
Christine
Hi everyone,
I defined two fields, say, FieldOne and FieldTwo, to make 2D phase plot.
FieldOne is logarithmic by default, FieldTwo is linear (i.e., I set
take_log=False in add_field).
I want to produce a phase plot with logarithmic bins for FieldOne and
linear bins for FieldTwo, where the range of FieldTwo is [-10,10]
I thought that
pc.add_phase_object(dd, ["FieldOne", "FieldTwo", "CellMass"], weight=None, x_bins=100,y_bins=100, \
x_bounds=[1e0,1e10], y_bounds=[-10,10])
might do the job, but yt returns the error message:
Warning: invalid value encountered in log10
yt : [ERROR ] 2011-09-30 16:55:05,610 Your min/max values for x, y have
given me a nan.
yt : [ERROR ] 2011-09-30 16:55:05,610 Usually this means you are asking
for log, with a zero bound.
Traceback (most recent call last):
File "stability.py", line 352, in <module>
x_bounds=[1e0,1e10], y_bounds=[-10,10])
File
"/nics/e/sw/analysis/yt/2.1/sles11.1_gnu4.3.4/src/yt-hg/yt/visualization/plot_collection.py",
line 1149, in add_phase_object
lazy_reader)
File
"/nics/e/sw/analysis/yt/2.1/sles11.1_gnu4.3.4/src/yt-hg/yt/data_objects/profiles.py",
line 408, in __init__
raise ValueError
ValueError
It appears that add_phase_object treats FieldTwo logarithmically, although
it is linear.
So how can I do a log-linear phase plot?
Best,
Wolfram
Hi everyone,
There has been some discussion on the developers list about holding a yt
workshop within roughly the next six months. Ideally, this workshop would
have two parts. The first part would focus on education for users, from
basic intro to advanced usage, and perhaps spending time helping users craft
specific analysis routines. The second part would focus on development,
where we discuss new features we would like the code to have as well as
existing parts that are in need of some work, and then we actually get down
to working on these thing and coding. Since one of the main goals of yt is
to blur the lines between user and developer, we would try to aim the end of
the users portion at understanding yt internals and how best to work on the
code. The goal here would be to make a natural transition between the two
parts to maximize the number of people willing to stick around for the
development section.
As it's not yet clear what kind of external funding we can get, we would
like to make this as accessible as possible. This probably means choosing a
city that is a major airport hub, like Chicago, Detroit, etc. The timing
would be sometime early next year, currently anywhere between late January
and say March.
Before any of this can move forward, we really would like to know how many
people are actually interested in such a thing. If you are at all
interested in participating in a yt users/developers workshop, please
respond to this email in at least the following way:
I am [am not] interested in coming to a users workshop.
I am [am not] interested in coming to a developers workshop.
Any and all other comments are also welcome, as to timing, location,
content, etc.
Personally, I think this could really be a great thing, but let's here what
you think.
Britton
Hello,
I'm doing a simple analysis of looking for a gravitationally bound
sphere centred at the most dense point in each level of clumps by
iteratively increasing the radius from 0.5pc to 4pc until the derived
quantity "IsBound" is True.
I'm trying to use mpi4py as this iteration takes a very long time on
serial but I'm getting an error very similar to the error I received
when I tried mpi4py with clump finding routine:
Traceback (most recent call last):
bound = sp_cand.quantities["IsBound"](truncate=True,
include_thermal_energy=False)
File "/home/elee/accretion/analysis/codes/clump_excise_sph.py", line
71, in <module>
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 86, in __call__
self.func(e, *args, **kwargs)
self.func(e, *args, **kwargs)
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 351, in _IsBound
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 351, in _IsBound
self.func(e, *args, **kwargs)
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 351, in _IsBound
bound = sp_cand.quantities["IsBound"](truncate=True,
include_thermal_energy=False)
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 86, in __call__
bv_x,bv_y,bv_z = data.quantities["BulkVelocity"]()
bv_x,bv_y,bv_z = data.quantities["BulkVelocity"]()
AttributeError: 'FieldDetector' object has no attribute 'quantities'
self.func(e, *args, **kwargs)
AttributeError: 'FieldDetector' object has no attribute 'quantities'
File
"/home/jchong/ytdev/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 351, in _IsBound
bv_x,bv_y,bv_z = data.quantities["BulkVelocity"]()
AttributeError: 'FieldDetector' object has no attribute 'quantities'
bv_x,bv_y,bv_z = data.quantities["BulkVelocity"]()
AttributeError: 'FieldDetector' object has no attribute 'quantities'
It seems like parallelization loses the attribute "quantities"
associated with data, which, if I understand correctly, should be the
sphere object. Does this mean it somehow loses the sphere object that
was passed in as an argument? Or is this somehow related to the parallel
contouring algorithm that Britton has mentioned before?
Thanks.
Best Regards,
Eve
Hi all,
I have a pretty dumb question.
I have data from which I would like to take a slice with a resolution of
one cell per pixel. How can I do that ?
Thanks a lot,
JC
Hi everyone,
I was trying to use the YT installation on Kraken to create a merger tree and seem to have run into a problem with it being unable to import SQLite3. The error appears to stem from the following:
P190 yt : [ERROR ] 2011-09-20 00:02:03,730 sqlite3 not imported!
Digging around the YT installs, it appears that SQLite3 isn't there. Oddly, when I installed and built it in my home directory I still got the same error, so perhaps this is an issue with YT or Kraken rather than with the community install. Do anyone have an idea what might be going on? The output file is attached.
Thanks,
Brian
Hi all,
Nautilus and Kraken now have yt-2.2 installed. Please let me know if there
are any issues.
The yt module on Kraken is still using h5py 1.2.0. I will try to update it
to 1.3.1 as soon as I can.
Kraken:
module swap PrgEnv-pgi PrgEnv-gnu
module load yt/2.2
Nautilus:
module load yt/2.2
If no major issues come up, I will make them "default." That is, "module
load yt" will load version 2.2
Thanks,
Hari
Hi Stephen, I'm trying to do halo finding in a subregion of the box, but do
the various halo finders know that the boundary conditions are no longer
periodic? If periodic BC is on by default, is there a flag to switch off
periodicity during the subregion halo find?
From
G.S.