Hi all,
Apologies for the spam, but I thought maybe the yt-users list would be good place to find some interest in this new library I wrote, pywwt:
http://www.jzuhone.com/pywwt
pywwt is a Python interface for the Microsoft World Wide Telescope (WWT, http://www.worldwidetelescope.org) Windows client, using the Layer Control API (LCAPI). The LCAPI provides an interface to WWT’s Layer Manager by sending data and information in the form of strings over HTTP. pywwt provides a straightforward Python interface to make these calls, enabling the control of WWT from scripts or an IPython notebook. Most importantly, it enables the passing of data created within a Python environment to WWT.
The upshot of this is that particle data that can be loaded into yt can be passed off to a World Wide Telescope client running on a Windows machine, either the same host or a host on the same network.
To see an example IPython notebook (complete with an example video!), visit: http://www.jzuhone.com/pywwt/pywwt_example.html
pywwt requires the following packages:
• NumPy
• Matplotlib
• AstroPy
• Beautiful Soup 4
• Requests
• Dateutil
pywwt can be installed from pip:
pip install pywwt
or download the source from http://github.com/jzuhone/pywwt and install:
python setup.py install
My use cases are limited, and I'd be interested in what others could do with it, so if you are interested please fork the code and help develop!
Best,
John Z
Hi,
I newly installed yt in my laptop, but ran into an error call
"NotImplementedError" when I tried to use 'pixelize_healpix' which used to
work fine in my another computer, the whole message is as followed:
img2d,count = pixelize_healpix(NP, img1d, resolution, resolution,
rotation)
File "grid_traversal.pyx", line 1127, in
yt.utilities.lib.grid_traversal.pixelize_healpix
(yt/utilities/lib/grid_traversal.c:14555)
NotImplementedError
Can any of you help to explain why this happens here? How can I fix it?
Thanks for your help!
Yong
Hi yt-users!
I'm new to yt and Python (I'm an IDL guy).
Currently, I'm using VisIt to visualize my FITS data cube. However, since I'm wandering through the fields of Python, I would really like to use yt as my default visualization tool.
Having said that, I would like to ask if somebody out there has some piece of code to read a FITS data cube into a Python array (I know how to do this already) and use yt to visualize it and make iso-surface plots (like the ones I've attached to this message). I went through the yt manual examples (especially the volume plot sections) but all I've got was some kind of blurred blotch (see figure "UniformGridData_volume_rendered.png").
Any help would be very appreciated.
Best regards!
m.
--Dr. Mairan Teodoro
NASA Goddard Space Flight Center
8800 Greenbelt Rd.
Greenbelt, MD 20771 USA
Bldg. 34, Rm. 321
301-286-6321
Code 667
http://asd.gsfc.nasa.gov/Mairan.Teodorohttp://etacar2014.wikidot.com
Hi all,
Sorry to bother you again, but I have another problem with the clump
finder. I have been able to run the script to find the clumps, wrote
them to a text file, and saved the clump object using
<pf.h.save_object(master_clump, 'myclumps')>. However, when I try to
read the object back in and get the lowest clumps using
master_clump = pf.h.load_object('myclumps')
leaf_clumps = get_lowest_clumps(master_clump)
I get an error saying:
Traceback (most recent call last):
File "./findclumps.py", line 66, in <module>
leaf_clumps = get_lowest_clumps(master_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 209, in get_lowest_clumps
if clump.children is None or len(clump.children) == 0:
AttributeError: 'NoneType' object has no attribute 'children'
Does this happen because the clump object didn't actually get saved? And
how can I check whether it did or not?
Thanks again!
Cheers,
Caroline
Hi all,
I'm currently running into and issue where I can't seem to figure out
how to control the x and y limits of my axes in a PhasePlot. Is this
possible? Or do I need to go the PlotCollection route?
Thanks!
Devin
--
Devin W. Silvia
Research Associate
Department of Physics and Astronomy
Michigan State University
www.devinsilvia.com
Dear YT-users,
My installation of yt on Ubuntu machine failed up on getting pip. I have tried to test the source of the problem first by installing pip as "sudo apt-get install python-pip". And I have pip installed. It turn out to be the same even when i do again "bash install_script.sh". Then, I also tried to verify these is not a network connection problem as it is saying in the error message"error: Download error for https://pypi.python.org/packages/source/p/pip/pip-1.5.tar.gz: Tunnel connection failed: 407 Proxy Authentication Required". I will be glad to receive your help on these.
Cheers,
Remudin
################
################
################
################
......
Installing Python. This may take a while, but don't worry. yt loves you.
Installing mercurial-2.8
Setting YT_DIR=/home/remudin/yt-x86_64/src/yt-hg/
Installing distribute
Installing pip
********************************************
FAILURE REPORT:
********************************************
Processing dependencies for distribute==0.6.32
Finished processing dependencies for distribute==0.6.32
After install bootstrap.
Creating /home/remudin/yt-x86_64/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg-info
Creating /home/remudin/yt-x86_64/lib/python2.7/site-packages/setuptools.pth
Searching for pip
Reading http://pypi.python.org/simple/pip/
Best match: pip 1.5
Downloading https://pypi.python.org/packages/source/p/pip/pip-1.5.tar.gz#md5=6969b8a8ad…
error: Download error for https://pypi.python.org/packages/source/p/pip/pip-1.5.tar.gz: Tunnel connection failed: 407 Proxy Authentication Required
********************************************
********************************************
Failure. Check /home/remudin/yt-x86_64/yt_install.log. The last 10 lines are above.
################
################
################
################
................................
.................................
Remudin Reshid; MEKURIA,
School of Physics, Wits University,
1 Jan Smuts Ave, Braamfontein, WITS 2050
Johannesburg, South Africa
................................
.................................
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="width:100%;">
<tr>
<td align="left" style="text-align:justify;"><font face="arial,sans-serif" size="1" color="#999999"><span style="font-size:11px;">This communication is intended for the addressee only. It is confidential. If you have received this communication in error, please notify us immediately and destroy the original message. You may not copy or disseminate this communication without the permission of the University. Only authorised signatories are competent to enter into agreements on behalf of the University and recipients are thus advised that the content of this message may not be legally binding on the University and may contain the personal views and opinions of the author, which are not necessarily the views and opinions of The University of the Witwatersrand, Johannesburg. All agreements between the University and outsiders are subject to South African Law unless the University agrees in writing to the contrary. </span></font></td>
</tr>
</table
Hi, everybody
I've been working off the example scripts on the yt website, and can't
quite seem to do what I want to do. I want to plot something like 20
tall/skinny images in a horizontal row, and label the time steps below, and
put the colorbar vertically. I am constrained to using frb's because my
images are not square. I have managed to make a plot with three such
images, although I haven't managed to put in the time step labels, and
there is white space between the images. But it was very much brute force
-- I had to create a separate set of axes for each image.
All the example scripts that use frb's use the "get_multi_plot" inside yt,
whereas the only example of a time series in the image plots uses the
AxesGrid from matplotlib. I have not managed to make the AxesGrid work with
an frb. There is also a non-image-plotting example in the bootcamp of
using "TimeSeriesData" to go through a lot of files, which would be great,
but I have not been able to figure out how to translate that into what I
need.
If anybody has a sample script of something vaguely similar to this, I
would really appreciate it!
thanks
kathy
--
Kathy DeGioia Eastwood, Ph.D.
Professor of Physics and Astronomy
Northern Arizona University
Flagstaff, AZ 86011-6010
Ph: 928-523-7159 FX: 928-523-1371
Kathy.Eastwood(a)nau.edu
deliveries: 602 S. Humphreys St., Bldg 19 Rm 209
Hi all,
I have a problem with the clump finder. When I try to run it on my
dataset (Enzo data), using a script that mostly follows the
find_clumps.py from the yt docs, I get the following, very long, error:
Traceback (most recent call last):
File "./findclumps.py", line 44, in <module>
find_clumps(master_clump, c_min, c_max, step)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 182, in find_clumps
find_clumps(clump, min_val*d_clump, max_val, d_clump)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 191, in find_clumps
elif (child._isValid()):
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/analysis_modules/level_sets/clump_handling.py",
line 145, in _isValid
self.function_value = eval(self.function)
File "<string>", line 1, in <module>
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 94, in __call__
return self._call_func_unlazy(args, kwargs)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 119, in _call_func_unlazy
retval = self.func(self._data_source, *args, **kwargs)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/derived_quantities.py",
line 378, in _IsBound
mass_to_use = data["TotalMass"]
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 332, in __getitem__
self.get_data(key)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 2618, in get_data
if self._generate_field(field):
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 362, in _generate_field
self[field] = self.pf.field_info[field](self)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/field_info_container.py",
line 395, in __call__
dd = self._function(self, data)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/universal_fields.py",
line 444, in _TotalMass
return (data["Density"]+data["particle_density"]) *
data["CellVolume"]
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 332, in __getitem__
self.get_data(key)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 2618, in get_data
if self._generate_field(field):
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 359, in _generate_field
self._generate_field_in_grids(field, ngt_exception.ghost_zones)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 369, in _generate_field_in_grids
grid[field] = self.__touch_grid_field(grid, field)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 95, in save_state
tr = func(self, grid, field, *args, **kwargs)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/data_containers.py",
line 373, in __touch_grid_field
return grid[field]
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 157, in __getitem__
self.get_data(key)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 200, in get_data
self._generate_field(field)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 145, in _generate_field
self[field] = self.pf.field_info[field](self)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/field_info_container.py",
line 395, in __call__
dd = self._function(self, data)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/universal_fields.py",
line 998, in _pdensity
if data["particle_position_x"].size == 0: return blank
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 157, in __getitem__
self.get_data(key)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 200, in get_data
self._generate_field(field)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/grid_patch.py",
line 145, in _generate_field
self[field] = self.pf.field_info[field](self)
File
"/home/uni05/cborm/YT/yt-x86_64/src/yt-hg/yt/data_objects/field_info_container.py",
line 396, in __call__
dd *= self._convert_function(data)
TypeError: unsupported operand type(s) for *=: 'NoneType' and 'float'
The main difference is that for the function passed to Clump, I'm using
'self.data.quantities["IsBound"](truncate=True,include_thermal_energy=True)
> 1.0' to find gravitationally bound objects.
When I run the clump finder on my data with a function that keeps clumps
based on the number of cells, it works fine.
I also tried running the script on the IsolatedGalaxy dataset as
demonstrated in the docs. This works fine too, also when the function is
set to the one mentioned above.
Anyone knows what's going on here?
Btw, my yt version is b118390aa42c.
Thanks!
Cheers,
Caroline
Is there a yt way to add an axes triad (like in VisIt -- just a simple
indicator of the direction for +x, +y, +z) to a volume render image?
Also on those lines, when I draw a box for the domain with
cam.draw_domain(im), is there a way to get it to add ticks and labels to
the box?
Thanks,
Mike
--
Michael Zingale
Associate Professor
Dept. of Physics & Astronomy • Stony Brook University • Stony Brook, NY
11794-3800
*phone*: 631-632-8225
*e-mail*: Michael.Zingale(a)stonybrook.edu
*web*: http://www.astro.sunysb.edu/mzingale
Hello out there, I'm trying to create a LightRay object for an enzo sim. I
get this error message:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File
"/data/codes/yt-x86_64/src/yt-hg/yt/analysis_modules/cosmological_observation/light_ray/light_ray.py",
line 117, in __init__
redshift_data=redshift_data)
File
"/data/codes/yt-x86_64/src/yt-hg/yt/analysis_modules/cosmological_observation/cosmology_splice.py",
line 119, in create_cosmology_splice
cosmology_splice.append({'time': self.simulation[0].current_time,
File "/data/codes/yt-x86_64/src/yt-hg/yt/data_objects/time_series.py",
line 117, in __getitem__
o = self._pre_outputs[key]
IndexError: list index out of range
The nearest and farthest redshift are both 0, which is the current redshift
of the dataset I was given. This may or may not have any bearing on the
problem. Thanks for the help!
-Claire Kopenhafer