LBNL-ETA / pyradiance

Python wrapper for the validated RADIANCE ray-tracing engine
Other
13 stars 3 forks source link

Allow users to point to a local Radiance installation. #21

Open sariths opened 1 year ago

sariths commented 1 year ago

Edit: Based on the discussion below, this issue is a feature request for allowing users to set their own PATH and RAYPATH directories instead of relying on compiled binaries from pyradiance.

@taoning , How does one do a version check for Radiance executables? I tried running a rcontrib(params=['-version']) check but that did not work (because of required params).

Secondly, on Windows some executables are still being "compiled" as a perl files. Genbsdf is available as both perl and exe. image

Does it make sense to allow the users to override the pyradiance bin and choose their local Radiance installation instead?

taoning commented 1 year ago

Version check can be done with: radiance_version = pr.rtrace(None, None, version=True)

Perl file should all be converted to .exe. If not, then there is a bug in the setup.py.

Regarding letting users to point to local Radiance installation, I think one can set pr.BINPATH to any Radiance binaries directory.

taoning commented 1 year ago

Actually, setting pr.BINPATH directly wouldn't work since it's immutable. We'd need to make a dictionary called something like PATH and do PATH['bin'] = BINPATH. Then one can change PATH['bin'] to something else.

sariths commented 1 year ago

Actually, setting pr.BINPATH directly wouldn't work since it's immutable. We'd need to make a dictionary called something like PATH and do PATH['bin'] = BINPATH. Then one can change PATH['bin'] to something else.

2023-08-04 11_04_09-pyradTest – checkOconv py

Yup, I can confirm as much (I changed the path of rtrace after setting the BIN, so it should have returned an error but it didn't).

Perl file should all be converted to .exe. If not, then there is a bug in the setup.py.

This does not work right now (does not convert to exe). Should this be a separate issue then?

taoning commented 1 year ago

yes please