Skip to main content

⚡sting⚡

Welcome! This repository contains STING—Specialized Tool for INverter-based Grids. STING is an open-source software that is able to run:

  • AC Power Flow
  • Stochastic capacity expansion
  • Kron reduction
  • Model order reduction
  • Small-signal modeling
  • Electromagnetic transient simulation

Minimum requirements to run STING

Please install Python 3.14

We are actively working to support STING in the latest version of Python.

Please install all relevant solvers for your use case before running STING.

Most of modules additionally require solvers that solve optimization models. For example, solving optimal power flow is needed to find an equilibrium point for small-signal modeling. We currently support and use the following libraries:

Solver How to install Use
IPOPT brew install ipopt ACOPF, Small signal modeling, EMT simulation
Gurobi pip install gurobipy Capacity expansion
MOSEK pip install mosek Capacity expansion

Install STING

STING is available on PyPI (https://pypi.org/project/sting-py/)!

To install follow the steps:

  1. Create a folder where you plan to have your case studies:
mkdir sting_env
  1. Go to the folder:
cd sting_env
  1. Create a python environment:
python3.14 -m venv .venv
  1. Activate the python environment:
source .venv/bin/activate
  1. Install STING in your python environment:
pip install sting-py
  1. Execute an example. This example is the construction of the state-space matrices of the small-signal model of a 9 bus system.
sting-example 9_bus_ssm

You can also see the prior steps executed in the following video clip. Refresh your browser to repeat the clip.

Project demo

Alternatively, you can also install STING in Editable Mode directly from this repository. We recommend this installation if you want to get the latest version, develop new models, and explore the framework of the modules.

Install STING in Editable Mode

  1. Download STING: Make sure you have python3.14 installed on your computer. Using pyenv can be helpful for managing multiple versions of python on your PC. Start by cloning this repository and navigating into the STING directory.

    git clone https://github.com/REAM-lab/sting
    cd sting
    

    Next, create a virtual environment and download all required packages.

    python3.14 -m venv .venv 
    source .venv/bin/activate
    pip install -e .  
    

    To install all optional dependencies, run pip install -e ".[all]". This will install extra packages necessary for optimization, specifically solvers.

  2. Run sting: To ensure that sting was installed correctly navigate to the examples folder. You will see examples for different modules. Find the file run.py and execute it.

Installing STING in Project Configuration

For research projects we recommend creating a separate directory for your project files and scripts—isolating them from the source files of STING. To install and configure STING in this manner perform the following steps.

  1. Download STING: If you haven't already, install [python3.14] and clone STING
    git clone https://github.com/REAM-lab/sting
    
  2. Project Installation: In the same parent directory of STING, create a new directory for your project—for instance my_project. Then install all packages from STING in a virtual environment
    mkdir my_project
    cd my_project
    python3.14 -m venv .venv 
    source .venv/bin/activate
    pip install -e ../sting/.
    
  3. Visual Studio Code (Optional): If you are using Visual Studio Code as a text editor you can add STING as an "extra path". To do so go to Preferences > Settings and search for extra paths. Under Python > Analysis: Extra Paths add the global path of STING on your machine—for instance Users/your_name/python/sting.

Citing

@misc{STING,
    author = {{Renewable Energy + Advanced Mathematics Lab (REAM)}},
    title = {Specialized tool for inverter-based grids},
    year = {2025},
    publisher = {GitHub},
    journal = {GitHub repository},
    url = {https://github.com/REAM-lab/sting}
}

Research Software Notice

All work is distributed under the Apache open-source license. However, this repository also contains software developed as part of active research that has not yet been formally published. As a developer, user, or reader of this software you are agreeing to good faith applications of this work. Original research that has not been previously published may not be represented as the independent work of another author. We kindly ask that you adhere to academic integrity and consult with authors if you are unsure what might constitute original unpublished work.

Metadata

Release files for sting-py 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sting-py 0.2.3
File Size Uploaded
sting_py-0.2.3.tar.gz 215.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sting-py 0.2.3
File Interpreter ABI Platform
sting_py-0.2.3-py3-none-any.whl Python 3 none any Details

Total release size: 562.7 kB

Release files / sting_py-0.2.3.tar.gz

Download URL sting_py-0.2.3.tar.gz
Size 215.4 kB
Tags Source
SHA-256 checksum
How to use checksums
36ded54ea9090251910f66382174a77542e470318c03bb1daa94bfac2672b118
BLAKE2b-256 checksum
How to use checksums
33eda12ef1a25fb32318972458c665ba77858c75b2c8e88a9629802e24c8f085
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.9

Release files / sting_py-0.2.3-py3-none-any.whl

Download URL sting_py-0.2.3-py3-none-any.whl
Size 347.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1f247c8a792623c8f83bd3d96197b7ea944bebedf60a22d34883ffd0ccbabd91
BLAKE2b-256 checksum
How to use checksums
64465105744fa4171b4097f4eed76708be360803664b023ff409bd13260ccec6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.9

Release history Release notifications | RSS feed

This release

0.2.3 This release

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page