graphblas-algorithms
graphblas-algorithms copied to clipboard
Redo/refactor calculations and caching of properties such as degrees
We compute and cache many properties such as has_self_edges, degrees- (w/o diagonals), degrees+ (with diagonals), etc., which is actually very handy. However, the code is a little complicated (cough cough, my bad) and may be error prone (see: https://github.com/python-graphblas/graphblas-algorithms/issues/82#issuecomment-1840040146). It would be great if we could refactor this to be more clear, maintainable, and safe. I imagine such a solution would be more declarative and less procedural.