Skip to content

Commit

Permalink
Merge pull request #109 from engineerjoe440/dev/explore-#108
Browse files Browse the repository at this point in the history
Prepare for 0.3.0 Release... Ready or Not...
  • Loading branch information
engineerjoe440 authored May 13, 2023
2 parents c1e1ce7 + ad7b11d commit 3a01a4e
Show file tree
Hide file tree
Showing 24 changed files with 144 additions and 143 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
if [ -f test/pytestrequires.txt ]; then pip install -r test/pytestrequires.txt; fi
if [ -f test/requirements.txt ]; then pip install -r test/requirements.txt; fi
pip install .
python3 -c "import electricpy; print('electricpy.__file__')"
- name: Test with pytest
Expand Down
37 changes: 0 additions & 37 deletions .github/workflows/pythonpackage.yml

This file was deleted.

4 changes: 2 additions & 2 deletions .github/workflows/sphinx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
run: |
python -m pip install --upgrade pip
cp logo/ElectricpyLogo.svg docsource/static/ElectricpyLogo.svg
pip install -r docsource/sphinxrequires.txt
pip install -r docsource/requirements.txt
- name: Build Sphinx docs
if: success()
run: |
Expand All @@ -33,7 +33,7 @@ jobs:
- name: Generate Coverage Badge
if: success()
run: |
pip install -r test/pytestrequires.txt
pip install -r test/requirements.txt
coverage run --source=./electricpy -m pytest
coverage-badge -o docs/html/coverage.svg
Expand Down
29 changes: 29 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"
# You can also specify other tool versions:
# nodejs: "19"
# rust: "1.64"
# golang: "1.19"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docsource/conf.py

# If using Sphinx, optionally build your docs in additional formats such as PDF
# formats:
# - pdf

# Optionally declare the Python requirements required to build your docs
python:
install:
- requirements: docsource/requirements.txt
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,11 @@ notebooks!)

## Installing / Getting Started

1. Install ElectricPy with `pip`
1. ElectricPy has a few basic installation options for use with `pip`. For most
common users, use the following command to install ElectricPy with `pip`

```
pip install electricpy
pip install electricpy[full]
```

2. Check installation success in Python environment:
Expand Down Expand Up @@ -103,8 +104,17 @@ and installing locally.
- [matplotlib](https://matplotlib.org/)
- [SciPy](https://scipy.org/)
- [SymPy](https://www.sympy.org/en/index.html)

#### Optional Dependencies

For numerical analysis (install with `pip install electricpy[numerical]`):

- [numdifftools](https://numdifftools.readthedocs.io/en/latest/)

For fault analysis (install with `pip install electricpy[fault]`)

- [arcflash](https://github.com/LiaungYip/arcflash)


## Get Involved / Contribute

Expand Down Expand Up @@ -153,7 +163,6 @@ opportunity to take advantage of this project.
For more information regarding this resource, please contact Joe Stanley

- <[email protected]>
- <[email protected]>

## License and Usage

Expand Down
23 changes: 23 additions & 0 deletions cspell.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"version": "0.2",
"ignorePaths": [],
"dictionaryDefinitions": [],
"dictionaries": [],
"words": [
"electricpy",
"epmath",
"fsolve",
"matplotlib",
"parallelz",
"phasor",
"phasorlist",
"phasorplot",
"phasors",
"powerset",
"pyplot",
"scipy",
"visu"
],
"ignoreWords": [],
"import": []
}
2 changes: 1 addition & 1 deletion docsource/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', "sphinxrequires.txt"]
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', "requirements.txt"]

templates_path = ["_templates"]

Expand Down
File renamed without changes.
6 changes: 1 addition & 5 deletions electricpy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,22 @@
################################################################################


from .version import NAME, VERSION
import cmath as _c
from inspect import getframeinfo as _getframeinfo
from inspect import stack as _stack
from warnings import showwarning as _showwarning

import matplotlib.pyplot as _plt
# Import Supporting Modules
import numpy as _np
from scipy.integrate import quad as integrate

# Import Submodules
from .version import NAME, VERSION
from .constants import *
from .phasors import phasor, parallelz

__version__ = VERSION

# Define Cycle Time Function


def tcycle(ncycles=1, freq=60):
r"""
Time of Electrical Cycles.
Expand Down
4 changes: 2 additions & 2 deletions electricpy/bode.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@

from cmath import exp as _exp

# Import External Dependencies

import matplotlib.pyplot as _plt
import numpy as _np
import scipy.signal as _sig
from numpy import pi as _pi
# Import Local Dependencies

from electricpy.math import convolve

# Define System Conditioning Function
Expand Down
1 change: 0 additions & 1 deletion electricpy/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"""
################################################################################

# Import Supporting Dependencies
import numpy as _np
import cmath as _c

Expand Down
1 change: 0 additions & 1 deletion electricpy/conversions.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
"""
################################################################################

# Import Local Requirements
from electricpy.constants import WATTS_PER_HP, Aabc, A012, KWH_PER_BTU

# Import Required Packages
Expand Down
6 changes: 2 additions & 4 deletions electricpy/fault.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,12 @@
"""
################################################################################

# Import Necessary Dependencies
import numpy as _np
import matplotlib.pyplot as _plt
from scipy.optimize import fsolve as _fsolve

# Import Local Dependencies
from .constants import *
from .conversions import seq_to_abc
from electricpy.constants import *
from electricpy.conversions import seq_to_abc


def _phaseroll(M012, reference):
Expand Down
1 change: 0 additions & 1 deletion electricpy/latex.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

import cmath as _c

# Import Required Packages
import numpy as _np


Expand Down
4 changes: 1 addition & 3 deletions electricpy/machines.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,11 @@
"""
################################################################################

# Required Imports
import cmath as _c
import numpy as _np
from scipy.optimize import fsolve as _fsolve

# Import Locals
from .phasors import compose
from electricpy.phasors import compose


# Define Transformer Short-Circuit/Open-Circuit Function
Expand Down
1 change: 0 additions & 1 deletion electricpy/math.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
"""
################################################################################

# Import Required Packages
import numpy as _np
import scipy.signal as _sig
from scipy.integrate import quad as integrate
Expand Down
1 change: 1 addition & 0 deletions electricpy/passive.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
Filled with methods related capacitors.
"""
################################################################################

import numpy as _np


Expand Down
1 change: 0 additions & 1 deletion electricpy/phasors.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
"""
################################################################################

# Import Required Packages
import numpy as _np
import cmath as _c

Expand Down
5 changes: 1 addition & 4 deletions electricpy/thermal.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,9 @@
"""
################################################################################


# Import Supporting Modules
import numpy as _np

# Import Submodules
from .constants import *
from electricpy.constants import *

# Define Cold-Junction-Voltage Calculator
def coldjunction(Tcj, coupletype="K", To=None, Vo=None, P1=None, P2=None,
Expand Down
3 changes: 2 additions & 1 deletion electricpy/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@
This file is to keep track of Name, Current Version of electricpy for CI and CD
"""
################################################################################

NAME = "electricpy"
VERSION = "0.3.0"
VERSION = "0.3.0"
Loading

0 comments on commit 3a01a4e

Please sign in to comment.