question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Runtime warning in singleaxis tracker

See original GitHub issue

Describe the bug ~\AppData\Local\Programs\Python\Python38-32\lib\site-packages\pvlib\tracking.py:555: RuntimeWarning: invalid value encountered in remainder surface_azimuth = surface_azimuth % 360

To Reproduce I used this code : import pandas as pd import numpy as np import pvlib azimuth = pd.read_csv("Azimuth.csv") zenith = pd.read_csv("solar2.csv") Plib = pvlib.tracking.SingleAxisTracker() data=Plib.singleaxis(apparent_zenith=zenith['SolarZenithAngle'],apparent_azimuth=azimuth['Azimuth']) print(data) Expected behavior Should have got the tracking values

Screenshots If applicable, add screenshots to help explain your problem.

Versions:

  • pvlib.__version__: 0.7.1
  • pandas.__version__: 1.0.1
  • python: 3.8.1

Additional context solar2.csv and Azimuth.csv are normal csv files with Irradiance and angle data Similar to issue #622 Didnt find a solution there or anywhere else

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
HrushikeshBodascommented, Mar 17, 2020

Sure Thanks a lot for your help!

0reactions
mikofskicommented, Mar 16, 2020

@HrushikeshBodas, we frequently see issues when the datetime series is not timezone aware. Can you make sure that the timezone is correct? You can use either the tz argument in pandas.DatetimeIndex or the .tz_localize method to convert a naive datetime series to timezone aware. A quick way to tell is to check the solar position, if the solar zenith is less than 90° during the day and a minimum near noon.

If you find you have now resolved this issue, perhaps you can close it? Thanks! image

Also I encourage you and others to read through and/or post on the pvlib Google Group or with the [pvlib] tag on StackOverflow before posting an issue. For more information, please see the documentation section on getting help.

Cheers!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tracking - | notebook.community
Walk through each step of the single axis tracking algorithm. ... Single axis tracker algorithm ... RuntimeWarning: invalid value encountered in greater ......
Read more >
Rotation Angle for the Optimum Tracking of One-Axis Trackers
γa. Axis azimuth, angle clockwise from north of the horizontal projection of the tracker axis, 0° to. +360°. If the axis tilt is...
Read more >
RuntimeWarning for np.array with NaN · Issue #11029 - GitHub
When i run the code A = np.full(7, np.nan) there is no issue. When i run A = np.full(8, np.nan) and for any...
Read more >
(PDF) Single axis automatic tracking system based on PILOT ...
Single axis automatic tracking system based on PILOT scheme to control the solar panel to optimize solar energy extraction.
Read more >
Single-axis tracking — pvlib python 0.9.4 documentation
Single-axis tracking#. Examples of modeling tilt angles for single-axis tracker arrays. This example shows basic usage of pvlib's tracker position ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found