Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Day night masking sphinx documentation #139

Merged

Conversation

kperrynrel
Copy link
Member

@kperrynrel kperrynrel commented Mar 23, 2022

Description

This PR adds data sets for NREL's SERF east installation, and runs day-night masking on 1-minute sampled and 15-minute sampled data. This example is for the Sphinx gallery. Related to #133.

Checklist

The following items must be addressed before the code can be merged.
Please don't hesitate to ask for help if you are unsure of how to accomplish any of the items.
You are free to remove any checklist items that do not apply or add additional items that are
not on this list

  • Clearly documented all new API functions with PEP257 and numpydoc compliant docstrings
  • Adds description and name entries in the appropriate "what's new" file
    in docs/whatsnew
    for all changes. Includes link to the GitHub Issue with :issue:`num`
    or this Pull Request with :pull:`num`. Includes contributor name
    and/or GitHub username (link with :ghuser:`user`).
  • Non-API functions clearly documented with docstrings or comments as necessary
  • Pull request is nearly complete and ready for detailed review

@kperrynrel kperrynrel self-assigned this Mar 23, 2022
@kperrynrel kperrynrel added the documentation Improvements or additions to documentation label Mar 23, 2022
@kperrynrel kperrynrel requested a review from kandersolar March 24, 2022 15:59
Copy link
Member

@kandersolar kandersolar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure I see much value in running the same code again on 15 minute data. I could support it if it was tweaking the optional parameters to get better results or something, but if it's essentially the same thing just with a different accuracy score, I'd lean towards removing it to keep the example more digestible.

docs/examples/day-night-masking.py Outdated Show resolved Hide resolved
docs/examples/day-night-masking.py Outdated Show resolved Hide resolved
docs/examples/day-night-masking.py Show resolved Hide resolved
docs/examples/day-night-masking.py Outdated Show resolved Hide resolved
@kperrynrel kperrynrel requested a review from cwhanse March 29, 2022 18:57
Copy link
Member

@cwhanse cwhanse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @kperrynrel

docs/examples/day-night-masking.py Outdated Show resolved Hide resolved
Comment on lines 74 to 75
how='numpy',
delta_t=67.0)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd delete the optional kwargs, no reason to suggest to a user of this example that values other than the default are needed.

@kperrynrel kperrynrel merged commit 9579731 into pvlib:master Apr 18, 2022
kperrynrel added a commit to kperrynrel/pvanalytics that referenced this pull request May 25, 2022
* v0.1.1 Release (pvlib#132)

* change pypi classifier from pre-alpha to beta

* remove unnecessary docs/requirements.txt

* whatsnew v0.1.1

* include 0.1.1 in whatsnew index

* link zenodo in readme

* Added clipping time series example for Sphinx documentation.

* added sphinx documentation + examples for running the clipping mask.

* fixed pep8 formatting errors.

* added a new whatsnew rst file for version 0.1.2

* removed close plot to visualize in sphinx.

* removed trailing whitespace.

* added tight layout for plot sizing.

* Updated the docs based on @kanderso-nrel's recs.

* fixed pep8 warning.

* removed trailing whitespace-pep8 issue.

* Added placeholder scripts for each function for Sphinx documentation.

* added sphinx module for completeness score.

* Update docs/examples/clipping.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clipping.py

Co-authored-by: Cliff Hansen <[email protected]>

* added each of the python scripts for detecting stale data, interpolated data, and check for daily data completeness.

* updated the interpolated-periods documentation

* cleaning up doc strings.

* updated the naming conventions of the sphinx docs.

* fixed pep8 error on stale data periods docs.

* made updates to the Sphinx docs based on kanderso-nrel's feedback.

* fixed pep8 errors.

* Edited some of the language in the sphinx doc comments.

* Added pv-terms json.

* added the documentation files for hampel, tukey, and zscore outlier detection.

* update the documentation to include separate data files for each of the different issues, to avoid further confusion.

* updated the interpolated data docs to pull the correct csv.

* More docstring cleanup.

* Updated outlier code to use the new outlier csv file.

* updated the outliers routine to handle varying indices.

* Docstring cleaning.

* made updates to the hovertext and the _round edits per @kanderso-nrel's comments

* updated diff to round on docstring per @kanderso-nrel's comment.

* updated the whatsnew doc with the outliers documentation.

* updated the hovertext info.

* updated the routine with the bug fix for whatsnew, and removed the initial graphing.

* added prints to visualize the imported data in example docs.

* Update docs/whatsnew/0.1.2.rst

Co-authored-by: Kevin Anderson <[email protected]>

* added new commenting based on @cwhanse's recommendations.

* fixed improper spelling in comments

* Day night masking sphinx documentation (pvlib#139)

* update the day-night masking example.

* update the day-night masking routine.

* added the SERF east data for running the day-night mask examples.

* added the day-night masking routine.

* Added section for comparing day-night mask to PVlib sunrise-sunset times.

* added separate printouts for sunrise and sunset time comparisons.

* added vertical lines for sunrise + sunset in plots

* update the routine to remove hardcoded file name.

* added update to the whatsnew file.

* removed a newline to see if we could get git actions to work.

* Made updates to documentation based on @kanderso-nrel's recommendations.

* Update docs/examples/day-night-masking.py

Co-authored-by: Cliff Hansen <[email protected]>

* Removed default kwargs for pvlib SPA sunrise-sunset function.

* Updating the commenting.

* fixed pep8 line length

Co-authored-by: Perry <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>

* Irradiance sphinx documentation (pvlib#140)

* added initial files for all of the irradiance documentation (need to edit).

* added RMIS example data for irradiance Sphinx documentation.

* added the new qcrad function.

* update the examples for both qcrad functions.

* added qcrad-limits documentation.

* ensured outputs for all irradiance functions in examples.

* added plotting functionality for some of the examples.

* added graphics for all of the irradiance documentation.

* added new line at end of file to stop pep8 failure.

* Clean up of doc strings for irradiance documentation.

* Fixed the docstring PEP8 error.

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Removed 'sampled' reference from docstring when describing data

* changed py:func to py:meth in docstring

* Updated the routine to calculate extraterrestrial radition as dni_extra for check_irradiance_limits_qcrad() function.

* Renamed the routine Clearsky Limits for Daily Insolation

* removed pep8 issues

* added the documentation to the whatsnew file.

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* added day-night mask to clearsky-limits-irradiance documentation

* removed hardcoded path!

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* switched the ordering of parameters in ) per @cwhanse's request.

* rearranged the order of inputs for irradiance_consistency_qcrad function in unit test.

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* updated clearsky-limits-irradiance example to comment on Ineichen model performance

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

Co-authored-by: Perry <[email protected]>
Co-authored-by: Kevin Anderson <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>

Co-authored-by: Kevin Anderson <[email protected]>
Co-authored-by: Perry <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>
kperrynrel added a commit that referenced this pull request Jun 24, 2022
* Add in pvanalytics update (#1)

* v0.1.1 Release (#132)

* change pypi classifier from pre-alpha to beta

* remove unnecessary docs/requirements.txt

* whatsnew v0.1.1

* include 0.1.1 in whatsnew index

* link zenodo in readme

* Added clipping time series example for Sphinx documentation.

* added sphinx documentation + examples for running the clipping mask.

* fixed pep8 formatting errors.

* added a new whatsnew rst file for version 0.1.2

* removed close plot to visualize in sphinx.

* removed trailing whitespace.

* added tight layout for plot sizing.

* Updated the docs based on @kanderso-nrel's recs.

* fixed pep8 warning.

* removed trailing whitespace-pep8 issue.

* Added placeholder scripts for each function for Sphinx documentation.

* added sphinx module for completeness score.

* Update docs/examples/clipping.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clipping.py

Co-authored-by: Cliff Hansen <[email protected]>

* added each of the python scripts for detecting stale data, interpolated data, and check for daily data completeness.

* updated the interpolated-periods documentation

* cleaning up doc strings.

* updated the naming conventions of the sphinx docs.

* fixed pep8 error on stale data periods docs.

* made updates to the Sphinx docs based on kanderso-nrel's feedback.

* fixed pep8 errors.

* Edited some of the language in the sphinx doc comments.

* Added pv-terms json.

* added the documentation files for hampel, tukey, and zscore outlier detection.

* update the documentation to include separate data files for each of the different issues, to avoid further confusion.

* updated the interpolated data docs to pull the correct csv.

* More docstring cleanup.

* Updated outlier code to use the new outlier csv file.

* updated the outliers routine to handle varying indices.

* Docstring cleaning.

* made updates to the hovertext and the _round edits per @kanderso-nrel's comments

* updated diff to round on docstring per @kanderso-nrel's comment.

* updated the whatsnew doc with the outliers documentation.

* updated the hovertext info.

* updated the routine with the bug fix for whatsnew, and removed the initial graphing.

* added prints to visualize the imported data in example docs.

* Update docs/whatsnew/0.1.2.rst

Co-authored-by: Kevin Anderson <[email protected]>

* added new commenting based on @cwhanse's recommendations.

* fixed improper spelling in comments

* Day night masking sphinx documentation (#139)

* update the day-night masking example.

* update the day-night masking routine.

* added the SERF east data for running the day-night mask examples.

* added the day-night masking routine.

* Added section for comparing day-night mask to PVlib sunrise-sunset times.

* added separate printouts for sunrise and sunset time comparisons.

* added vertical lines for sunrise + sunset in plots

* update the routine to remove hardcoded file name.

* added update to the whatsnew file.

* removed a newline to see if we could get git actions to work.

* Made updates to documentation based on @kanderso-nrel's recommendations.

* Update docs/examples/day-night-masking.py

Co-authored-by: Cliff Hansen <[email protected]>

* Removed default kwargs for pvlib SPA sunrise-sunset function.

* Updating the commenting.

* fixed pep8 line length

Co-authored-by: Perry <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>

* Irradiance sphinx documentation (#140)

* added initial files for all of the irradiance documentation (need to edit).

* added RMIS example data for irradiance Sphinx documentation.

* added the new qcrad function.

* update the examples for both qcrad functions.

* added qcrad-limits documentation.

* ensured outputs for all irradiance functions in examples.

* added plotting functionality for some of the examples.

* added graphics for all of the irradiance documentation.

* added new line at end of file to stop pep8 failure.

* Clean up of doc strings for irradiance documentation.

* Fixed the docstring PEP8 error.

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Kevin Anderson <[email protected]>

* Removed 'sampled' reference from docstring when describing data

* changed py:func to py:meth in docstring

* Updated the routine to calculate extraterrestrial radition as dni_extra for check_irradiance_limits_qcrad() function.

* Renamed the routine Clearsky Limits for Daily Insolation

* removed pep8 issues

* added the documentation to the whatsnew file.

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/clearsky-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* added day-night mask to clearsky-limits-irradiance documentation

* removed hardcoded path!

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* switched the ordering of parameters in ) per @cwhanse's request.

* rearranged the order of inputs for irradiance_consistency_qcrad function in unit test.

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* updated clearsky-limits-irradiance example to comment on Ineichen model performance

* Update docs/examples/qcrad-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/qcrad-consistency-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/examples/daily-insolation-limits-irradiance.py

Co-authored-by: Cliff Hansen <[email protected]>

Co-authored-by: Perry <[email protected]>
Co-authored-by: Kevin Anderson <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>

Co-authored-by: Kevin Anderson <[email protected]>
Co-authored-by: Perry <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>

* added back in all of the data shift files.

* Debug pep8 fixes.

* Added data_dir path to conftest.

* pep8 fix.

* renamed pytest fixture.

* added unit test for when ruptures is not available--up test coverage.

* retry to debug the ruptures package load

* fixed my ruptures delete and re-impoort test

* added import error test for ruptures

* more ruptures package unload-reload unit tests

* Update 0.1.2.rst

Updated PR number

* updates based on @kanderso-nrel's review

* renamed variables in the test file for data shifts from time_series to series

* updated the longest segment output to tuple + updated warning in docstring

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update docs/whatsnew/0.1.2.rst

Co-authored-by: Cliff Hansen <[email protected]>

* Updated PVSC citation.:

* Cleaned up any existing pep8 errors

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update pvanalytics/quality/data_shifts.py

Co-authored-by: Cliff Hansen <[email protected]>

* Update the docstring

Co-authored-by: Kevin Anderson <[email protected]>
Co-authored-by: Perry <[email protected]>
Co-authored-by: Cliff Hansen <[email protected]>
@kandersolar kandersolar added this to the v0.1.2 milestone Jun 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants