Skip to content

Commit ed931c0

Browse files
committed
Added readme and test
1 parent 75e6f86 commit ed931c0

File tree

4 files changed

+20
-0
lines changed

4 files changed

+20
-0
lines changed

examples/ray/mandelbrot/README.rst

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
==================
2+
Mandelbrot example
3+
==================
4+
5+
mandelbrot.py <height> <width> <max_iter> <tile_size>
6+
- height - height of image
7+
- width - width of image
8+
- max_iter - determines the "defintion" of zoom
9+
- tile_size - parallelization factor. each tile is computed in parallel
10+
11+
Generates mandelbrot.png - Computes a high-resolution image of the Mandelbrot set using parallel processing. It divides the image into smaller rectangular tiles and distributes these tiles across multiple worker tasks using Ray-Charm4py. Each task calculates whether each pixel in its tile belongs to the Mandelbrot set, storing the result in a memory-mapped file to avoid using excessive RAM. This approach enables efficient generation of very large fractal images by balancing performance and memory usage.
12+
13+
.. image:: mandelbrot_ray.png
14+
:alt: Mandelbrot Set Visualization
15+
:align: center
16+
File renamed without changes.
219 KB
Loading

test_config.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,5 +312,9 @@
312312
"condition": "numbaInstalled",
313313
"path": "examples/wave2d/wave2d.py",
314314
"args": "300 -1 --NO-RENDER"
315+
},
316+
{
317+
"path": "examples/ray/mandelbrot.py",
318+
"args": "100 100 10 10"
315319
}
316320
]

0 commit comments

Comments
 (0)