sproclib


Namesproclib JSON
Version 2.1.0 PyPI version JSON
download
home_pagehttps://github.com/gressling/sproclib
SummaryStandard Process Control Library for chemical process control - Semantic API for chemical plant design using familiar ML patterns
upload_time2025-07-12 15:10:47
maintainerNone
docs_urlNone
authorThorsten Gressling
requires_python>=3.8
licenseMIT
keywords process control chemical engineering pid simulation optimization semantic api machine learning
VCS
bugtrack_url
requirements numpy scipy matplotlib cvxpy pyomo pandas jupyter python-control pytest pytest-cov sphinx sphinx-rtd-theme sphinx-autodoc-typehints myst-parser docutils pillow
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # SPROCLIB - Standard Process Control Library

A comprehensive Python library for chemical process control, providing essential classes and functions for PID control, process modeling, simulation, optimization, and advanced control techniques.

**SPROCLIB provides a semantic API for chemical plant design that uses familiar patterns from machine learning frameworks like TensorFlow and Keras.**

## Installation

```bash
pip install sproclib
```

## Features

- **Semantic Plant Design**: Intuitive API similar to ML frameworks for building complex chemical processes
- **Process Units**: CSTR, pumps, heat exchangers, distillation columns, reactors, and tanks
- **Economic Optimization**: Built-in optimization algorithms for cost minimization and profit maximization
- **PID Controllers**: Classical and advanced PID control implementations with auto-tuning
- **Analysis Tools**: Transfer functions, simulation, and system identification
- **Advanced Control**: Model predictive control, state-space controllers, and IMC
- **Transport Models**: Continuous and batch transport for liquids and solids

## Quick Start

Create and optimize a chemical plant in just a few lines:

```python
from sproclib.unit.plant import ChemicalPlant
from sproclib.unit.pump import CentrifugalPump
from sproclib.unit.reactor import CSTR

# Define plant
plant = ChemicalPlant(name="Process Plant")

# Add units
plant.add(CentrifugalPump(H0=50.0, eta=0.75), name="feed_pump")
plant.add(CSTR(V=150.0, k0=7.2e10), name="reactor")

# Connect units
plant.connect("feed_pump", "reactor", "feed_stream")

# Configure optimization
plant.compile(
   optimizer="economic",
   loss="total_cost",
   metrics=["profit", "conversion"]
)

# Optimize operations
plant.optimize(target_production=1000.0)
```

## Advanced Example

```python
# Traditional PID control example
import sproclib as spc

# Create a PID controller
controller = spc.PIDController(kp=1.0, ki=0.1, kd=0.05)

# Create a tank model
tank = spc.Tank(volume=100, area=10)

# Simulate step response
response = spc.step_response(tank, time_span=100)
```

## Requirements

- Python 3.8+
- NumPy >= 1.20.0
- SciPy >= 1.7.0
- Matplotlib >= 3.3.0

## License

MIT License

## Author

Thorsten Gressling <gressling@paramus.ai>

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/gressling/sproclib",
    "name": "sproclib",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "process control, chemical engineering, PID, simulation, optimization, semantic API, machine learning",
    "author": "Thorsten Gressling",
    "author_email": "Thorsten Gressling <gressling@paramus.ai>",
    "download_url": "https://files.pythonhosted.org/packages/4b/53/4d815ded191181cb990802d27fd516d3e211a5ebb9535f59d04c83cd6b10/sproclib-2.1.0.tar.gz",
    "platform": null,
    "description": "# SPROCLIB - Standard Process Control Library\r\n\r\nA comprehensive Python library for chemical process control, providing essential classes and functions for PID control, process modeling, simulation, optimization, and advanced control techniques.\r\n\r\n**SPROCLIB provides a semantic API for chemical plant design that uses familiar patterns from machine learning frameworks like TensorFlow and Keras.**\r\n\r\n## Installation\r\n\r\n```bash\r\npip install sproclib\r\n```\r\n\r\n## Features\r\n\r\n- **Semantic Plant Design**: Intuitive API similar to ML frameworks for building complex chemical processes\r\n- **Process Units**: CSTR, pumps, heat exchangers, distillation columns, reactors, and tanks\r\n- **Economic Optimization**: Built-in optimization algorithms for cost minimization and profit maximization\r\n- **PID Controllers**: Classical and advanced PID control implementations with auto-tuning\r\n- **Analysis Tools**: Transfer functions, simulation, and system identification\r\n- **Advanced Control**: Model predictive control, state-space controllers, and IMC\r\n- **Transport Models**: Continuous and batch transport for liquids and solids\r\n\r\n## Quick Start\r\n\r\nCreate and optimize a chemical plant in just a few lines:\r\n\r\n```python\r\nfrom sproclib.unit.plant import ChemicalPlant\r\nfrom sproclib.unit.pump import CentrifugalPump\r\nfrom sproclib.unit.reactor import CSTR\r\n\r\n# Define plant\r\nplant = ChemicalPlant(name=\"Process Plant\")\r\n\r\n# Add units\r\nplant.add(CentrifugalPump(H0=50.0, eta=0.75), name=\"feed_pump\")\r\nplant.add(CSTR(V=150.0, k0=7.2e10), name=\"reactor\")\r\n\r\n# Connect units\r\nplant.connect(\"feed_pump\", \"reactor\", \"feed_stream\")\r\n\r\n# Configure optimization\r\nplant.compile(\r\n   optimizer=\"economic\",\r\n   loss=\"total_cost\",\r\n   metrics=[\"profit\", \"conversion\"]\r\n)\r\n\r\n# Optimize operations\r\nplant.optimize(target_production=1000.0)\r\n```\r\n\r\n## Advanced Example\r\n\r\n```python\r\n# Traditional PID control example\r\nimport sproclib as spc\r\n\r\n# Create a PID controller\r\ncontroller = spc.PIDController(kp=1.0, ki=0.1, kd=0.05)\r\n\r\n# Create a tank model\r\ntank = spc.Tank(volume=100, area=10)\r\n\r\n# Simulate step response\r\nresponse = spc.step_response(tank, time_span=100)\r\n```\r\n\r\n## Requirements\r\n\r\n- Python 3.8+\r\n- NumPy >= 1.20.0\r\n- SciPy >= 1.7.0\r\n- Matplotlib >= 3.3.0\r\n\r\n## License\r\n\r\nMIT License\r\n\r\n## Author\r\n\r\nThorsten Gressling <gressling@paramus.ai>\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Standard Process Control Library for chemical process control - Semantic API for chemical plant design using familiar ML patterns",
    "version": "2.1.0",
    "project_urls": {
        "Documentation": "https://sproclib.readthedocs.io/en/latest/",
        "Homepage": "https://github.com/gressling/sproclib",
        "Issues": "https://github.com/gressling/sproclib/issues",
        "Repository": "https://github.com/gressling/sproclib"
    },
    "split_keywords": [
        "process control",
        " chemical engineering",
        " pid",
        " simulation",
        " optimization",
        " semantic api",
        " machine learning"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "029683d92349f04b0562d22bde13de4d6d5d9fe4dc1041da14c8420103cb207d",
                "md5": "19ceb768804bfc63227577f907f77071",
                "sha256": "d18b9b64702766543a9229243456add3373cb45fb61bb3da39f456ee5507df84"
            },
            "downloads": -1,
            "filename": "sproclib-2.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "19ceb768804bfc63227577f907f77071",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 478374,
            "upload_time": "2025-07-12T15:10:30",
            "upload_time_iso_8601": "2025-07-12T15:10:30.276073Z",
            "url": "https://files.pythonhosted.org/packages/02/96/83d92349f04b0562d22bde13de4d6d5d9fe4dc1041da14c8420103cb207d/sproclib-2.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "4b534d815ded191181cb990802d27fd516d3e211a5ebb9535f59d04c83cd6b10",
                "md5": "20e1a72efae6f2eeff62a0a734989ea4",
                "sha256": "87228091dc5db2e1fe28d7bcb5bb4dd0fd06f34886d0fa5b211851f5d85b6c40"
            },
            "downloads": -1,
            "filename": "sproclib-2.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "20e1a72efae6f2eeff62a0a734989ea4",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 13987396,
            "upload_time": "2025-07-12T15:10:47",
            "upload_time_iso_8601": "2025-07-12T15:10:47.096596Z",
            "url": "https://files.pythonhosted.org/packages/4b/53/4d815ded191181cb990802d27fd516d3e211a5ebb9535f59d04c83cd6b10/sproclib-2.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-12 15:10:47",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "gressling",
    "github_project": "sproclib",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "numpy",
            "specs": [
                [
                    ">=",
                    "1.20.0"
                ]
            ]
        },
        {
            "name": "scipy",
            "specs": [
                [
                    ">=",
                    "1.7.0"
                ]
            ]
        },
        {
            "name": "matplotlib",
            "specs": [
                [
                    ">=",
                    "3.4.0"
                ]
            ]
        },
        {
            "name": "cvxpy",
            "specs": [
                [
                    ">=",
                    "1.2.0"
                ]
            ]
        },
        {
            "name": "pyomo",
            "specs": [
                [
                    ">=",
                    "6.0.0"
                ]
            ]
        },
        {
            "name": "pandas",
            "specs": [
                [
                    ">=",
                    "1.3.0"
                ]
            ]
        },
        {
            "name": "jupyter",
            "specs": [
                [
                    ">=",
                    "1.0.0"
                ]
            ]
        },
        {
            "name": "python-control",
            "specs": [
                [
                    ">=",
                    "0.9.0"
                ]
            ]
        },
        {
            "name": "pytest",
            "specs": [
                [
                    ">=",
                    "6.0.0"
                ]
            ]
        },
        {
            "name": "pytest-cov",
            "specs": [
                [
                    ">=",
                    "2.12.0"
                ]
            ]
        },
        {
            "name": "sphinx",
            "specs": [
                [
                    ">=",
                    "8.0.0"
                ]
            ]
        },
        {
            "name": "sphinx-rtd-theme",
            "specs": [
                [
                    ">=",
                    "3.0.0"
                ]
            ]
        },
        {
            "name": "sphinx-autodoc-typehints",
            "specs": [
                [
                    ">=",
                    "3.0.0"
                ]
            ]
        },
        {
            "name": "myst-parser",
            "specs": [
                [
                    ">=",
                    "4.0.0"
                ]
            ]
        },
        {
            "name": "docutils",
            "specs": [
                [
                    ">=",
                    "0.21.0"
                ]
            ]
        },
        {
            "name": "pillow",
            "specs": [
                [
                    ">=",
                    "9.0.0"
                ]
            ]
        }
    ],
    "lcname": "sproclib"
}
        
Elapsed time: 0.45831s