pvfactors for Bifacial modelling

68 views
Skip to first unread message

amit kumar

unread,
Jun 24, 2024, 6:47:02 AMJun 24
to pvlib-python
Hi all,
I am using pvfactors_timeseries to get the backside irradiance from DHI,DNI and other parameters.
I installed pvlib successfully. While installing Solarfactors, i get some error. and when i run pvfactors_timeseries(), it does not find the module pvfactors.
Can someone help me here.
I have not used pvfactors before

Regards
Amit

Echedey Luis Álvarez

unread,
Jun 24, 2024, 6:53:06 AMJun 24
to pvlib-...@googlegroups.com

Hi Amit,
Can you provide the error you get when installing solarfactors? There's no way we can troubleshoot what is happening to you without error logs, a reproducible example, etc.

Please, run the following command too:

pip list
I suspect it has something to do with the dependencies and versions.

Best,
Echedey.

--
You received this message because you are subscribed to the Google Groups "pvlib-python" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pvlib-python...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pvlib-python/840c8f27-de18-45fa-a836-9cfd08fdbae4n%40googlegroups.com.
Message has been deleted
Message has been deleted
Message has been deleted

amit kumar

unread,
Jun 24, 2024, 2:56:43 PMJun 24
to pvlib-python
List of libraries and their versions for your reference if this helps.

Package            Version
------------------ -----------
asttokens          2.4.1
certifi            2024.6.2
charset-normalizer 3.3.2
cloudpickle        3.0.0
colorama           0.4.6
comm               0.2.2
contourpy          1.2.1
cycler             0.12.1
debugpy            1.8.1
decorator          5.1.1
executing          2.0.1
fonttools          4.53.0
h5py               3.11.0
idna               3.7
ipykernel          6.29.4
ipython            8.25.0
jedi               0.19.1
jupyter_client     8.6.2
jupyter_core       5.7.2
kiwisolver         1.4.5
matplotlib         3.9.0
matplotlib-inline  0.1.7
nest-asyncio       1.6.0
numpy              2.0.0
packaging          24.1
pandas             2.2.2
parso              0.8.4
pillow             10.3.0
pip                24.0
platformdirs       4.2.2
prompt_toolkit     3.0.47
psutil             6.0.0
pure-eval          0.2.2
pvlib              0.11.0
Pygments           2.18.0
pyparsing          3.1.2
python-dateutil    2.9.0.post0
pytz               2024.1
pywin32            306
pyzmq              26.0.3
requests           2.32.3
scipy              1.13.1
six                1.16.0
spyder-kernels     2.5.2
stack-data         0.6.3
tornado            6.4.1
traitlets          5.14.3
tzdata             2024.1
urllib3            2.2.2
wcwidth            0.2.13

amit kumar

unread,
Jun 24, 2024, 2:56:46 PMJun 24
to pvlib-python
Hi Echedey,
Thanks for responding. Here is the complete error msg i am getting while installing solarfactors. Hope this helps.

................................................................................................
PS C:\Users\26093> pip install solarfactors
Collecting solarfactors
  Using cached solarfactors-1.5.3-py2.py3-none-any.whl.metadata (12 kB)
Requirement already satisfied: pvlib>=0.9.0 in c:\users\26093\appdata\local\programs\python\python312\lib\site-packages (from solarfactors) (0.11.0)
Collecting shapely<2,>=1.6.4.post2 (from solarfactors)
  Using cached Shapely-1.8.5.post1.tar.gz (200 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  error: subprocess-exited-with-error

  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [33 lines of output]
      Traceback (most recent call last):
        File "C:\Users\26093\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
          main()
        File "C:\Users\26093\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\26093\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 112, in get_requires_for_build_wheel
          backend = _build_backend()
                    ^^^^^^^^^^^^^^^^
        File "C:\Users\26093\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 77, in _build_backend
          obj = import_module(mod_path)
                ^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\26093\AppData\Local\Programs\Python\Python312\Lib\importlib\__init__.py", line 90, in import_module
          return _bootstrap._gcd_import(name[level:], package, level)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
        File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
        File "<frozen importlib._bootstrap>", line 1310, in _find_and_load_unlocked
        File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
        File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
        File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
        File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
        File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
        File "<frozen importlib._bootstrap_external>", line 995, in exec_module
        File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
        File "C:\Users\26093\AppData\Local\Temp\pip-build-env-bj4ggxo1\overlay\Lib\site-packages\setuptools\__init__.py", line 16, in <module>
          import setuptools.version
        File "C:\Users\26093\AppData\Local\Temp\pip-build-env-bj4ggxo1\overlay\Lib\site-packages\setuptools\version.py", line 1, in <module>
          import pkg_resources
        File "C:\Users\26093\AppData\Local\Temp\pip-build-env-bj4ggxo1\overlay\Lib\site-packages\pkg_resources\__init__.py", line 2191, in <module>
          register_finder(pkgutil.ImpImporter, find_on_path)
                          ^^^^^^^^^^^^^^^^^^^
      AttributeError: module 'pkgutil' has no attribute 'ImpImporter'. Did you mean: 'zipimporter'?
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

[notice] A new release of pip is available: 24.0 -> 24.1
[notice] To update, run: python.exe -m pip install --upgrade pip

Thanks
Amit

On Monday, June 24, 2024 at 4:23:06 PM UTC+5:30 Echedey wrote:

amit kumar

unread,
Jun 24, 2024, 2:56:50 PMJun 24
to pvlib-python
Thanx for responding Echedey.
Here is the complete error msg i am getting while installing solarfactors:
#.........................................

Thanks

On Monday, June 24, 2024 at 4:23:06 PM UTC+5:30 Echedey wrote:

Echedey Luis Álvarez

unread,
Jun 24, 2024, 5:01:30 PMJun 24
to pvlib-...@googlegroups.com
I have been able to reproduce your error with Python 3.12 on Ubuntu 22.04 LTS.
After researching for a bit, I don't find a quick fix for you. My recommendation is to downgrade Python to 3.11 and work from there, installation goes normally with it. I will report this back to the solarfactors repository, and once we have a working solution we will send you a notification. Expect this to take some days to fix.

Best,
Echedey.

Mark Campanelli

unread,
Jun 24, 2024, 5:12:15 PMJun 24
to pvlib-python
Echedey,

  Looks like versioning is a bit old school in solarfactors. I'd be willing to convert it to something simpler using setuptools-scm like I did here: https://github.com/NREL/PVDegradationTools/pull/37

-Mark

Echedey Luis Álvarez

unread,
Jun 24, 2024, 5:25:46 PMJun 24
to pvlib-...@googlegroups.com

I was going to give it a shot right now, thou I had in mind upgrading versioneer. That makes much more sense, and since it's part of the pvlib repo, I think it's time to unify that part of the infrastructure too. Cross-referencing tracking issue at solarfactors: https://github.com/pvlib/solarfactors/issues/16

Thanks Mark, your help will be pretty much appreciated.

amit kumar

unread,
Jun 28, 2024, 3:10:55 PMJun 28
to Echedey Luis Álvarez, pvlib-...@googlegroups.com
Thanks for your effort Echedey. I ll try again with what you suggested.

Regards
Amit

Reply all
Reply to author
Forward
0 new messages