sybila / biodivine-lib-param-bn

Rust library for working with parametrised Boolean networks.
MIT License
2 stars 2 forks source link

Computation of minimal trap spaces #51

Closed daemontus closed 7 months ago

daemontus commented 7 months ago

This PR adds the ability to compute minimal trap spaces, similar to how fixed-points can be computed already. It also slightly improves APIs related to iteration.

In terms of validation, I have only added some basic tests, but I compared the results to trappist on BBM models and everything seems to be in order. We can add an automated comparison down the line, but for now I didn't really want to bother with calling Python dependencies from Rust.

Som initial API was already present, so this tries to align with it as well as we can.

Trap space related API:

Updates to existing API:

Misc changes:

codecov[bot] commented 7 months ago

Codecov Report

Attention: 57 lines in your changes are missing coverage. Please review.

Comparison is base (60ea437) 78.13% compared to head (bbb1e00) 80.26%.

Files Patch % Lines
src/symbolic_async_graph/_impl_graph_vertices.rs 38.88% 11 Missing :warning:
src/trap_spaces/_impl_network_colored_spaces.rs 86.74% 11 Missing :warning:
src/trap_spaces/_impl_symbolic_space_context.rs 89.90% 11 Missing :warning:
src/trap_spaces/_impl_network_spaces.rs 88.88% 7 Missing :warning:
...mbolic_async_graph/_impl_graph_colored_vertices.rs 78.26% 5 Missing :warning:
src/_impl_extended_boolean.rs 0.00% 4 Missing :warning:
src/symbolic_async_graph/_impl_graph_colors.rs 40.00% 3 Missing :warning:
src/trap_spaces/_impl_trap_spaces.rs 96.15% 3 Missing :warning:
src/_impl_space.rs 0.00% 2 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #51 +/- ## ========================================== + Coverage 78.13% 80.26% +2.13% ========================================== Files 67 71 +4 Lines 4377 4744 +367 ========================================== + Hits 3420 3808 +388 + Misses 957 936 -21 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.