simulation-alg 0.1.10__tar.gz → 0.1.13__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.
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/Cargo.lock +3 -3
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/Cargo.toml +2 -2
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/PKG-INFO +1 -1
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/pyproject.toml +1 -1
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/simulation.pyi +6 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/src/graph/hypergraph.rs +9 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/.github/workflows/ci.yml +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/.gitignore +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/.gitmodules +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/LICENSE +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/README.md +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/hyper-simulation.log +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/python/__init__.py +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/requirements.txt +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/src/graph/mod.rs +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/src/graph/networkx_graph.rs +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/src/lib.rs +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/src/utils.rs +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/test.py +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/test_bounded_simulation.py +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/tests/test_hyper_simulation.py +0 -0
- {simulation_alg-0.1.10 → simulation_alg-0.1.13}/tests/test_simulation.py +0 -0
|
@@ -188,9 +188,9 @@ dependencies = [
|
|
|
188
188
|
|
|
189
189
|
[[package]]
|
|
190
190
|
name = "graph-simulation"
|
|
191
|
-
version = "0.1.
|
|
191
|
+
version = "0.1.26"
|
|
192
192
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
193
|
-
checksum = "
|
|
193
|
+
checksum = "d9d438a0ffa1040ffc4355fe60bdbab50e4b08e51f879258666b5c9361c9daeb"
|
|
194
194
|
dependencies = [
|
|
195
195
|
"bincode",
|
|
196
196
|
"env_logger",
|
|
@@ -543,7 +543,7 @@ dependencies = [
|
|
|
543
543
|
|
|
544
544
|
[[package]]
|
|
545
545
|
name = "simulation"
|
|
546
|
-
version = "0.1.
|
|
546
|
+
version = "0.1.13"
|
|
547
547
|
dependencies = [
|
|
548
548
|
"graph-base",
|
|
549
549
|
"graph-simulation",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[package]
|
|
2
2
|
name = "simulation"
|
|
3
|
-
version = "0.1.
|
|
3
|
+
version = "0.1.13"
|
|
4
4
|
edition = "2021"
|
|
5
5
|
license = "MIT"
|
|
6
6
|
description = "A Python package for simulation algorithms"
|
|
@@ -14,7 +14,7 @@ crate-type = ["cdylib"]
|
|
|
14
14
|
|
|
15
15
|
[dependencies]
|
|
16
16
|
pyo3 = { version = "0.27.1", features = ["extension-module"] }
|
|
17
|
-
graph-simulation = "0.1.
|
|
17
|
+
graph-simulation = "0.1.26"
|
|
18
18
|
graph-base = "0.1.14"
|
|
19
19
|
rayon = "1.10.0"
|
|
20
20
|
# [tool.maturin]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: simulation-alg
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.13
|
|
4
4
|
Classifier: Programming Language :: Rust
|
|
5
5
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
6
6
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
@@ -133,4 +133,10 @@ class Hypergraph:
|
|
|
133
133
|
"""
|
|
134
134
|
Hyper Simulation
|
|
135
135
|
"""
|
|
136
|
+
|
|
137
|
+
@staticmethod
|
|
138
|
+
def get_hyper_simulation_strict(query: 'Hypergraph', data: 'Hypergraph', delta: Delta, d_match: DMatch) -> dict[int, set[int]]:
|
|
139
|
+
"""
|
|
140
|
+
Strict Hyper Simulation
|
|
141
|
+
"""
|
|
136
142
|
|
|
@@ -174,6 +174,15 @@ impl Hypergraph {
|
|
|
174
174
|
.collect()
|
|
175
175
|
}
|
|
176
176
|
|
|
177
|
+
#[staticmethod]
|
|
178
|
+
pub fn get_hyper_simulation_strict(query: PyRef<Hypergraph>, data: PyRef<Hypergraph>, delta: PyRef<DeltaPy>, d_match: PyRef<DMatchImpl>) -> HashMap<usize, HashSet<usize>> {
|
|
179
|
+
let delta_inner = DeltaImpl::from(delta.clone(), &*query, &*data);
|
|
180
|
+
let sim = HyperSimulation::get_hyper_simulation_strict(&*query, &*data, &delta_inner, &*d_match);
|
|
181
|
+
sim.into_iter()
|
|
182
|
+
.map(|(k, v)| (k.id(), v.into_iter().map(|n| n.id()).collect()))
|
|
183
|
+
.collect()
|
|
184
|
+
}
|
|
185
|
+
|
|
177
186
|
pub fn get_hyper_simulation_trace(&self) -> Vec<Event> {
|
|
178
187
|
let trace = HyperSimulationTrace::get_trace("hyper_simulation.trace").unwrap();
|
|
179
188
|
let events = trace.into_iter().map(|event| {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|