Changeset 5847 for anuga_core/source/pypar-numeric/mandelbrot_example
- Timestamp:
- Oct 18, 2008, 9:13:18 PM (16 years ago)
- Location:
- anuga_core/source/pypar-numeric/mandelbrot_example
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/pypar-numeric/mandelbrot_example/compile.py
r5779 r5847 149 149 if os.name == 'posix' and os.uname()[4] == 'x86_64': 150 150 #Extra flags for 64 bit architectures 151 #s += ' -fPIC -m64' #gcc152 s += ' -fPIC -tp amd64' #pgcc151 s += ' -fPIC -m64' #gcc 152 #s += ' -fPIC -tp amd64' #pgcc 153 153 154 154 -
anuga_core/source/pypar-numeric/mandelbrot_example/mandel_sequential.py
r5779 r5847 12 12 # User definable parameters 13 13 kmax = 2**15 # Maximal number of iterations (=number of colors) 14 M = N = 700 # width = height = N (200, 400, 600, 700 are good)14 M = N = 200 # width = height = N (200, 400, 600, 700 are good) 15 15 16 16 # Region in complex plane -
anuga_core/source/pypar-numeric/mandelbrot_example/mandelplot.py
r5779 r5847 18 18 """ 19 19 20 from Tkinter import Frame, Canvas, TOP, NW, PhotoImage 20 #from Tkinter import Frame, Canvas, TOP, NW, PhotoImage 21 from pylab import imshow, show 21 22 from Numeric import transpose, Float 22 from Image import new # PIL23 #from Image import new # PIL 23 24 import time 24 25 … … 27 28 # User definable parameters 28 29 29 imtype = 'ppm' # Image format (e.g 'ppm', 'bmp', 'tiff')30 filename ='mandel' # Base filename30 #imtype = 'ppm' # Image format (e.g 'ppm', 'bmp', 'tiff') 31 #filename ='mandel' # Base filename 31 32 32 33 exponent = 0.998 # Exponent for morphing colors, good with kmax = 2**15 … … 47 48 A = transpose(A).astype(Float) 48 49 49 im = new("RGB", A.shape)50 #im = new("RGB", A.shape) 50 51 51 52 … … 78 79 79 80 # Save image to file 80 im.putdata(L) 81 im.save(filename + '.' + imtype, imtype) 81 imshow(A) 82 show() 83 84 #im.save(filename + '.' + imtype, imtype) 82 85 print 'Computed plot in %.2f seconds: ' %(time.time()-t0) 83 86 … … 88 91 # sys.exit() 89 92 90 import os91 os.system('xv %s' %(filename + '.' + imtype))93 #import os 94 #os.system('xv %s' %(filename + '.' + imtype)) 92 95 93 96
Note: See TracChangeset
for help on using the changeset viewer.