Skip to content

Commit

Permalink
materials access and remove pvgis image
Browse files Browse the repository at this point in the history
  • Loading branch information
tobin-ford committed Nov 19, 2024
1 parent 88d9732 commit 13d186c
Show file tree
Hide file tree
Showing 5 changed files with 112 additions and 13 deletions.
1 change: 1 addition & 0 deletions docs/source/user_guide/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ User Guide
NSRDB_API_Key
montecarlo
geospatial
materials
pv-variables-terms
contributing

Expand Down
107 changes: 107 additions & 0 deletions docs/source/user_guide/materials.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
.. materials::

Materials Storage and Access
============================

PVDeg contains a library of material parameters suitable for estimating the durability of materials and components.


These material parameters and other relevant information sit in a directiory at ``PVDegradationTools/pvdeg/data``.

This location can be quickly accessed through a special variable as shown below.

.. code-block:: Python
import pvdeg
file_path = os.path.join(pvdeg.DATA_DIR, <file-to-access.ext>)
.. code-block:: Python
from pvdeg import DATA_DIR
file_path = os.path.join(DATA_DIR, <file-to-access.ext>)
File Organization
------------------------------------
There are many files in this directory. We will generally be interested in one of the following files.


- `AApermeation.json <AApermeation_>`_ (acetic acid permeation parameters)
- `H2Opermeation.json <H2Opermeation_>`_ (water permeation parameters)
- `O2permeation.json <O2permeation_>`_ (oxygen permeation parameters)
- kinetic_parameters.json (letid/bolid parameters)
- DegradationDatabase.json (degredation models)

Material Parameters
------------------------------------
Each of the material permeation parameters files above is a json indexed by arbitrary names.
These are not a mapping of material names or aliases and are not consistent across the three files below.

- `AApermeation.json <AApermeation_>`_ (acetic acid permeation parameters)
- `H2Opermeation.json <H2Opermeation_>`_ (water permeation parameters)
- `O2permeation.json <O2permeation_>`_ (oxygen permeation parameters)

Accessing Material Parameters
-----------------------------

PVDeg provides convenience methods/functions to access material parameters. ``pvdeg.utilities.read_material`` is the simplest way to access material parameters. We will also show a sample use.

.. autofunction:: pvdeg.utilities.read_material

.. code-block:: Python
material_dict = pvdeg.utilities.read_material(
pvdeg_file = "AApermeation",
key = "AA001",
)
.. code-block:: Python
material_dict = pvdeg.utilities.read_material(
pvdeg_file = "H2Opermeation",
key = "W003",
)
The result of both of these functions will be a dictionary that looks like the following. The keys may vary depending on the structure of the json but this is the general idea.

.. code-block:: Python
{
"name": string,
"alias": string,
"contributor": string,
"source": string,
"Fickian": bool,
"Ead": numeric,
"Do": numeric,
"Eas": numeric,
"So": numeric,
"Eap": numeric,
"Po": numeric
}
There are also convenience functions to view and search jsons in jupyter notebooks called ``pvdeg.utilities.display_json`` and ``pvdeg.utilities.search_json``.


.. _AApermeation:

AApermeation
~~~~~~~~~~~~
.. literalinclude:: ../../../pvdeg/data/AApermeation.json
:language: json

.. _H2Opermeation:

H2Opermeation
~~~~~~~~~~~~
.. literalinclude:: ../../../pvdeg/data/H2Opermeation.json
:language: json

.. _O2permeation:

O2permeation
~~~~~~~~~~~~
.. literalinclude:: ../../../pvdeg/data/O2permeation.json
:language: json
Binary file not shown.
Binary file not shown.
17 changes: 4 additions & 13 deletions docs/source/user_guide/meteorological-data.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.. _meteorological-data.rst:
.. _meteorological-data:

Meterological Data
==================
Expand Down Expand Up @@ -44,19 +44,10 @@ PVGIS is free to use and does NOT require an api-key. It has a rate limit of 30
The PVDeg tutorials and examples use two datasets, `NSRDB`_ and `PVGIS`_. These are serially complete data including meteorological data and solar radiation (irradiance) measurements.
The methodology for these datasets varies but both are gridded geospatial datasets with similar attributes.

PVGIS data are seperated by satellite/model source. Each satellite source for PVGIS 5.2 is shown below.
PVGIS data are seperated by satellite/model source. Visit the links below for more information about the datasets.

.. image:: meteorological-data-details/pvgis-52.png
:alt: PVGIS 5.2 satellite sources, image missing

`<https://joint-research-centre.ec.europa.eu/photovoltaic-geographical-information-system-pvgis/pvgis-releases/pvgis-52_en>`_

Sources for PVGIS 5.3

.. image:: meteorological-data-details/pvgis-53.png
:alt: PVGIS 5.3 satellite sources, image missing

`<https://joint-research-centre.ec.europa.eu/photovoltaic-geographical-information-system-pvgis/pvgis-releases/pvgis-53_en>`_
- `PVGIS 5.2 <https://joint-research-centre.ec.europa.eu/photovoltaic-geographical-information-system-pvgis/pvgis-releases/pvgis-52_en>`_
- `PVGIS 5.3 <https://joint-research-centre.ec.europa.eu/photovoltaic-geographical-information-system-pvgis/pvgis-releases/pvgis-53_en>`_

.. _GIDS:
Issues with Gids
Expand Down

0 comments on commit 13d186c

Please sign in to comment.