aplbrain / dotmotif

A performant, powerful query framework to search for network motifs
https://bossdb.org/tools/dotmotif
Apache License 2.0
81 stars 9 forks source link

Add edge aliasing and edge constraints #119

Closed j6k4m8 closed 2 years ago

j6k4m8 commented 2 years ago

This PR adds support for edge aliases (first described in #110) and comparisons between edge attributes with values and with other edges.

This enables syntax like this:

A -> B as ab
B -> A as ba

ab.weight > ba.weight

I am going to push macro support in a separate PR, since this one is getting pretty lengthy already!

codecov-commenter commented 2 years ago

Codecov Report

Merging #119 (db4154a) into master (16e5f84) will increase coverage by 1.04%. The diff coverage is 98.06%.

@@            Coverage Diff             @@
##           master     #119      +/-   ##
==========================================
+ Coverage   90.12%   91.17%   +1.04%     
==========================================
  Files          22       22              
  Lines        1793     2028     +235     
==========================================
+ Hits         1616     1849     +233     
- Misses        177      179       +2     
Impacted Files Coverage Δ
dotmotif/parsers/v2/__init__.py 94.68% <93.67%> (-0.74%) :arrow_down:
dotmotif/__init__.py 97.59% <100.00%> (+3.33%) :arrow_up:
dotmotif/executors/GrandIsoExecutor.py 83.33% <100.00%> (+0.47%) :arrow_up:
dotmotif/executors/Neo4jExecutor.py 72.61% <100.00%> (+1.01%) :arrow_up:
dotmotif/executors/NetworkXExecutor.py 92.30% <100.00%> (+0.83%) :arrow_up:
dotmotif/executors/test_dm_cypher.py 100.00% <100.00%> (ø)
dotmotif/executors/test_grandisoexecutor.py 100.00% <100.00%> (ø)
dotmotif/executors/test_networkxexecutor.py 100.00% <100.00%> (ø)
dotmotif/parsers/v2/test_v2_parser.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 16e5f84...db4154a. Read the comment docs.