matrix-utils 0.5__tar.gz → 0.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- matrix_utils-0.6/.gitignore +104 -0
- matrix_utils-0.6/.pre-commit-config.yaml +53 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/CHANGELOG.md +5 -1
- {matrix_utils-0.5 → matrix_utils-0.6}/PKG-INFO +1 -1
- matrix_utils-0.6/binder/Brightway 2.5 demonstration.ipynb +615 -0
- matrix_utils-0.6/binder/environment.yml +33 -0
- matrix_utils-0.6/dev/Brightway 2.5 - Linking with IAMs.ipynb +741 -0
- matrix_utils-0.6/dev/Brightway 2.5 demonstration.ipynb +648 -0
- matrix_utils-0.6/dev/Graph traversal with modification.ipynb +893 -0
- matrix_utils-0.6/dev/Indexing speed tests.ipynb +235 -0
- matrix_utils-0.6/dev/Interfaces which produce results for multiple matrices.ipynb +506 -0
- matrix_utils-0.6/dev/Mapping speed tests.ipynb +420 -0
- matrix_utils-0.6/dev/Multifunctionality with Brightway 2.5.ipynb +555 -0
- matrix_utils-0.6/dev/Real-time modification of hybrid databases.ipynb +543 -0
- matrix_utils-0.6/dev/Supply chain modification.ipynb +562 -0
- matrix_utils-0.6/dev/Untitled.ipynb +32 -0
- matrix_utils-0.6/dev/profiling/bw2.prof +0 -0
- matrix_utils-0.6/dev/profiling/bw2.svg +9638 -0
- matrix_utils-0.6/dev/profiling/bw25.prof +0 -0
- matrix_utils-0.6/dev/profiling/bw25.svg +9948 -0
- matrix_utils-0.6/dev/profiling/bw25_profile.txt +6310 -0
- matrix_utils-0.6/dev/profiling/bw25_profiling.py +12 -0
- matrix_utils-0.6/dev/profiling/bw2_profile.txt +5014 -0
- matrix_utils-0.6/dev/profiling/bw2_profiling.py +10 -0
- matrix_utils-0.6/dev/profiling/profiling-versus-bw2.py +55 -0
- matrix_utils-0.6/dev/speed_test_unique_indices.py +7 -0
- matrix_utils-0.6/dev/speed_tests.py +113 -0
- matrix_utils-0.6/docs/Makefile +20 -0
- matrix_utils-0.6/docs/conf.py +57 -0
- matrix_utils-0.6/docs/index.rst +19 -0
- matrix_utils-0.6/docs/loading.rst +4 -0
- matrix_utils-0.6/docs/make.bat +35 -0
- matrix_utils-0.6/docs/saving.rst +11 -0
- matrix_utils-0.6/docs/utilities.rst +35 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/__init__.py +1 -1
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/array_mapper.py +27 -14
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/mapped_matrix.py +3 -3
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils.egg-info/PKG-INFO +1 -1
- matrix_utils-0.6/matrix_utils.egg-info/SOURCES.txt +68 -0
- matrix_utils-0.6/tests/array_mapper.py +80 -0
- matrix_utils-0.6/tests/fixtures/__init__.py +1 -0
- matrix_utils-0.6/tests/fixtures/a-first.zip +0 -0
- matrix_utils-0.6/tests/fixtures/b-second.zip +0 -0
- matrix_utils-0.6/tests/fixtures/basic.py +77 -0
- matrix_utils-0.6/tests/fixtures/create_static_fixtures.py +192 -0
- matrix_utils-0.6/tests/fixtures/sa-1.zip +0 -0
- matrix_utils-0.6/tests/fixtures/sa-2.zip +0 -0
- matrix_utils-0.6/tests/indexers.py +127 -0
- matrix_utils-0.6/tests/integration.py +190 -0
- matrix_utils-0.6/tests/interfaces.py +16 -0
- matrix_utils-0.6/tests/mapped_matrix.py +836 -0
- matrix_utils-0.6/tests/masking.py +271 -0
- matrix_utils-0.6/tests/monte_carlo.py +243 -0
- matrix_utils-0.6/tests/ordering.py +31 -0
- matrix_utils-0.6/tests/utils.py +105 -0
- matrix_utils-0.5/matrix_utils.egg-info/SOURCES.txt +0 -20
- {matrix_utils-0.5 → matrix_utils-0.6}/CODE_OF_CONDUCT.md +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/LICENSE +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/MANIFEST.in +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/README.md +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/aggregation.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/errors.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/indexers.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/mapped_matrix_dict.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/resource_group.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils/utils.py +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils.egg-info/dependency_links.txt +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils.egg-info/requires.txt +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/matrix_utils.egg-info/top_level.txt +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/pyproject.toml +0 -0
- {matrix_utils-0.5 → matrix_utils-0.6}/setup.cfg +0 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
*.egg-info/
|
|
24
|
+
.installed.cfg
|
|
25
|
+
*.egg
|
|
26
|
+
MANIFEST
|
|
27
|
+
|
|
28
|
+
# PyInstaller
|
|
29
|
+
# Usually these files are written by a python script from a template
|
|
30
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
31
|
+
*.manifest
|
|
32
|
+
*.spec
|
|
33
|
+
|
|
34
|
+
# Installer logs
|
|
35
|
+
pip-log.txt
|
|
36
|
+
pip-delete-this-directory.txt
|
|
37
|
+
|
|
38
|
+
# Unit test / coverage reports
|
|
39
|
+
htmlcov/
|
|
40
|
+
.tox/
|
|
41
|
+
.coverage
|
|
42
|
+
.coverage.*
|
|
43
|
+
.cache
|
|
44
|
+
nosetests.xml
|
|
45
|
+
coverage.xml
|
|
46
|
+
*.cover
|
|
47
|
+
.hypothesis/
|
|
48
|
+
.pytest_cache/
|
|
49
|
+
|
|
50
|
+
# Translations
|
|
51
|
+
*.mo
|
|
52
|
+
*.pot
|
|
53
|
+
|
|
54
|
+
# Django stuff:
|
|
55
|
+
*.log
|
|
56
|
+
local_settings.py
|
|
57
|
+
db.sqlite3
|
|
58
|
+
|
|
59
|
+
# Flask stuff:
|
|
60
|
+
instance/
|
|
61
|
+
.webassets-cache
|
|
62
|
+
|
|
63
|
+
# Scrapy stuff:
|
|
64
|
+
.scrapy
|
|
65
|
+
|
|
66
|
+
# Sphinx documentation
|
|
67
|
+
docs/_build/
|
|
68
|
+
|
|
69
|
+
# PyBuilder
|
|
70
|
+
target/
|
|
71
|
+
|
|
72
|
+
# Jupyter Notebook
|
|
73
|
+
.ipynb_checkpoints
|
|
74
|
+
|
|
75
|
+
# pyenv
|
|
76
|
+
.python-version
|
|
77
|
+
|
|
78
|
+
# celery beat schedule file
|
|
79
|
+
celerybeat-schedule
|
|
80
|
+
|
|
81
|
+
# SageMath parsed files
|
|
82
|
+
*.sage.py
|
|
83
|
+
|
|
84
|
+
# Environments
|
|
85
|
+
.env
|
|
86
|
+
.venv
|
|
87
|
+
env/
|
|
88
|
+
venv/
|
|
89
|
+
ENV/
|
|
90
|
+
env.bak/
|
|
91
|
+
venv.bak/
|
|
92
|
+
|
|
93
|
+
# Spyder project settings
|
|
94
|
+
.spyderproject
|
|
95
|
+
.spyproject
|
|
96
|
+
|
|
97
|
+
# Rope project settings
|
|
98
|
+
.ropeproject
|
|
99
|
+
|
|
100
|
+
# mkdocs documentation
|
|
101
|
+
/site
|
|
102
|
+
|
|
103
|
+
# mypy
|
|
104
|
+
.mypy_cache/
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
exclude: '^docs/conf.py'
|
|
2
|
+
|
|
3
|
+
repos:
|
|
4
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
5
|
+
rev: v4.4.0
|
|
6
|
+
hooks:
|
|
7
|
+
- id: trailing-whitespace
|
|
8
|
+
- id: check-added-large-files
|
|
9
|
+
- id: check-ast
|
|
10
|
+
- id: check-json
|
|
11
|
+
- id: check-merge-conflict
|
|
12
|
+
- id: check-xml
|
|
13
|
+
- id: check-yaml
|
|
14
|
+
- id: debug-statements
|
|
15
|
+
- id: end-of-file-fixer
|
|
16
|
+
- id: requirements-txt-fixer
|
|
17
|
+
- id: mixed-line-ending
|
|
18
|
+
args: ['--fix=auto'] # replace 'auto' with 'lf' to enforce Linux/Mac line endings or 'crlf' for Windows
|
|
19
|
+
|
|
20
|
+
## If you want to avoid flake8 errors due to unused vars or imports:
|
|
21
|
+
# - repo: https://github.com/myint/autoflake
|
|
22
|
+
# rev: v1.4
|
|
23
|
+
# hooks:
|
|
24
|
+
# - id: autoflake
|
|
25
|
+
# args: [
|
|
26
|
+
# --in-place,
|
|
27
|
+
# --remove-all-unused-imports,
|
|
28
|
+
# --remove-unused-variables,
|
|
29
|
+
# ]
|
|
30
|
+
|
|
31
|
+
- repo: https://github.com/pycqa/isort
|
|
32
|
+
rev: 5.11.5
|
|
33
|
+
hooks:
|
|
34
|
+
- id: isort
|
|
35
|
+
args: [--settings-path=pyproject.toml]
|
|
36
|
+
|
|
37
|
+
- repo: https://github.com/psf/black
|
|
38
|
+
rev: 23.10.0
|
|
39
|
+
hooks:
|
|
40
|
+
- id: black
|
|
41
|
+
args: [--config=pyproject.toml]
|
|
42
|
+
|
|
43
|
+
# - repo: https://github.com/adamchainz/blacken-docs
|
|
44
|
+
# rev: 1.16.0
|
|
45
|
+
# hooks:
|
|
46
|
+
# - id: blacken-docs
|
|
47
|
+
# additional_dependencies: [black]
|
|
48
|
+
|
|
49
|
+
- repo: https://github.com/PyCQA/flake8
|
|
50
|
+
rev: 6.0.0
|
|
51
|
+
hooks:
|
|
52
|
+
- id: flake8
|
|
53
|
+
additional_dependencies: [Flake8-pyproject]
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
### [0.6] - 2024-11-01
|
|
4
|
+
|
|
5
|
+
* New array mapping implementation using sparse matrices which is ~100x faster and allows for very large input values
|
|
6
|
+
|
|
3
7
|
### [0.5] - 2024-08-20
|
|
4
8
|
|
|
5
|
-
* Default is
|
|
9
|
+
* Default is now 64 bit integers for indexing; compatible with `bw_processing` 1.0
|
|
6
10
|
|
|
7
11
|
### [0.4.3] - 2024-06-04
|
|
8
12
|
|