[Yt-svn] yt: Removing outdated script; updating image_writer and camera t...
hg at spacepope.org
hg at spacepope.org
Fri Sep 17 15:21:39 PDT 2010
hg Repository: yt
details: yt/rev/c0273aa7b0c9
changeset: 3402:c0273aa7b0c9
user: Matthew Turk <matthewturk at gmail.com>
date:
Fri Sep 17 15:21:35 2010 -0700
description:
Removing outdated script; updating image_writer and camera to be a bit nicer.
diffstat:
doc/wipe_svn.sh | 21 ---------------------
yt/visualization/image_writer.py | 3 +++
yt/visualization/volume_rendering/camera.py | 4 ++--
3 files changed, 5 insertions(+), 23 deletions(-)
diffs (59 lines):
diff -r 79f9e9053123 -r c0273aa7b0c9 doc/wipe_svn.sh
--- a/doc/wipe_svn.sh Fri Sep 17 12:30:27 2010 -0700
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-export PYTHONPATH=`pwd`/../
-make html
-
-echo "Files deleted since last svn commit:"
-echo " (generated with 'svn stat | grep \! ')"
-echo
-svn stat | grep \! |grep -v build
-echo
-
-echo "Files added since last svn commit:"
-echo " (generated with 'svn stat | grep \? ')"
-echo
-svn stat | grep \? | grep -v build/html
-echo
-
-echo "Examples files status:"
-echo
-svn stat ../examples/
-
-cd ./build/html/
-zip -r ../../docs_html.zip .
diff -r 79f9e9053123 -r c0273aa7b0c9 yt/visualization/image_writer.py
--- a/yt/visualization/image_writer.py Fri Sep 17 12:30:27 2010 -0700
+++ b/yt/visualization/image_writer.py Fri Sep 17 15:21:35 2010 -0700
@@ -167,6 +167,9 @@
(1024, 1024))
>>> write_image(frb1, "saved.png")
"""
+ if len(image.shape) == 3:
+ mylog.info("Using only channel 1 of supplied image")
+ image = image[:,:,0]
if color_bounds is None:
mi = na.nanmin(image[~na.isinf(image)])
ma = na.nanmax(image[~na.isinf(image)])
diff -r 79f9e9053123 -r c0273aa7b0c9 yt/visualization/volume_rendering/camera.py
--- a/yt/visualization/volume_rendering/camera.py Fri Sep 17 12:30:27 2010 -0700
+++ b/yt/visualization/volume_rendering/camera.py Fri Sep 17 15:21:35 2010 -0700
@@ -176,7 +176,7 @@
----------
fn : string, optional
If supplied, the image will be saved out to this before being
- returned. The scaling supplied will 2.0*image.std().
+ returned. Scaling will be to the maximum value.
Returns
-------
@@ -199,7 +199,7 @@
pbar.finish()
if fn is None:
return image
- write_bitmap(image, fn, 4.0*image.std())
+ write_bitmap(image, fn)
return image
def zoom(self, factor):
More information about the yt-svn
mailing list