Jump to content

blender change environment variables [Python]

19_blackie_73

Hey guys,

i wanted to get gpu rendering running on my old dell inspiron 15r with i3 and some dedicated ati gpu. Here is what is said on the blender release notes:

 

 

For hardware which is not officially supported, it's possible to test split kernel work by setting the `CYCLES_OPENCL_SPLIT_KERNEL_TEST` environment variable to 1. It'll make all the OpenCL devices appear in User Preferences and will make sure split kernel is used on them.

source: http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.75/Cycles

 

my question is: how can i change it? do i have to open a specific python script or just type in the text editor: CYCLES_OPENCL_SPLIT_KERNEL_TEST=1 and run the script?

 

Thanks in advance!

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

If you're on Linux or Mac try:

export CYCLES_OPENCL_SPLIT_KERNEL_TEST=1
In a terminal, and then run your application.

If you're on Windows, Google changing an environment variable. I'm pretty sure you can use setx

--Neil Hanlon

Operations Engineer

Link to comment
Share on other sites

Link to post
Share on other sites

If you're on Linux or Mac try:

 

export CYCLES_OPENCL_SPLIT_KERNEL_TEST=1
In a terminal, and then run your application.

If you're on Windows, Google changing an environment variable. I'm pretty sure you can use setx

 

 

Linux variables should be set in ~/.profile or /etc/environment on certain distributions.

Link to comment
Share on other sites

Link to post
Share on other sites

Linux variables should be set in ~/.profile or /etc/environment on certain distributions.

 

Well he's not running it like that all the time, presumably--so exporting the variable is the correct way to test this.

 

If it needs to remain permanent, it should go in the user's profile, yes.

--Neil Hanlon

Operations Engineer

Link to comment
Share on other sites

Link to post
Share on other sites

you can enable opencl rendering on windows by open CMD in the blender install and type set CYCLES_OPENCL_TEST=all. then just go into user prefs and change the compute device the opencl.

                     ¸„»°'´¸„»°'´ Vorticalbox `'°«„¸`'°«„¸
`'°«„¸¸„»°'´¸„»°'´`'°«„¸Scientia Potentia est  ¸„»°'´`'°«„¸`'°«„¸¸„»°'´

Link to comment
Share on other sites

Link to post
Share on other sites

you can enable opencl rendering on windows by open CMD in the blender install and type set CYCLES_OPENCL_TEST=all. then just go into user prefs and change the compute device the opencl.

tried it with a .bat file with the same content, ran it, but i wasn't able to get it

anywhere a place to see which value this variable has?

but to be honest, i don't think that this thing can handle rendering so thanks for your effort

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

tried it with a .bat file with the same content, ran it, but i wasn't able to get it

anywhere a place to see which value this variable has?

but to be honest, i don't think that this thing can handle rendering so thanks for your effort

the i3 bulit in GPU should support openCL, i only used blender a little bit for college so other that what i posted i'm not much help sorry.

                     ¸„»°'´¸„»°'´ Vorticalbox `'°«„¸`'°«„¸
`'°«„¸¸„»°'´¸„»°'´`'°«„¸Scientia Potentia est  ¸„»°'´`'°«„¸`'°«„¸¸„»°'´

Link to comment
Share on other sites

Link to post
Share on other sites

the i3 bulit in GPU should support openCL, i only used blender a little bit for college so other that what i posted i'm not much help sorry.

no problem, was just a try to have some test runs with it, i don't need it because of  my 970 ;-)

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

no problem, was just a try to have some test runs with it, i don't need it because of  my 970 ;-)

I remember the iGPU on my i3 showing up in blender at one point, not sure how i did that though lol

                     ¸„»°'´¸„»°'´ Vorticalbox `'°«„¸`'°«„¸
`'°«„¸¸„»°'´¸„»°'´`'°«„¸Scientia Potentia est  ¸„»°'´`'°«„¸`'°«„¸¸„»°'´

Link to comment
Share on other sites

Link to post
Share on other sites

Hold up a second, they added support in the latest release. Theres no need for scripts, just open user prefs (Ctrl + Alt + U), go to the system tab, at the bottom left there is a computer device option, switch that to OpenCL, save user settings, then enable it for your project at the top of the redner tab

Link to comment
Share on other sites

Link to post
Share on other sites

Hold up a second, they added support in the latest release. Theres no need for scripts, just open user prefs (Ctrl + Alt + U), go to the system tab, at the bottom left there is a computer device option, switch that to OpenCL, save user settings, then enable it for your project at the top of the redner tab

i know that, but even with 2.75 where the support was official released my dgpu in my laptop is not showing up so i searched for a way to get my card showing up

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

  • 2 weeks later...

I don't think it's possible to run cycles on an AMD gpu... Try using luxrender but that won't be the same as cycles :(

 

Edit: Just read that 2.75 has amd gpu support... Now I'm really sad that I'm going on a trip in a few hours and won't be able to test gpu rendering on my r9-290 until I get back.

Link to comment
Share on other sites

Link to post
Share on other sites

I don't think it's possible to run cycles on an AMD gpu... Try using luxrender but that won't be the same as cycles :(

 

Edit: Just read that 2.75 has amd gpu support... Now I'm really sad that I'm going on a trip in a few hours and won't be able to test gpu rendering on my r9-290 until I get back.

what's your results?

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

what's your results?

Don't remember specific numbers but opencl rendering with luxrender was faster than cycles rendering on a cpu but the end result seemed less visually amazing than cycles. Ideally you would want a cuda capable gpu for cycles rendering since that would be the quickest and visually stunning. Of course if you don't have one and don't want to buy on luxrender is your best bet.

Link to comment
Share on other sites

Link to post
Share on other sites

Don't remember specific numbers but opencl rendering with luxrender was faster than cycles rendering on a cpu but the end result seemed less visually amazing than cycles. Ideally you would want a cuda capable gpu for cycles rendering since that would be the quickest and visually stunning. Of course if you don't have one and don't want to buy on luxrender is your best bet.

but cycles should now be able to work with your card - this says the blender homepage. I'm just curious how fast it'll be compared to my 970.

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

but cycles should now be able to work with your card - this says the blender homepage. I'm just curious how fast it'll be compared to my 970.

Well like I mentioned previously, I'm on a month long trip to Eastern Canada :( so you'll have to wait till September when I'll be able to test the latest version of Blender.

Link to comment
Share on other sites

Link to post
Share on other sites

Well like I mentioned previously, I'm on a month long trip to Eastern Canada :( so you'll have to wait till September when I'll be able to test the latest version of Blender.

you didn't say how long but i'm pretty curious about how good it'll work. so if you don't mind you could render some scene and give me that and we could compare times (when you are back)

GUITAR BUILD LOG FROM SCRATCH OUT OF APPLEWOOD

 

- Ryzen Build -

R5 3600 | MSI X470 Gaming Plus MAX | 16GB CL16 3200MHz Corsair LPX | Dark Rock 4

MSI 2060 Super Gaming X

1TB Intel 660p | 250GB Kingston A2000 | 1TB Seagate Barracuda | 2TB WD Blue

be quiet! Silent Base 601 | be quiet! Straight Power 550W CM

2x Dell UP2516D

 

- First System (Retired) -

Intel Xeon 1231v3 | 16GB Crucial Ballistix Sport Dual Channel | Gigabyte H97 D3H | Gigabyte GTX 970 Gaming G1 | 525 GB Crucial MX 300 | 1 TB + 2 TB Seagate HDD
be quiet! 500W Straight Power E10 CM | be quiet! Silent Base 800 with stock fans | be quiet! Dark Rock Advanced C1 | 2x Dell UP2516D

Reviews: be quiet! Silent Base 800 | MSI GTX 950 OC

 

Link to comment
Share on other sites

Link to post
Share on other sites

you didn't say how long but i'm pretty curious about how good it'll work. so if you don't mind you could render some scene and give me that and we could compare times (when you are back)

Of course! I'm pretty curious as well.

Link to comment
Share on other sites

Link to post
Share on other sites

  • 3 weeks later...

Alright I finally gave opencl rendering a try and it's much faster than cpu rendering but I will need to run some standardized tests before I get any solid numbers. In fact @19_blackie_73 what did you render for your testing? Anyways I'll need to check some more resources to figure out what the idea rendering setting would be for a gpu. Like this would be a pretty good start http://www.blenderguru.com/articles/4-easy-ways-to-speed-up-cycles/ since it appears as though changing the tile sizes can increase performance but this was directed at cuda gpus so even if I guess it would apply to opencl I'm not entirely certain.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×