Developer API

This is the class and function reference of pvfactors. For clarity and simplicity, all inherited methods and attributes have been removed from the class descriptions as there were often too many irrelevant ones coming from base packages like shapely.

geometry

The geometry sub-package of pvfactors implements multiple classes that make the construction of a 2D geometry for a PV array intuitive and scalable. It is meant to be decoupled from irradiance and view factor calculations so that it can be used independently for other purposes, like visualization for instance. The following schematics summarizes the organization of the classes in this sub-package.

../_images/class_organization.png

base

Base classes for pvfactors geometry subpackage.

BaseSurface

Base surfaces will be extensions of LineString classes, but adding an orientation to it (normal vector).

PVSurface

PV surfaces inherit from BaseSurface.

ShadeCollection

A group of PVSurface objects that all have the same shading status.

PVSegment

A PV segment will be a collection of 2 collinear and contiguous shade collections, a shaded one and an illuminated one.

BaseSide

A side represents a fixed collection of PV segments objects that should all be collinear, with the same normal vector

BasePVArray

Base class for PV arrays in pvfactors.

pvrow

Module will classes related to PV row geometries

TsPVRow

Timeseries PV row class: this class is a vectorized version of the PV row geometries.

TsSide

Timeseries side class: this class is a vectorized version of the BaseSide geometries.

TsSegment

A TsSegment is a timeseries segment that has a timeseries shaded collection and a timeseries illuminated collection.

PVRowSide

A PV row side represents the whole surface of one side of a PV row.

PVRow

A PV row is made of two PV row sides, a front and a back one.

pvground

Classes for implementation of ground geometry

TsGround

Timeseries ground class: this class is a vectorized version of the PV ground geometry class, and it will store timeseries shaded ground and illuminated ground elements, as well as pv row cut points.

TsGroundElement

Special class for timeseries ground elements: a ground element has known timeseries coordinate boundaries, but it will also have a break down of its area into n+1 timeseries surfaces located in the n+1 ground zones defined by the n ground cutting points.

PVGround

Class that defines the ground geometry in PV arrays.

pvarray

Module containing PV array classes, which will use PV rows and ground geometries.

OrderedPVArray

An ordered PV array has a flat horizontal ground, and pv rows which are all at the same height, with the same surface tilt and azimuth angles, and also all equally spaced.

timeseries

Timeseries geometry tools. They allow the vectorization of geometry calculations.

TsShadeCollection

Collection of timeseries surfaces that are all either shaded or illuminated.

TsSurface

Timeseries surface class: vectorized representation of PV surface geometries.

TsLineCoords

Timeseries line coordinates class: will provide a helpful shapely-like API to invoke timeseries coordinates.

TsPointCoords

Timeseries point coordinates: provides a shapely-like API for timeseries point coordinates.

viewfactors

The viewfactors sub-package of pvfactors implements the methods used to calculate view factors from pvfactors PV array objects.

calculator

Module with classes and functions to calculate views and view factors

VFCalculator

This calculator class will be used for the calculation of view factors for OrderedPVArray, and it will rely on both VFTsMethods and AOIMethods

timeseries view factor methods

Module with view factor calculation tools

VFTsMethods

This class contains all the methods used to calculate timeseries view factors for all the surfaces in OrderedPVArray

view factor aoi methods

Module containing AOI loss calculation methods

AOIMethods

Class containing methods related to calculating AOI losses for OrderedPVArray objects.

irradiance

The irradiance sub-package of pvfactors implements all irradiance related models and methods that can be applied to pvfactors PV array objects.

base

Module with Base classes for irradiance models

BaseModel

Base class for irradiance models

models

Module containing irradiance models used with pv array geometries

IsotropicOrdered

Diffuse isotropic sky model for OrderedPVArray.

HybridPerezOrdered

Model is based off Perez diffuse light model, and applied to pvfactors OrderedPVArray objects.

engine

This module contains the engine class that will run the complete timeseries simulations.

PVEngine

Class putting all of the calculations together into simple workflows.

run

Module containing the functions to run engine calculations in normal or parallel mode.

run_timeseries_engine

Run timeseries simulation without multiprocessing.

run_parallel_engine

Run timeseries simulation using multiprocessing.

report

Module containing examples of report builder functions and classes.

example_fn_build_report

Example function that builds a report when used in the PVEngine with full or fast mode simulations.

ExampleReportBuilder

A class is required to build reports when running calculations with multiprocessing because of python constraints