egglog 7.1.0__tar.gz → 8.0.0__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.
Potentially problematic release.
This version of egglog might be problematic. Click here for more details.
- {egglog-7.1.0 → egglog-8.0.0}/.github/dependabot.yml +15 -0
- {egglog-7.1.0 → egglog-8.0.0}/.github/workflows/version.yml +5 -2
- {egglog-7.1.0 → egglog-8.0.0}/.gitignore +2 -0
- {egglog-7.1.0 → egglog-8.0.0}/Cargo.lock +93 -19
- egglog-8.0.0/Cargo.toml +42 -0
- egglog-8.0.0/Makefile +24 -0
- {egglog-7.1.0 → egglog-8.0.0}/PKG-INFO +33 -32
- {egglog-7.1.0 → egglog-8.0.0}/docs/changelog.md +15 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/conf.py +8 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/index.md +2 -11
- egglog-8.0.0/docs/reference/contributing.md +94 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference/python-integration.md +138 -0
- {egglog-7.1.0 → egglog-8.0.0}/pyproject.toml +10 -5
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/bindings.pyi +63 -23
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/builtins.py +49 -6
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/conversion.py +31 -8
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/declarations.py +146 -8
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/egraph.py +337 -203
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/egraph_state.py +171 -64
- egglog-8.0.0/python/egglog/examples/higher_order_functions.py +45 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/array_api.py +278 -93
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/array_api_jit.py +1 -4
- egglog-8.0.0/python/egglog/exp/array_api_loopnest.py +145 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/array_api_numba.py +1 -1
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/array_api_program_gen.py +51 -12
- egglog-8.0.0/python/egglog/functionalize.py +91 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/pretty.py +97 -43
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/runtime.py +60 -44
- egglog-8.0.0/python/egglog/thunk.py +95 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/type_constraint_solver.py +5 -4
- egglog-8.0.0/python/egglog/visualizer.css +1 -0
- egglog-8.0.0/python/egglog/visualizer.js +35753 -0
- egglog-8.0.0/python/egglog/visualizer_widget.py +39 -0
- egglog-8.0.0/python/tests/__snapshots__/test_array_api/TestLDA.test_optimize.py +75 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/__snapshots__/test_array_api/TestLDA.test_source_optimized.py +9 -9
- egglog-8.0.0/python/tests/__snapshots__/test_array_api/TestLDA.test_trace.py +77 -0
- egglog-8.0.0/python/tests/__snapshots__/test_bindings/TestEGraph.test_parse_program.py +122 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/conftest.py +2 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_array_api.py +4 -4
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_bindings.py +100 -59
- egglog-8.0.0/python/tests/test_functionalize.py +61 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_high_level.py +124 -10
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_py_object_sort.py +12 -9
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_runtime.py +2 -2
- egglog-8.0.0/python/tests/test_unstable_fn.py +368 -0
- {egglog-7.1.0 → egglog-8.0.0}/src/conversions.rs +82 -58
- {egglog-7.1.0 → egglog-8.0.0}/src/egraph.rs +17 -17
- {egglog-7.1.0 → egglog-8.0.0}/src/error.rs +6 -3
- {egglog-7.1.0 → egglog-8.0.0}/src/lib.rs +4 -2
- {egglog-7.1.0 → egglog-8.0.0}/src/py_object_sort.rs +27 -21
- {egglog-7.1.0 → egglog-8.0.0}/src/serialize.rs +10 -1
- egglog-7.1.0/Cargo.toml +0 -33
- egglog-7.1.0/docs/reference/contributing.md +0 -15
- egglog-7.1.0/python/egglog/graphviz_widget.py +0 -34
- egglog-7.1.0/python/egglog/thunk.py +0 -71
- egglog-7.1.0/python/egglog/widget.css +0 -6
- egglog-7.1.0/python/egglog/widget.js +0 -50
- egglog-7.1.0/python/tests/__snapshots__/test_array_api/TestLDA.test_optimize.py +0 -68
- egglog-7.1.0/python/tests/__snapshots__/test_array_api/TestLDA.test_trace.py +0 -75
- egglog-7.1.0/python/tests/test_unstable_fn.py +0 -184
- {egglog-7.1.0 → egglog-8.0.0}/.github/workflows/CI.yml +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/.pre-commit-config.yaml +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/.readthedocs.yaml +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/CITATION.cff +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/LICENSE +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/README.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/conftest.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/.gitignore +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/_templates/comments.html +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/environment.yml +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/.gitignore +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_07_presentation.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_11_09_portland_state.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_11_17_pytensor.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_11_pydata_lightning_talk.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_12_02_congruence_closure-1.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_12_02_congruence_closure-2.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2023_12_02_congruence_closure.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2024_03_17_community_talk.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/2024_03_17_map.svg +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/big_graph.svg +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/define_and_define.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/ecosystem-graph.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/egg.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/indexing_pushdown.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/moa.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/optional_values.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation/pldi_2023_presentation.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/explanation.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/how-to-guides.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference/bindings.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference/egglog-translation.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference/high-level.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference/usage.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/reference.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/tutorials/getting-started.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/tutorials/screenshot-1.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/tutorials/screenshot-2.png +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/tutorials/sklearn.ipynb +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/docs/tutorials.md +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/increment_version.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/__init__.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/config.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/README.rst +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/__init__.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/bool.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/eqsat_basic.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/fib.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/lambda_.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/matrix.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/ndarrays.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/resolution.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/examples/schedule_demo.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/__init__.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/program_gen.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/exp/siu_examples.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/ipython_magic.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/egglog/py.typed +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/__init__.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/__snapshots__/test_program_gen/test_to_string.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_convert.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_modules.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_pretty.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_program_gen.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_type_constraint_solver.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/python/tests/test_typing.py +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/rust-toolchain.toml +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/src/utils.rs +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/stubtest_allow +0 -0
- {egglog-7.1.0 → egglog-8.0.0}/test-data/unit/check-high-level.test +0 -0
|
@@ -9,11 +9,26 @@ updates:
|
|
|
9
9
|
directory: "/"
|
|
10
10
|
schedule:
|
|
11
11
|
interval: "weekly"
|
|
12
|
+
groups:
|
|
13
|
+
rust-production:
|
|
14
|
+
dependency-type: "production"
|
|
15
|
+
rust-development:
|
|
16
|
+
dependency-type: "development"
|
|
12
17
|
- package-ecosystem: "github-actions"
|
|
13
18
|
directory: "/"
|
|
14
19
|
schedule:
|
|
15
20
|
interval: "weekly"
|
|
21
|
+
groups:
|
|
22
|
+
actions-production:
|
|
23
|
+
dependency-type: "production"
|
|
24
|
+
actions-development:
|
|
25
|
+
dependency-type: "development"
|
|
16
26
|
- package-ecosystem: "pip"
|
|
17
27
|
directory: "/"
|
|
18
28
|
schedule:
|
|
19
29
|
interval: "weekly"
|
|
30
|
+
groups:
|
|
31
|
+
python-production:
|
|
32
|
+
dependency-type: "production"
|
|
33
|
+
python-development:
|
|
34
|
+
dependency-type: "development"
|
|
@@ -53,6 +53,8 @@ jobs:
|
|
|
53
53
|
- uses: actions/checkout@v4
|
|
54
54
|
with:
|
|
55
55
|
ref: version-${{ needs.bump.outputs.version }}
|
|
56
|
+
- name: Setup QEMU
|
|
57
|
+
uses: docker/setup-qemu-action@v1
|
|
56
58
|
- uses: PyO3/maturin-action@v1.42.1
|
|
57
59
|
with:
|
|
58
60
|
manylinux: auto
|
|
@@ -93,7 +95,8 @@ jobs:
|
|
|
93
95
|
- uses: PyO3/maturin-action@v1.42.1
|
|
94
96
|
with:
|
|
95
97
|
command: build
|
|
96
|
-
|
|
98
|
+
target: universal2-apple-darwin
|
|
99
|
+
args: --release -o dist --find-interpreter
|
|
97
100
|
- name: Upload wheels
|
|
98
101
|
uses: actions/upload-artifact@v4
|
|
99
102
|
with:
|
|
@@ -128,7 +131,7 @@ jobs:
|
|
|
128
131
|
- run: |
|
|
129
132
|
git tag "v$VERSION"
|
|
130
133
|
git push --tags
|
|
131
|
-
gh pr merge --admin --delete-branch
|
|
134
|
+
gh pr merge --admin --delete-branch --merge
|
|
132
135
|
env:
|
|
133
136
|
VERSION: ${{ needs.bump.outputs.version }}
|
|
134
137
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -135,6 +135,15 @@ version = "2.4.0"
|
|
|
135
135
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
136
136
|
checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635"
|
|
137
137
|
|
|
138
|
+
[[package]]
|
|
139
|
+
name = "bitmaps"
|
|
140
|
+
version = "2.1.0"
|
|
141
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
142
|
+
checksum = "031043d04099746d8db04daf1fa424b2bc8bd69d92b25962dcde24da39ab64a2"
|
|
143
|
+
dependencies = [
|
|
144
|
+
"typenum",
|
|
145
|
+
]
|
|
146
|
+
|
|
138
147
|
[[package]]
|
|
139
148
|
name = "block-buffer"
|
|
140
149
|
version = "0.10.4"
|
|
@@ -144,6 +153,12 @@ dependencies = [
|
|
|
144
153
|
"generic-array",
|
|
145
154
|
]
|
|
146
155
|
|
|
156
|
+
[[package]]
|
|
157
|
+
name = "byteorder"
|
|
158
|
+
version = "1.5.0"
|
|
159
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
160
|
+
checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"
|
|
161
|
+
|
|
147
162
|
[[package]]
|
|
148
163
|
name = "cc"
|
|
149
164
|
version = "1.0.83"
|
|
@@ -284,14 +299,15 @@ checksum = "675e35c02a51bb4d4618cb4885b3839ce6d1787c97b664474d9208d074742e20"
|
|
|
284
299
|
|
|
285
300
|
[[package]]
|
|
286
301
|
name = "egglog"
|
|
287
|
-
version = "0.
|
|
288
|
-
source = "git+https://github.com/
|
|
302
|
+
version = "0.2.0"
|
|
303
|
+
source = "git+https://github.com/saulshanabrook/egg-smol?rev=a555b2f5e82c684442775cc1a5da94b71930113c#a555b2f5e82c684442775cc1a5da94b71930113c"
|
|
289
304
|
dependencies = [
|
|
290
305
|
"clap",
|
|
291
306
|
"egraph-serialize",
|
|
292
307
|
"env_logger",
|
|
293
308
|
"generic_symbolic_expressions",
|
|
294
309
|
"hashbrown 0.14.1",
|
|
310
|
+
"im-rc",
|
|
295
311
|
"indexmap",
|
|
296
312
|
"instant",
|
|
297
313
|
"lalrpop",
|
|
@@ -311,8 +327,8 @@ dependencies = [
|
|
|
311
327
|
]
|
|
312
328
|
|
|
313
329
|
[[package]]
|
|
314
|
-
name = "
|
|
315
|
-
version = "
|
|
330
|
+
name = "egglog_python"
|
|
331
|
+
version = "8.0.0"
|
|
316
332
|
dependencies = [
|
|
317
333
|
"egglog",
|
|
318
334
|
"egraph-serialize",
|
|
@@ -329,7 +345,7 @@ dependencies = [
|
|
|
329
345
|
[[package]]
|
|
330
346
|
name = "egraph-serialize"
|
|
331
347
|
version = "0.1.0"
|
|
332
|
-
source = "git+https://github.com/
|
|
348
|
+
source = "git+https://github.com/saulshanabrook/egraph-serialize?rev=1c205fcc6d3426800b828e9264dbadbd4a5ef6e9#1c205fcc6d3426800b828e9264dbadbd4a5ef6e9"
|
|
333
349
|
dependencies = [
|
|
334
350
|
"graphviz-rust",
|
|
335
351
|
"indexmap",
|
|
@@ -396,9 +412,9 @@ dependencies = [
|
|
|
396
412
|
|
|
397
413
|
[[package]]
|
|
398
414
|
name = "fastrand"
|
|
399
|
-
version = "2.0
|
|
415
|
+
version = "2.1.0"
|
|
400
416
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
401
|
-
checksum = "
|
|
417
|
+
checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a"
|
|
402
418
|
|
|
403
419
|
[[package]]
|
|
404
420
|
name = "fixedbitset"
|
|
@@ -418,8 +434,9 @@ dependencies = [
|
|
|
418
434
|
|
|
419
435
|
[[package]]
|
|
420
436
|
name = "generic_symbolic_expressions"
|
|
421
|
-
version = "5.0.
|
|
422
|
-
source = "
|
|
437
|
+
version = "5.0.4"
|
|
438
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
439
|
+
checksum = "597eb584fb7cfd1935294fc3608a453fc35a58dfa9da4299c8fd3bc75a4c0b4b"
|
|
423
440
|
|
|
424
441
|
[[package]]
|
|
425
442
|
name = "getrandom"
|
|
@@ -485,6 +502,20 @@ version = "2.1.0"
|
|
|
485
502
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
486
503
|
checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4"
|
|
487
504
|
|
|
505
|
+
[[package]]
|
|
506
|
+
name = "im-rc"
|
|
507
|
+
version = "15.1.0"
|
|
508
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
509
|
+
checksum = "af1955a75fa080c677d3972822ec4bad316169ab1cfc6c257a942c2265dbe5fe"
|
|
510
|
+
dependencies = [
|
|
511
|
+
"bitmaps",
|
|
512
|
+
"rand_core",
|
|
513
|
+
"rand_xoshiro",
|
|
514
|
+
"sized-chunks",
|
|
515
|
+
"typenum",
|
|
516
|
+
"version_check",
|
|
517
|
+
]
|
|
518
|
+
|
|
488
519
|
[[package]]
|
|
489
520
|
name = "indexmap"
|
|
490
521
|
version = "2.2.6"
|
|
@@ -730,9 +761,9 @@ dependencies = [
|
|
|
730
761
|
|
|
731
762
|
[[package]]
|
|
732
763
|
name = "pest"
|
|
733
|
-
version = "2.7.
|
|
764
|
+
version = "2.7.11"
|
|
734
765
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
735
|
-
checksum = "
|
|
766
|
+
checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95"
|
|
736
767
|
dependencies = [
|
|
737
768
|
"memchr",
|
|
738
769
|
"thiserror",
|
|
@@ -741,9 +772,9 @@ dependencies = [
|
|
|
741
772
|
|
|
742
773
|
[[package]]
|
|
743
774
|
name = "pest_derive"
|
|
744
|
-
version = "2.7.
|
|
775
|
+
version = "2.7.11"
|
|
745
776
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
746
|
-
checksum = "
|
|
777
|
+
checksum = "2a548d2beca6773b1c244554d36fcf8548a8a58e74156968211567250e48e49a"
|
|
747
778
|
dependencies = [
|
|
748
779
|
"pest",
|
|
749
780
|
"pest_generator",
|
|
@@ -751,9 +782,9 @@ dependencies = [
|
|
|
751
782
|
|
|
752
783
|
[[package]]
|
|
753
784
|
name = "pest_generator"
|
|
754
|
-
version = "2.7.
|
|
785
|
+
version = "2.7.11"
|
|
755
786
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
756
|
-
checksum = "
|
|
787
|
+
checksum = "3c93a82e8d145725dcbaf44e5ea887c8a869efdcc28706df2d08c69e17077183"
|
|
757
788
|
dependencies = [
|
|
758
789
|
"pest",
|
|
759
790
|
"pest_meta",
|
|
@@ -764,9 +795,9 @@ dependencies = [
|
|
|
764
795
|
|
|
765
796
|
[[package]]
|
|
766
797
|
name = "pest_meta"
|
|
767
|
-
version = "2.7.
|
|
798
|
+
version = "2.7.11"
|
|
768
799
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
769
|
-
checksum = "
|
|
800
|
+
checksum = "a941429fea7e08bedec25e4f6785b6ffaacc6b755da98df5ef3e7dcf4a124c4f"
|
|
770
801
|
dependencies = [
|
|
771
802
|
"once_cell",
|
|
772
803
|
"pest",
|
|
@@ -806,9 +837,12 @@ checksum = "7170ef9988bc169ba16dd36a7fa041e5c4cbeb6a35b76d4c03daded371eae7c0"
|
|
|
806
837
|
|
|
807
838
|
[[package]]
|
|
808
839
|
name = "ppv-lite86"
|
|
809
|
-
version = "0.2.
|
|
840
|
+
version = "0.2.20"
|
|
810
841
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
811
|
-
checksum = "
|
|
842
|
+
checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04"
|
|
843
|
+
dependencies = [
|
|
844
|
+
"zerocopy",
|
|
845
|
+
]
|
|
812
846
|
|
|
813
847
|
[[package]]
|
|
814
848
|
name = "precomputed-hash"
|
|
@@ -940,6 +974,15 @@ dependencies = [
|
|
|
940
974
|
"serde",
|
|
941
975
|
]
|
|
942
976
|
|
|
977
|
+
[[package]]
|
|
978
|
+
name = "rand_xoshiro"
|
|
979
|
+
version = "0.6.0"
|
|
980
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
981
|
+
checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa"
|
|
982
|
+
dependencies = [
|
|
983
|
+
"rand_core",
|
|
984
|
+
]
|
|
985
|
+
|
|
943
986
|
[[package]]
|
|
944
987
|
name = "redox_syscall"
|
|
945
988
|
version = "0.2.16"
|
|
@@ -1090,6 +1133,16 @@ version = "0.3.11"
|
|
|
1090
1133
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1091
1134
|
checksum = "38b58827f4464d87d377d175e90bf58eb00fd8716ff0a62f80356b5e61555d0d"
|
|
1092
1135
|
|
|
1136
|
+
[[package]]
|
|
1137
|
+
name = "sized-chunks"
|
|
1138
|
+
version = "0.6.5"
|
|
1139
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1140
|
+
checksum = "16d69225bde7a69b235da73377861095455d298f2b970996eec25ddbb42b3d1e"
|
|
1141
|
+
dependencies = [
|
|
1142
|
+
"bitmaps",
|
|
1143
|
+
"typenum",
|
|
1144
|
+
]
|
|
1145
|
+
|
|
1093
1146
|
[[package]]
|
|
1094
1147
|
name = "smallvec"
|
|
1095
1148
|
version = "1.11.0"
|
|
@@ -1368,3 +1421,24 @@ name = "windows_x86_64_msvc"
|
|
|
1368
1421
|
version = "0.48.0"
|
|
1369
1422
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1370
1423
|
checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a"
|
|
1424
|
+
|
|
1425
|
+
[[package]]
|
|
1426
|
+
name = "zerocopy"
|
|
1427
|
+
version = "0.7.35"
|
|
1428
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1429
|
+
checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0"
|
|
1430
|
+
dependencies = [
|
|
1431
|
+
"byteorder",
|
|
1432
|
+
"zerocopy-derive",
|
|
1433
|
+
]
|
|
1434
|
+
|
|
1435
|
+
[[package]]
|
|
1436
|
+
name = "zerocopy-derive"
|
|
1437
|
+
version = "0.7.35"
|
|
1438
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1439
|
+
checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e"
|
|
1440
|
+
dependencies = [
|
|
1441
|
+
"proc-macro2",
|
|
1442
|
+
"quote",
|
|
1443
|
+
"syn 2.0.60",
|
|
1444
|
+
]
|
egglog-8.0.0/Cargo.toml
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
[package]
|
|
2
|
+
name = "egglog_python"
|
|
3
|
+
version = "8.0.0"
|
|
4
|
+
edition = "2021"
|
|
5
|
+
|
|
6
|
+
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
|
7
|
+
[lib]
|
|
8
|
+
name = "egglog"
|
|
9
|
+
crate-type = ["cdylib"]
|
|
10
|
+
|
|
11
|
+
[dependencies]
|
|
12
|
+
pyo3 = { version = "0.21", features = ["extension-module"] }
|
|
13
|
+
|
|
14
|
+
# https://github.com/egraphs-good/egglog/compare/ceed816e9369570ffed9feeba157b19471dda70d...main
|
|
15
|
+
# egglog = { git = "https://github.com/egraphs-good/egglog", rev = "fb4a9f114f9bb93154d6eff0dbab079b5cb4ebb6" }
|
|
16
|
+
# egglog = { path = "../egg-smol" }
|
|
17
|
+
# egglog = { git = "https://github.com/oflatt/egg-smol", branch = "oflatt-fast-terms" }
|
|
18
|
+
egglog = { git = "https://github.com/saulshanabrook/egg-smol", rev = "a555b2f5e82c684442775cc1a5da94b71930113c" }
|
|
19
|
+
egraph-serialize = { git = "https://github.com/saulshanabrook/egraph-serialize", rev = "1c205fcc6d3426800b828e9264dbadbd4a5ef6e9", features = [
|
|
20
|
+
"serde",
|
|
21
|
+
"graphviz",
|
|
22
|
+
] }
|
|
23
|
+
# egraph-serialize = { path = "../egraph-serialize", features = [
|
|
24
|
+
# "serde",
|
|
25
|
+
# "graphviz",
|
|
26
|
+
# ] }
|
|
27
|
+
serde_json = "*"
|
|
28
|
+
pyo3-log = "0.10.0"
|
|
29
|
+
log = "0.4.21"
|
|
30
|
+
lalrpop-util = { version = "0.20.2", features = ["lexer"] }
|
|
31
|
+
ordered-float = "*"
|
|
32
|
+
uuid = { version = "1.8.0", features = ["v4"] }
|
|
33
|
+
num-rational = "*"
|
|
34
|
+
|
|
35
|
+
# Use unreleased version of egraph-serialize in egglog as well
|
|
36
|
+
# [patch.crates-io]
|
|
37
|
+
# egraph-serialize = { git = "https://github.com/egraphs-good/egraph-serialize", rev = "5838c036623e91540831745b1574539e01c8cb23" }
|
|
38
|
+
# egraph-serialize = { path = "../egraph-serialize" }
|
|
39
|
+
|
|
40
|
+
# enable debug symbols for easier profiling
|
|
41
|
+
# [profile.release]
|
|
42
|
+
# debug = 1
|
egglog-8.0.0/Makefile
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
|
|
2
|
+
all: python/egglog/visualizer.js
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
# download visualizer release from github
|
|
7
|
+
#
|
|
8
|
+
visualizer.tgz:
|
|
9
|
+
curl -s https://api.github.com/repos/egraphs-good/egraph-visualizer/releases/latest \
|
|
10
|
+
| grep "browser_download_url.*tgz" \
|
|
11
|
+
| cut -d : -f 2,3 \
|
|
12
|
+
| tr -d \" \
|
|
13
|
+
| wget -qi - -O visualizer.tgz
|
|
14
|
+
|
|
15
|
+
# extract visualizer release
|
|
16
|
+
python/egglog/visualizer.js python/egglog/visualizer.css: visualizer.tgz
|
|
17
|
+
tar -xzf visualizer.tgz
|
|
18
|
+
rm visualizer.tgz
|
|
19
|
+
mv package/dist/index.js python/egglog/visualizer.js
|
|
20
|
+
mv package/dist/style.css python/egglog/visualizer.css
|
|
21
|
+
rm -rf package
|
|
22
|
+
|
|
23
|
+
clean:
|
|
24
|
+
rm -rf package python/egglog/visualizer.css python/egglog/visualizer.js visualizer.tgz
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
2
|
Name: egglog
|
|
3
|
-
Version:
|
|
3
|
+
Version: 8.0.0
|
|
4
4
|
Classifier: Environment :: MacOS X
|
|
5
5
|
Classifier: Environment :: Win32 (MS Windows)
|
|
6
6
|
Classifier: Intended Audience :: Developers
|
|
@@ -19,38 +19,39 @@ Classifier: Typing :: Typed
|
|
|
19
19
|
Requires-Dist: typing-extensions
|
|
20
20
|
Requires-Dist: black
|
|
21
21
|
Requires-Dist: graphviz
|
|
22
|
-
Requires-Dist:
|
|
23
|
-
Requires-Dist:
|
|
24
|
-
Requires-Dist:
|
|
25
|
-
Requires-Dist:
|
|
26
|
-
Requires-Dist:
|
|
27
|
-
Requires-Dist:
|
|
28
|
-
Requires-Dist:
|
|
29
|
-
Requires-Dist:
|
|
30
|
-
Requires-Dist:
|
|
31
|
-
Requires-Dist:
|
|
32
|
-
Requires-Dist:
|
|
33
|
-
Requires-Dist:
|
|
34
|
-
Requires-Dist:
|
|
35
|
-
Requires-Dist:
|
|
36
|
-
Requires-Dist:
|
|
37
|
-
Requires-Dist:
|
|
38
|
-
Requires-Dist:
|
|
39
|
-
Requires-Dist:
|
|
40
|
-
Requires-Dist:
|
|
41
|
-
Requires-Dist:
|
|
42
|
-
Requires-Dist:
|
|
43
|
-
Requires-Dist:
|
|
44
|
-
Requires-Dist:
|
|
45
|
-
Requires-Dist:
|
|
46
|
-
Requires-Dist:
|
|
47
|
-
Requires-Dist:
|
|
48
|
-
Requires-Dist:
|
|
49
|
-
Requires-Dist:
|
|
50
|
-
|
|
22
|
+
Requires-Dist: anywidget
|
|
23
|
+
Requires-Dist: scikit-learn ; extra == 'array'
|
|
24
|
+
Requires-Dist: array-api-compat ; extra == 'array'
|
|
25
|
+
Requires-Dist: numba ==0.59.1 ; extra == 'array'
|
|
26
|
+
Requires-Dist: llvmlite ==0.42.0 ; extra == 'array'
|
|
27
|
+
Requires-Dist: pre-commit ; extra == 'dev'
|
|
28
|
+
Requires-Dist: ruff ; extra == 'dev'
|
|
29
|
+
Requires-Dist: mypy ; extra == 'dev'
|
|
30
|
+
Requires-Dist: anywidget[dev] ; extra == 'dev'
|
|
31
|
+
Requires-Dist: egglog[docs,test] ; extra == 'dev'
|
|
32
|
+
Requires-Dist: pytest ; extra == 'test'
|
|
33
|
+
Requires-Dist: mypy ; extra == 'test'
|
|
34
|
+
Requires-Dist: syrupy ; extra == 'test'
|
|
35
|
+
Requires-Dist: egglog[array] ; extra == 'test'
|
|
36
|
+
Requires-Dist: pytest-codspeed ; extra == 'test'
|
|
37
|
+
Requires-Dist: pytest-benchmark ; extra == 'test'
|
|
38
|
+
Requires-Dist: pytest-xdist ; extra == 'test'
|
|
39
|
+
Requires-Dist: pydata-sphinx-theme ; extra == 'docs'
|
|
40
|
+
Requires-Dist: myst-nb ; extra == 'docs'
|
|
41
|
+
Requires-Dist: sphinx-autodoc-typehints ; extra == 'docs'
|
|
42
|
+
Requires-Dist: sphinx-gallery ; extra == 'docs'
|
|
43
|
+
Requires-Dist: nbconvert ; extra == 'docs'
|
|
44
|
+
Requires-Dist: matplotlib ; extra == 'docs'
|
|
45
|
+
Requires-Dist: anywidget ; extra == 'docs'
|
|
46
|
+
Requires-Dist: seaborn ; extra == 'docs'
|
|
47
|
+
Requires-Dist: egglog[array] ; extra == 'docs'
|
|
48
|
+
Requires-Dist: line-profiler ; extra == 'docs'
|
|
49
|
+
Requires-Dist: sphinxcontrib-mermaid ; extra == 'docs'
|
|
50
|
+
Requires-Dist: ablog ; extra == 'docs'
|
|
51
51
|
Provides-Extra: array
|
|
52
|
-
Provides-Extra: docs
|
|
53
52
|
Provides-Extra: dev
|
|
53
|
+
Provides-Extra: test
|
|
54
|
+
Provides-Extra: docs
|
|
54
55
|
License-File: LICENSE
|
|
55
56
|
Summary: e-graphs in Python built around the the egglog rust library
|
|
56
57
|
License: MIT
|
|
@@ -4,6 +4,21 @@ _This project uses semantic versioning_
|
|
|
4
4
|
|
|
5
5
|
## UNRELEASED
|
|
6
6
|
|
|
7
|
+
## 8.0.0 (2024-10-17)
|
|
8
|
+
|
|
9
|
+
- Adds ability to use anonymous functions where callables are needed. These are automatically transformed to egglog
|
|
10
|
+
functions with default rewrites.
|
|
11
|
+
- Upgrade [egglog](https://github.com/egraphs-good/egglog/compare/fb4a9f114f9bb93154d6eff0dbab079b5cb4ebb6...saulshanabrook:egg-smol:a555b2f5e82c684442775cc1a5da94b71930113c)
|
|
12
|
+
- Adds source annotations to expressions for tracebacks
|
|
13
|
+
- Adds ability to inline other functions besides primitives in serialized output
|
|
14
|
+
- Adds `remove` and `set` methods to `Vec`
|
|
15
|
+
- Upgrades to use the new egraph-visualizer so we can have interactive visualizations
|
|
16
|
+
|
|
17
|
+
## 7.2.0 (2024-05-23)
|
|
18
|
+
|
|
19
|
+
- Adds ability to use function bodies as default rewrites ([#167](https://github.com/egraphs-good/egglog-python/pull/167))
|
|
20
|
+
- Fixed bug with creating empty maps and adding to maps ([#168](https://github.com/egraphs-good/egglog-python/pull/168))
|
|
21
|
+
|
|
7
22
|
## 7.1.0 (2024-05-03)
|
|
8
23
|
|
|
9
24
|
## New Feaatures
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
file_format: mystnb
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
#
|
|
5
|
+
# `egglog` Python
|
|
6
6
|
|
|
7
|
-
`egglog` is a Python package that provides bindings to the Rust library of the same name,
|
|
7
|
+
`egglog` is a Python package that provides bindings to [the Rust library of the same name](https://github.com/egraphs-good/egglog/),
|
|
8
8
|
allowing you to use e-graphs in Python for optimization, symbolic computation, and analysis.
|
|
9
9
|
|
|
10
10
|
It wraps the Rust library [`egglog`](https://github.com/egraphs-good/egglog) which
|
|
@@ -13,14 +13,10 @@ See the ["Better Together: Unifying Datalog and Equality Saturation"](https://ar
|
|
|
13
13
|
|
|
14
14
|
> We present egglog, a fixpoint reasoning system that unifies Datalog and equality saturation (EqSat). Like Datalog, it supports efficient incremental execution, cooperating analyses, and lattice-based reasoning. Like EqSat, it supports term rewriting, efficient congruence closure, and extraction of optimized terms.
|
|
15
15
|
|
|
16
|
-
## [Installation](./reference/usage)
|
|
17
|
-
|
|
18
16
|
```shell
|
|
19
17
|
pip install egglog
|
|
20
18
|
```
|
|
21
19
|
|
|
22
|
-
## Example
|
|
23
|
-
|
|
24
20
|
```{code-cell} python
|
|
25
21
|
from __future__ import annotations
|
|
26
22
|
from egglog import *
|
|
@@ -49,15 +45,10 @@ def _num_rule(a: Num, b: Num, c: Num, i: i64, j: i64):
|
|
|
49
45
|
yield rewrite(Num(i) * Num(j)).to(Num(i * j))
|
|
50
46
|
|
|
51
47
|
egraph.saturate()
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
```{code-cell} python
|
|
55
48
|
egraph.check(eq(expr1).to(expr2))
|
|
56
49
|
egraph.extract(expr1)
|
|
57
50
|
```
|
|
58
51
|
|
|
59
|
-
## Contents
|
|
60
|
-
|
|
61
52
|
```{toctree}
|
|
62
53
|
:maxdepth: 2
|
|
63
54
|
tutorials
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
## Development
|
|
4
|
+
|
|
5
|
+
This package is in active development and welcomes contributions!
|
|
6
|
+
|
|
7
|
+
Feel free to bring up any questions/comments on [the Zulip chat](https://egraphs.zulipchat.com/) or open an issue.
|
|
8
|
+
|
|
9
|
+
All feedback is welcome and encouraged, it's great to hear about anything that works well or could be improved.
|
|
10
|
+
|
|
11
|
+
### Getting Started
|
|
12
|
+
|
|
13
|
+
To get started locally developing with this project, fork it and clone it to your local machine.
|
|
14
|
+
|
|
15
|
+
Using [the Github CLI](https://github.com/cli/cli#installation) this would be:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
brew install gh
|
|
19
|
+
gh repo fork egraphs-good/egglog-python --clone
|
|
20
|
+
cd egglog-python
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
Then [install Rust](https://www.rust-lang.org/tools/install) and get a Python environment set up with a compatible version. Using [miniconda](https://formulae.brew.sh/cask/miniconda) this would be:
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
|
27
|
+
brew install --cask miniconda
|
|
28
|
+
conda create -n egglog-python python
|
|
29
|
+
conda activate egglog-python
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Then install the package in editable mode with the development dependencies:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
maturin develop -E dev,docs,test,array
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Anytime you change the rust code, you can run `maturin develop -E` to recompile the rust code.
|
|
39
|
+
|
|
40
|
+
If you would like to download a new version of the visualizer source, run `make clean; make`. This will download
|
|
41
|
+
the most recent released version from the github actions artifact in the [egraph-visualizer](https://github.com/egraphs-good/egraph-visualizer) repo. It is checked in because it's a pain to get cargo to include only one git ignored file while ignoring the rest of the files that were ignored.
|
|
42
|
+
|
|
43
|
+
### Running Tests
|
|
44
|
+
|
|
45
|
+
To run the tests, you can use the `pytest` command:
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
pytest
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
All code must pass ruff linters and formaters. This will be checked automatically by the pre-commit if you run `pre-commit install`.
|
|
52
|
+
|
|
53
|
+
To run it manually, you can use:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
pre-commit run --all-files ruff
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
If you make changes to the rust bindings, you can check that the stub files accurately reflect the rust code by running:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
pre-commit run --all-files --hook-stage manual stubtest
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
All code must all pass MyPy type checking. To run that locally use:
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
pre-commit run --all-files --hook-stage manual mypy
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Finally, to build the docs locally and test that they work, you can run:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
pre-commit run --all-files --hook-stage manual docs
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Making changes
|
|
78
|
+
|
|
79
|
+
All changes that impact users should be documented in the `docs/changelog.md` file. Please also add tests for any new features
|
|
80
|
+
or bug fixes.
|
|
81
|
+
|
|
82
|
+
When you are ready to submit your changes, please open a pull request. The CI will run the tests and check the code style.
|
|
83
|
+
|
|
84
|
+
## Documentation
|
|
85
|
+
|
|
86
|
+
We use the [Diátaxis framework](https://diataxis.fr/) to organize our documentation. The "explanation" section has
|
|
87
|
+
been renamed to "Blog" since most of the content there is more like a blog post than a reference manual. It uses
|
|
88
|
+
the [ABlog](https://ablog.readthedocs.io/en/stable/index.html#how-it-works) extension.
|
|
89
|
+
|
|
90
|
+
## Governance
|
|
91
|
+
|
|
92
|
+
The governance is currently informal, with Saul Shanabrook as the lead maintainer. If the project grows and there
|
|
93
|
+
are more contributors, we will formalize the governance structure in a way to allow it to be multi-stakeholder and
|
|
94
|
+
to spread out the power and responsibility.
|