Skip to content

Commit

Permalink
reverting to previoys commit
Browse files Browse the repository at this point in the history
  • Loading branch information
AadilLatif committed Mar 25, 2024
1 parent caf2373 commit b9ba2ba
Show file tree
Hide file tree
Showing 18 changed files with 38 additions and 38 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ RUN pip install --upgrade pip
# Install the python modules
RUN pip install -e .

ENV PYTHONPATH=/pydss/PyDSS
ENV PYTHONPATH=/PyDSS/PyDSS

EXPOSE 5000/tcp
EXPOSE 9090/tcp
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Welcome to the pydss Repository!

**Pydss** is a high level python interface for **OpenDSS** and provides the following functionalities
**PyDSS** is a high level python interface for **OpenDSS** and provides the following functionalities

Documentation on installation, setup and examples can be found here https://nrel.github.io/pydss/index.html
Documentation on installation, setup and examples can be found here https://nrel.github.io/PyDSS/index.html

4 changes: 2 additions & 2 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ model_tables:
python make_model_tables.py -o $(BUILDDIR)/model_tables

github: html
rm -rf source/pydss
sphinx-apidoc -o source/pydss ../pydss
rm -rf source/PyDSS
sphinx-apidoc -o source/PyDSS ../PyDSS
-git branch -D gh-pages
-git push origin --delete gh-pages
ghp-import -n -b gh-pages -m "Update documentation" ./build/html
Expand Down
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ pip install sphinx sphinx-rtd-theme
From docs directory:

```
sphinx-apidoc -o source/pydss ../pydss
sphinx-apidoc -o source/PyDSS ../PyDSS
```

## Build HTML Docs
Expand Down
6 changes: 3 additions & 3 deletions docs/source/Co-simulation Interfaces.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Following attributes can be configured for the HELICS interface.
Default values for additional simulation settings are as follows. For more information on how to appropriately set these values please look at HELICS documentaion

Once the HELICS co-simulation interface has been enabled, the next step is to set up ``publications`` and ``subscriptions`` to set up information exchange with external federates.
Pydss enables zero code setup of these modules. Each scenario can have its publlcation and subscription defination and is managed by two file in the ``ExportLists`` directory for a given scenario.
PyDSS enables zero code setup of these modules. Each scenario can have its publlcation and subscription defination and is managed by two file in the ``ExportLists`` directory for a given scenario.

publication tags (names) follow the following convertion

Expand Down Expand Up @@ -133,8 +133,8 @@ the same controller can be implemented as a pyController object in pydss.
The socket interface in pydss also come in handy, when setting up a hardware-in-loop type simulations and integrating the simulation
engine with actual hardware. Interfaces similar to raw socket implementations have been developed (to be open-sourced at a later time)
for Modbus-TCP and DNP3 communcations have developed and tested with pydss with sucess. A minimal socket interfacing example has
been provided as a pydss project in ~pydss/examples/external_interfaces. Within the folder,
~/pydss/examples/external_interfaces/pydss_project a scenario called 'socket' has been defined. Socket
been provided as a pydss project in ~PyDSS/examples/external_interfaces. Within the folder,
~/PyDSS/examples/external_interfaces/pydss_project a scenario called 'socket' has been defined. Socket
controller definations have been detailed with the 'pyControllerList' folder. An example of input requirements can be studied below.
This example will publish ``voltage magnitude`` (see Even set in Index) and ``real power`` for load ``Load.mpx000635970`` in the model. Subscribed
values will be used to update the ``kW`` property of the coupled load (Load.mpx000635970 in this case)
Expand Down
6 changes: 3 additions & 3 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ def find_version(*file_paths):
return version_match.group(1)
raise RuntimeError("Unable to find version string.")

project = 'pydss'
project = 'PyDSS'
copyright = '2019, Aadil Latif'
author = 'Aadil Latif'

# The full version, including alpha/beta/rc tags
release = find_version("../../pydss", "__init__.py")
release = find_version("../../PyDSS", "__init__.py")

# -- General configuration ---------------------------------------------------

Expand Down Expand Up @@ -98,7 +98,7 @@ def find_version(*file_paths):

redoc = [
{
'name': 'pydss API',
'name': 'PyDSS API',
'page': 'api',
'spec': 'spec/swagger.yml',
'embed': True,
Expand Down
4 changes: 2 additions & 2 deletions docs/source/hdf-data-format.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ the data then a suffix is added to the property name.

Common Metadata
===============
Pydss stores metadata that is common to all datasets in the root of the
PyDSS stores metadata that is common to all datasets in the root of the
scenario group. For example, the ``Timestamp`` dataset contains the simulation
timestamps (seconds since epoch) for all datasets that store values at every
time point. ::
Expand All @@ -56,7 +56,7 @@ time point. ::

Dataset Metadata
================
Pydss stores metadata for each dataset in HDF attributes as well as other
PyDSS stores metadata for each dataset in HDF attributes as well as other
datasets. This metadata describes the contents of datasets.

Attributes per dataset
Expand Down
10 changes: 5 additions & 5 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ PyDSS
#####

***********
About Pydss
About PyDSS
***********

Pydss is a Python wrapper for OpenDSS that aims to expand upon its
PyDSS is a Python wrapper for OpenDSS that aims to expand upon its
organizational, analytical, and visualization capabilities with these features:

- Allows the user to develop custom control algorithms for specific circuit elements and run them
Expand All @@ -25,7 +25,7 @@ organizational, analytical, and visualization capabilities with these features:
- Automates collection and analysis of circuit element results at each simulation time step.
- Flexible architecture allows users to develop extensions.

Pydss uses opendssdirect.py (https://pypi.org/project/OpenDSSDirect.py/) to communicate with
PyDSS uses opendssdirect.py (https://pypi.org/project/OpenDSSDirect.py/) to communicate with
OpenDSS.

.. _installation_label:
Expand Down Expand Up @@ -61,15 +61,15 @@ Alternatively, to get the lastest code from the master branch:
.. code-block:: bash
$ git clone https://github.com/NREL/PyDSS
$ pip install -e NREL-pydss
$ pip install -e PyDSS
Confirm the installation with this command. It should print the available commands::

$ pydss --help


*************
Running Pydss
Running PyDSS
*************
Refer to the :ref:`quick_start_label` for basic instructions on how to configure pydss to run a
simulation with an existing OpenDSS model.
Expand Down
2 changes: 1 addition & 1 deletion docs/source/reports.rst
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Adding New Reports
******************
Here's how to create a new report in pydss.

#. Create a new class in a Python file in ``pydss/reports``. The class must
#. Create a new class in a Python file in ``PyDSS/reports``. The class must
inherit from ``ReportBase``.
#. Implement the required methods:

Expand Down
2 changes: 1 addition & 1 deletion docs/source/spec/swagger.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions docs/source/spec/swagger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ paths:
required: true
schema:
type: string
example: C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples
example: C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples
style: form
explode: true
responses:
Expand Down Expand Up @@ -205,7 +205,7 @@ paths:
required: true
schema:
type: string
example: C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples
example: C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples
style: form
explode: true
responses:
Expand Down Expand Up @@ -330,7 +330,7 @@ paths:
Error tolerance: 0.001
Control mode: Static
Simulation Type: QSTS
Project Path: C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples
Project Path: C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples
Active Project: custom_contols
Active Scenario: base_case
DSS File: Master_Spohn_existing_VV.dss
Expand Down
2 changes: 1 addition & 1 deletion docs/source/tutorial.rst
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ set in each scenario's ``Exports.toml`` on a per-property basis.
``Line.LoadingPercent`` is an example. In this case pydss will read multiple
values for a line, compute a loading percentage, and store that. The
``limits`` field can be applied to these values. Refer to
``CUSTOM_FUNCTIONS`` in ``pydss/export_list_reader.py`` to see the options
``CUSTOM_FUNCTIONS`` in ``PyDSS/export_list_reader.py`` to see the options
available.
- Set ``sum_group_file = file_path`` where file_path is a JSON or TOML file
relative to the directory from which you will run pydss. The contents of the
Expand Down
6 changes: 3 additions & 3 deletions src/pydss/api/schema/PyDSS.v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
"Federate name": "PyDSS_x",
"Log Results": false,
"Max Control Iterations": 50,
"Project Path": "C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples",
"Project Path": "C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples",
"Simulation Type": "QSTS",
"Start Day": 1,
"Start Time (min)": 0,
Expand Down Expand Up @@ -347,7 +347,7 @@
"name": "path",
"required": true,
"schema": {
"example": "C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples",
"example": "C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples",
"type": "string"
},
"style": "form"
Expand Down Expand Up @@ -415,7 +415,7 @@
"name": "path",
"required": true,
"schema": {
"example": "C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples",
"example": "C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples",
"type": "string"
},
"style": "form"
Expand Down
6 changes: 3 additions & 3 deletions src/pydss/api/src/web/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ async def get_pydss_project_info(self, request, path):
required: true
schema:
type: string
example: C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples
example: C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples
responses:
'200':
description: Successfully retrieved project information
Expand Down Expand Up @@ -156,7 +156,7 @@ async def post_pydss_create(self, request):
"""

from zipfile import ZipFile
examples_path = os.path.join("C:/Users/alatif/Desktop/PyDSS_2.0/pydss/", 'examples')
examples_path = os.path.join("C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/", 'examples')
unzip_path = os.path.join(examples_path, "uploaded_opendss_project")
zip_path = os.path.join(examples_path, "uploaded_opendss_project.zip")

Expand Down Expand Up @@ -246,7 +246,7 @@ async def post_pydss(self, request):
Error tolerance: 0.001
Control mode: Static
Simulation Type: QSTS
Project Path: "C:/Users/alatif/Desktop/PyDSS_2.0/pydss/examples"
Project Path: "C:/Users/alatif/Desktop/PyDSS_2.0/PyDSS/examples"
Active Project: custom_contols
Active Scenario: base_case
DSS File: Master_Spohn_existing_VV.dss
Expand Down
2 changes: 1 addition & 1 deletion src/pydss/pyPostprocessor/pyPostprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def Create(project, scenario, ppInfo, dssInstance, dssSolver, dssObjects, dssObj
ScriptName = ppInfo.script
assert (ScriptName in pythonFiles), \
f"Definition for '{ScriptName}' post process script not found. \n" \
"Please define the controller in pydss/pyPostprocessor/PostprocessScripts"
"Please define the controller in PyDSS/pyPostprocessor/PostprocessScripts"
PostProcessor = POST_PROCESSES[ScriptName](
project,
scenario,
Expand Down
6 changes: 3 additions & 3 deletions src/pydss/registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,21 @@
"name": "NO_VRT",
"filename": os.path.join(
os.path.dirname(getattr(pydss, "__path__")[0]),
"pydss/pyControllers/Controllers/Settings/PvControllers.toml"
"PyDSS/pyControllers/Controllers/Settings/PvControllers.toml"
),
},
{
"name": "cpf",
"filename": os.path.join(
os.path.dirname(getattr(pydss, "__path__")[0]),
"pydss/pyControllers/Controllers/Settings/PvControllers.toml"
"PyDSS/pyControllers/Controllers/Settings/PvControllers.toml"
),
},
{
"name": "volt-var",
"filename": os.path.join(
os.path.dirname(getattr(pydss, "__path__")[0]),
"pydss/pyControllers/Controllers/Settings/PvControllers.toml"
"PyDSS/pyControllers/Controllers/Settings/PvControllers.toml"
),
},
],
Expand Down
4 changes: 2 additions & 2 deletions src/pydss/reports/reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,9 @@ def generate(self):
return filenames


# Note to devs: all subclasses of ReportBase need to reside in pydss/reports
# Note to devs: all subclasses of ReportBase need to reside in PyDSS/reports
# in order to be automatically imported. Otherwise, add a direct import in
# pydss/reports/__init__.py.
# PyDSS/reports/__init__.py.

class ReportBase(abc.ABC):
"""Base class for reports"""
Expand Down
2 changes: 1 addition & 1 deletion tests/test_custom_exports.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def test_custom_exports(cleanup_project):
assert "CurrentsMagAng" not in properties

# TODO: This metric no longer stores voltages in a dataframe.
# That functionality could be recovered in pydss/metrics.py or we could implement this with
# That functionality could be recovered in PyDSS/metrics.py or we could implement this with
# a different export property.
#node_names = scenario.list_element_names("Nodes", "VoltageMetric")
#dfs = scenario.get_filtered_dataframes("Nodes", "VoltageMetric")
Expand Down

0 comments on commit b9ba2ba

Please sign in to comment.