QSDsan: Quantitative Sustainable Design for Sanitation and Resource Recovery Systems

Attention

Package Restructuring In Progress — We are currently reorganizing QSDsan to enhance the user experience and expand functionality. Some APIs and module layouts may change as we work through these updates. We appreciate your patience and will keep this notice up to date. Thank you for being part of the community!

What is QSDsan?

QSDsan is an open-source, community-led platform for the quantitative sustainable design (QSD) [1] of sanitation and resource recovery systems [2]. Built in Python, it integrates process modeling, system simulation, techno-economic analysis (TEA), and life cycle assessment (LCA) to support transparent, reproducible, and comprehensive evaluation of emerging technologies. Leveraging BioSTEAM [3], the platform provides modular and extensible tools to compare treatment configurations, evaluate resource recovery opportunities, and assess energy, cost, and sustainability tradeoffs. The platform has a range of built-in unit operations and systems, including commonly used treatment processes and biokinetic models. These capabilities support the research, development, and deployment (RD&D) of early-stage technologies for advancing sustainable water management and circular resource recovery.

Tutorials
_images/tutorials_icon.svg
Tutorials
API
_images/api_icon.svg
API
Systems
_images/systems_icon.svg
Systems
FAQ
_images/faq_icon.svg
FAQ

Installation

QSDsan requires Python 3.12 or newer. The easiest way to install QSDsan is through pip in a command-line interface (e.g., Anaconda Prompt, terminal):

pip install qsdsan

To upgrade an existing installation:

pip install -U qsdsan

To install a specific version, replace X.X.X with the version number:

pip install qsdsan==X.X.X

To install the latest GitHub version from the main branch:

pip install git+https://github.com/QSD-Group/QSDsan.git

To install from another fork and/or branch, replace <USERNAME_OF_THE_FORK> and <BRANCH_NAME>:

pip install git+https://github.com/<USERNAME_OF_THE_FORK>/QSDsan.git@<BRANCH_NAME>

You can also download the package from PyPI.

For diagram generation, QSDsan uses Graphviz. If diagrams fail to render, install Graphviz following the official Graphviz download instructions and see Graphviz Installation for a quick check.

Join the Community

We would like to build an open and welcoming community, you can always post issues on our GitHub homepage or contact any of the Quantitative Sustainable Design Group members. We are always excited to have new members in our team.

If you would like to contribute, please follow our Contributing Guidelines and the Contributor Covenant, thank you for making QSDsan better!

QSDsan is and will stay open source under University of Illinois/NCSA Open Source License. Any third-party packages copied from QSDsan must be strictly open-source (not copy-left nor open-access). Please refer to the license page for details.

References