Pywaterflood
Pywaterflood: Well connectivity analysis through capacitance-resistance modeling - Published in JOSS (2024)
Science Score: 100.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 3 DOI reference(s) in README and JOSS metadata -
✓Academic publication links
Links to: joss.theoj.org, zenodo.org -
✓Committers with academic emails
1 of 3 committers (33.3%) from academic institutions -
○Institutional organization owner
-
✓JOSS paper metadata
Published in Journal of Open Source Software
Keywords
Keywords from Contributors
Scientific Fields
Repository
Capacitance resistance models for waterflood connectivity
Basic Info
Statistics
- Stars: 54
- Watchers: 5
- Forks: 22
- Open Issues: 7
- Releases: 9
Topics
Metadata Files
README.md
pywaterflood: Waterflood Connectivity Analysis
pywaterflood provides tools for capacitance resistance modeling, a
physics-inspired model for estimating well connectivity between injectors and
producers or producers and other producers. It is useful for analyzing and
optimizing waterfloods, CO2 floods, and geothermal projects.
Overview
A literature review has been written by Holanda, Gildin, Jensen, Lake and Kabir, entitled "A State-of-the-Art Literature Review on Capacitance Resistance Models for Reservoir Characterization and Performance Forecasting." They describe CRM as the following:
The Capacitance Resistance Model (CRM) is a fast way for modeling and simulating gas and waterflooding recovery processes, making it a useful tool for improving flood management in real-time. CRM is an input-output and material balance-based model, and requires only injection and production history, which are the most readily available data gathered throughout the production life of a reservoir.
There are several CRM versions (see Holanda et al., 2018). Through passing different parameters when creating the CRM instance, you can choose between CRMIP, where a unique time constant is used for each injector-producer pair, and CRMP, where a unique time constant is used for each producer. CRMIP is more reliable given sufficient data. With CRMP, you can reduce the number of unknowns, which is useful if available production data is limited.
Getting started
You can install this package from PyPI with the line
pip install pywaterflood
Or from conda/mamba with
conda install -c conda-forge pywaterflood
Then, read the docs to learn more. If you want to try it out online before installing it on your computer, you can run this google colab notebook.
A simple example
import numpy as np
import pandas as pd
from pywaterflood import CRM
gh_url = "https://raw.githubusercontent.com/frank1010111/pywaterflood/master/testing/data/"
prod = pd.read_csv(gh_url + 'production.csv', header=None).values
inj = pd.read_csv(gh_url + "injection.csv", header=None).values
time = pd.read_csv(gh_url + "time.csv", header=None).values[:,0]
crm = CRM(tau_selection='per-pair', constraints='up-to one')
crm.fit(prod, inj, time)
q_hat = crm.predict()
residuals = crm.residual()
print("MAE by well:", np.round(np.abs(residuals).mean(axis=0), 2), "barrels")
print("MAPE by well:", np.round(np.mean(np.abs(residuals) / prod * 100, axis=0), 2), "percent")
print("RMSE by well:", np.round(np.sqrt(np.sum(residuals**2, axis=0)), 2))
Contributing
Contributions are extremely welcome! Have an issue to report? Want to offer new features or documentation? Check out the contribution guide to help you set up. Discussions could start anytime at the discussions section.
pywaterflood uses Rust for computation and python as the high level interface.
Luckily, maturin is a very convenient tool for working
with mixed Python-Rust projects.
Running tests, building the package, linting to conform to code standards, and building the documentation are all handled by nox.
Running tests
The guide for getting started, has instructions for installing rust, python, and nox. At that point, both the lint and unit test sessions are run with the command
nox
License
This software library is released under a BSD 2-Clause License.
Acknowledgments
Capacitance resistance modeling would not have caught on without the persistence of two professors: Larry Lake and Jerry Jensen. Both of these gentlemen generously helped answer questions in the development of this library. Research funding for this project came from the Department of Energy grant "Optimizing Sweep based on Geochemical and Reservoir Characterization of the Residual Oil Zone of Hess Seminole Unit" (PI: Ian Duncan) and the State of Texas Advanced Resource Recovery program (PI: William Ambrose). Further development is supported by Penn State faculty promotion funds and volunteer time.
Owner
- Name: Frank Male
- Login: frank1010111
- Kind: user
- Location: State College, PA
- Company: Penn State University
- Repositories: 20
- Profile: https://github.com/frank1010111
Full stack scientific programmer - from raw data to decisions
JOSS Publication
Pywaterflood: Well connectivity analysis through capacitance-resistance modeling
Tags
well connectivity analysis waterfloods CO2 floods Geothermal energy multiphase flowCitation (CITATION.cff)
cff-version: "1.2.0"
authors:
- family-names: Male
given-names: Frank
orcid: "https://orcid.org/0000-0002-3402-5578"
contact:
- family-names: Male
given-names: Frank
orcid: "https://orcid.org/0000-0002-3402-5578"
doi: 10.5281/zenodo.10815882
message: If you use this software, please cite our article in the
Journal of Open Source Software.
preferred-citation:
authors:
- family-names: Male
given-names: Frank
orcid: "https://orcid.org/0000-0002-3402-5578"
date-published: 2024-03-20
doi: 10.21105/joss.06191
issn: 2475-9066
issue: 95
journal: Journal of Open Source Software
publisher:
name: Open Journals
start: 6191
title: "Pywaterflood: Well connectivity analysis through
capacitance-resistance modeling"
type: article
url: "https://joss.theoj.org/papers/10.21105/joss.06191"
volume: 9
title: "Pywaterflood: Well connectivity analysis through
capacitance-resistance modeling"
GitHub Events
Total
- Create event: 26
- Commit comment event: 1
- Release event: 1
- Watch event: 10
- Delete event: 25
- Issue comment event: 8
- Push event: 35
- Pull request review event: 23
- Pull request event: 46
- Fork event: 4
Last Year
- Create event: 26
- Commit comment event: 1
- Release event: 1
- Watch event: 10
- Delete event: 25
- Issue comment event: 8
- Push event: 35
- Pull request review event: 23
- Pull request event: 46
- Fork event: 4
Committers
Last synced: 5 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Frank Male | f****e@u****u | 421 |
| dependabot[bot] | 4****] | 72 |
| pre-commit-ci[bot] | 6****] | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 4 months ago
All Time
- Total issues: 20
- Total pull requests: 124
- Average time to close issues: 3 months
- Average time to close pull requests: 5 days
- Total issue authors: 4
- Total pull request authors: 3
- Average comments per issue: 0.75
- Average comments per pull request: 0.76
- Merged pull requests: 104
- Bot issues: 0
- Bot pull requests: 96
Past Year
- Issues: 0
- Pull requests: 49
- Average time to close issues: N/A
- Average time to close pull requests: 3 days
- Issue authors: 0
- Pull request authors: 2
- Average comments per issue: 0
- Average comments per pull request: 0.29
- Merged pull requests: 38
- Bot issues: 0
- Bot pull requests: 44
Top Authors
Issue Authors
- frank1010111 (16)
- castroavila (1)
- Cythina12 (1)
- dependabot[bot] (1)
- amandersillinois (1)
Pull Request Authors
- dependabot[bot] (113)
- frank1010111 (33)
- pre-commit-ci[bot] (3)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- pypi 280 last-month
- Total dependent packages: 0
- Total dependent repositories: 1
- Total versions: 9
- Total maintainers: 1
pypi.org: pywaterflood
Physics-inspired waterflood performance modeling
- Documentation: https://pywaterflood.readthedocs.io/
- License: BSD License
-
Latest release: 0.3.4
published about 1 year ago
Rankings
Maintainers (1)
Dependencies
- black >=22 develop
- coverage >=6.3.3 develop
- flake8 >=4.0.1 develop
- flake8-bugbear >=21.11.29 develop
- flake8-builtins >=1.5.3 develop
- flake8-comprehensions >=3.7.0 develop
- flake8-string-format >=0.3.0 develop
- mypy >=0.920 develop
- pre-commit >=2.0 develop
- pydocstyle >=6.1.1 develop
- pytest >=6.2.5 develop
- pytest-cov >=3.0.0 develop
- tox >=3.24.4 develop
- tox-gh-actions >=2.9.1 develop
- joblib >=1.1.0
- jupyterlab >=3.2
- myst-nb >=0.13.1
- numba >=0.55.1
- numpy >=1.21
- openpyxl >=3.0.9
- pandas >=1.3.5
- python >=3.7.1,<3.11
- scipy >=1.4
- seaborn >=0.10
- sphinx >=4.2.0
- sphinx-autoapi >=1.8.4
- sphinx-rtd-theme >=1.0
- actions/checkout v3 composite
- actions/download-artifact v3 composite
- actions/upload-artifact v3 composite
- pypa/gh-action-pypi-publish v1.6.4 composite
- abatilo/actions-poetry v2.2.0 composite
- actions/checkout v2.3.4 composite
- actions/setup-python v2.2.2 composite
- codecov/codecov-action v3 composite
- python 3.9-slim build
- actions/checkout v3 composite
- actions/upload-artifact v1 composite
- openjournals/openjournals-draft-action v.1.0 composite
- autocfg 1.1.0
- bitflags 1.3.2
- cfg-if 1.0.0
- indoc 1.0.6
- libc 0.2.126
- lock_api 0.4.7
- matrixmultiply 0.3.2
- ndarray 0.15.6
- num-complex 0.4.2
- num-integer 0.1.45
- num-traits 0.2.15
- numpy 0.16.2
- once_cell 1.13.0
- parking_lot 0.12.1
- parking_lot_core 0.9.3
- proc-macro2 1.0.40
- pyo3 0.16.6
- pyo3-build-config 0.16.6
- pyo3-ffi 0.16.6
- pyo3-macros 0.16.6
- pyo3-macros-backend 0.16.6
- quote 1.0.20
- rawpointer 0.2.1
- redox_syscall 0.2.13
- scopeguard 1.1.0
- smallvec 1.9.0
- syn 1.0.98
- target-lexicon 0.12.4
- unicode-ident 1.0.1
- unindent 0.1.9
- windows-sys 0.36.1
- windows_aarch64_msvc 0.36.1
- windows_i686_gnu 0.36.1
- windows_i686_msvc 0.36.1
- windows_x86_64_gnu 0.36.1
- windows_x86_64_msvc 0.36.1
