Title: BuddhabrotCL Post by: woronoi on June 17, 2016, 04:48:02 PM Suddenly, I have updated my C# OpenCL buddhabrot renderer. Metropolis-Hastings kernel and another external kernels.
Open source project: GitHub (https://github.com/nikvoronin/BuddhabrotCL) Download latest release: BuddhabrotCL (https://github.com/nikvoronin/BuddhabrotCL/releases/latest) (https://cloud.githubusercontent.com/assets/11328666/16513624/ddb64a4a-3f6e-11e6-8caa-8b8baac8a2a2.jpg) (https://cloud.githubusercontent.com/assets/11328666/16513633/f04544cc-3f6e-11e6-9942-454b540f9a82.jpg) (https://cloud.githubusercontent.com/assets/11328666/16513641/f9b44ce2-3f6e-11e6-8ada-915e37c4be15.jpg) Title: Re: BuddhabrotCL v1.3 Post by: lycium on June 18, 2016, 01:15:46 AM Something seems a little strange about your use of OpenCL / parallel computation... for example in this code: https://github.com/nikvoronin/BuddhabrotCL/blob/master/src/BuddhabrotCL/cl_halton.c
This seems to be a single work item, which computes the data for the entire buffer; each work item is independent, so a better way would be to have each element compute the i'th element of randomXYBuffer, then you spawn bufferSize work items instead of 1. I dare say it's not really worth using a separate kernel/buffer for this computation, can just be computed in the main Buddhabrot kernel. Title: Re: BuddhabrotCL v1.3 Post by: woronoi on June 21, 2016, 07:47:09 PM I dare say it's not really worth using a separate kernel/buffer for this computation, can just be computed in the main Buddhabrot kernel. You are right this is a weak place of program Title: Re: BuddhabrotCL Post by: woronoi on June 22, 2016, 03:46:55 PM In release v1.5 xorshift randomizer is in kernel. It become much faster.
Title: BuddhabrotCL 1.6 Post by: woronoi on June 23, 2016, 02:16:23 PM New release v1.6 with updated kernels.
(https://github.com/nikvoronin/BuddhabrotCL/raw/master/doc/004.jpg) I have changed random number generator. The same speed but better visual quality. Before (https://img-fotki.yandex.ru/get/95108/97637398.e/0_e1b63_64551570_orig.jpg) After (https://img-fotki.yandex.ru/get/49312/97637398.e/0_e1b64_62b2bc1e_orig.jpg) Title: BuddhabrotCL 1.7 Post by: woronoi on June 25, 2016, 10:03:14 PM Why not to draw classic figures?
(https://img-fotki.yandex.ru/get/26439/97637398.e/0_e1f20_104ef6b_orig.jpg) (https://img-fotki.yandex.ru/get/60682/97637398.e/0_e1f22_9597831a_orig.jpg) (https://img-fotki.yandex.ru/get/120031/97637398.e/0_e1f23_4e45caa_orig.jpg) (https://img-fotki.yandex.ru/get/96932/97637398.e/0_e1f21_f8931d10_orig.jpg) Title: BuddhabrotCL 1.8 Post by: woronoi on June 30, 2016, 04:47:59 PM OpenCL Metropolis-Hastings.
Naive method (https://cloud.githubusercontent.com/assets/11328666/16492200/9e7edcd2-3ee9-11e6-87ce-c459d1656272.png) Metropolis-Hastings (https://cloud.githubusercontent.com/assets/11328666/16492232/be66cc1c-3ee9-11e6-8630-5ec0b5658254.png) Title: Re: BuddhabrotCL Post by: ker2x on September 13, 2016, 08:41:42 PM very cool, i'll take a look !
Feel free to explore my buddhabrot generator, you may find some code/optimisation you like : https://github.com/ker2x/buddha I also have old buddhabrot openCL code here https://github.com/ker2x/WinBuddhaOpenCL I'll check your code in the next few days :D Title: Re: BuddhabrotCL Post by: ker2x on September 13, 2016, 09:01:38 PM a quick check show me we have very similar code :)
(well, i didn't implement MH in openCL but it's present in buddha++ in good old c++) However i use a slightly different xorshift. You may want to implement it and see if there is any difference, i'm very interested. It should be slower however. GFX cards are not happy with this kind of code :) Code: __kernel void xorshift( Title: Re: BuddhabrotCL Post by: Chillheimer on September 13, 2016, 09:38:25 PM beautiful tool. had completely forgotten about it.
works like a charm and produces awesome pictures. thank you very much for sharing this! Title: Re: BuddhabrotCL Post by: woronoi on September 14, 2016, 09:58:07 AM very cool, i'll take a look ! Feel free to explore my buddhabrot generator, you may find some code/optimisation you like : https://github.com/ker2x/buddha I also have old buddhabrot openCL code here https://github.com/ker2x/WinBuddhaOpenCL I'll check your code in the next few days :D Thnx a lot, great stuff. I think there are some useful parts for later development. a quick check show me we have very similar code :) (well, i didn't implement MH in openCL but it's present in buddha++ in good old c++) I have began the exploration of OpenCL from your WinBuddhaOpenCL but later rewrote a lot of code. That's why :) However i use a slightly different xorshift. You may want to implement it and see if there is any difference, i'm very interested. It should be slower however. GFX cards are not happy with this kind of code :) Xorshift isn't so good and produces repetitive artefacts when you implement it inside OpenCL kernel. I prefer Taus88. It generates smoother image and fast enough. You can compare those: Kernel --> RNG --> cl_taus88.c / cl_xorshift.c Title: Re: BuddhabrotCL Post by: Chillheimer on September 27, 2016, 11:17:30 PM I thought I'd post a few images to show what awesome looking results this great program gives.
thx again for sharing this with us! (http://fractalogy.org/downloads/pictures/buddha/buddha1_edit1.jpg) (http://fractalogy.org/downloads/pictures/buddha/buddha2-edt.jpg) (http://fractalogy.org/downloads/pictures/buddha/buddha5b-edt.jpg) (http://fractalogy.org/downloads/pictures/buddha/buddha6b-edt.jpg) (http://fractalogy.org/downloads/pictures/buddha/buddha7-edt.jpg) (http://fractalogy.org/downloads/pictures/buddha/buddha8edt.jpg) Title: BuddhabrotCL 1.8.2 Post by: woronoi on November 17, 2016, 09:10:54 AM Minor changes. Just added choice of compute devices.
Direct link to download: BuddhabrotCL-bin-1.8.2.zip (https://github.com/nikvoronin/BuddhabrotCL/releases/download/v1.8.2/BuddhabrotCL-bin-1.8.2.zip) (https://cloud.githubusercontent.com/assets/11328666/20380811/521b5c50-acb5-11e6-9302-17d0f5513914.png) Title: Re: BuddhabrotCL Post by: Chillheimer on November 17, 2016, 04:21:44 PM awesome!
this also solved the problem that my pc used only one of the 8 cores.. computation is now 8 times faster- wohooo! :) Title: Re: BuddhabrotCL Post by: mclarekin on November 18, 2016, 04:21:36 AM @ Chillheimer. 8 times faster, that must feel good. O0 O0 O0
@woronoi. I love the speed of OpenCL. And you have made choosing compute_device so simple O0 O0 O0 Title: Re: BuddhabrotCL Post by: Chillheimer on November 19, 2016, 02:34:31 PM I've had the same problem in the last version and as I've started to do longer renderings to get more details of zoomed in sections this really becomes a problem:
When I safe pictures after longer rendertimes (like 12hours+) the chances of crashing while export seems to rise very much. After 24hours I can be pretty sure that as soon as I hit 'safe' it will crash. The result is a half-safed png as attached (downsized, was 7680² resolution), it seems to crash at different points. And all the days of rendering are lost. I don't kjnow what more info I could provide you with but I really hope you find a solution to this. maybe a different way of saving the progress before exporting, so that even if it crashes, not all progress is lost and one can continue at the last savepoint? -happens on cpu as well as gpu -not sure but I feel it happens much more often after I switched filter type from linear/square to log&log10 -large rendersizes of over 7680*7680 -core i7-3770, 32gb ram, windows 10 64 bit -Sapphire Vapor-X Radeon R9 290 Tri-X OC, 4096 MB GDDR5 (besides that: this is currently my absolute favourit program, running 24/7, chewing out the most impressive pictures I've ever seen of the mandelbrot-set - and I've seen a lot! will share, when I'm ready ;)) Title: Re: BuddhabrotCL Post by: woronoi on November 21, 2016, 10:06:39 AM Awful. I'll try fix it ASAP.
Title: Re: BuddhabrotCL Post by: woronoi on March 19, 2017, 10:58:18 PM New release: BuddhabrotCL-bin-1.8.4.zip (https://github.com/nikvoronin/BuddhabrotCL/releases/download/v1.8.4/BuddhabrotCL-bin-1.8.4.zip)
Title: Re: BuddhabrotCL Post by: Chillheimer on March 19, 2017, 11:05:13 PM *me jumps on it* ;)
opens fine, but as soon as I start to render i get "sorry, can't build kernel! Open CL error code detected: BuildProgramFailure" no matter if I chose the opencl-emulation or just my cpu. it still works in 1.82 if I try the same thing a second time the error message changes to "sorry can't buid kernel! --and then in german, I try to translate-- the objectlink was not assigned to an object-entity" Title: Re: BuddhabrotCL Post by: woronoi on March 20, 2017, 06:43:53 AM @Chillheimer, I can't reproduce that. Try to copy `cl_mh.c` from 1.8.2 to 1.8.4, choose it under the `kernel` menu and run it.
Title: Re: BuddhabrotCL Post by: woronoi on March 24, 2017, 02:25:18 PM Use `cl_heuristic.c` for high iterations but not in a deep zoom
and `cl_metropolis.c` for deep zoom but not at high iterations. About coloring: Iterations Max (maxI) = 1 000 000 low color % = 0.001 * maxI = 1000 mid color % = 0.02 * maxI = 20 000 Tint = BGR Blue = 0..1 000 Green = 1 000..20 000 Red = 20 000..1 000 000 See an example on the picture below (https://cloud.githubusercontent.com/assets/11328666/24295272/faf58216-10aa-11e7-9da3-79591a30aae3.jpg) Title: Re: BuddhabrotCL Post by: Chillheimer on March 24, 2017, 02:34:28 PM Hi
replacing that file with the 1.8.2 version works (though it crashed repeatedly when I tried 1million+ iterations and when I choose a different kernel-file, like the ones you suggested I still get that error. Title: Re: BuddhabrotCL Post by: woronoi on March 24, 2017, 05:05:41 PM Next release: BuddhabrotCL-bin-1.8.5.zip (https://github.com/nikvoronin/BuddhabrotCL/releases/download/v1.8.5/BuddhabrotCL-bin-1.8.5.zip) Chillheimer, you should try to use kernels under the `kernel/Compatibility` folder. |