Skip to content

Conversation

@eriknw
Copy link
Member

@eriknw eriknw commented Mar 11, 2021

  • Add __slots__ to all the things
    • it simplifies serializing Scalar, Vector, and Matrix (don't need to worry about __getstate__ and __setstate__)
    • we may want to serialize other things eventually too (when there is need)
    • slightly faster and less memory usage
    • behaves similar to if we wrapped things in Cython
  • Move SuiteSparse-specific functions and things to grblas._ss namespace.
    • We can rename to grblas.ss once this has useful things for users.
  • Give ParameterizedBinaryOp a .monoid attribute just like other binaryops.

Note that pickling Vector and Matrix objects uses export/import from SuiteSparse. I haven't been very strict about checking the backend. It would help to have a non-SuiteSparse backend to test.

eriknw added 5 commits March 10, 2021 23:47
…ness.

Using `__slots__` will make it easier to serialize objects.
Also, allow `ParameterizedBinaryOp` to be associated with a monoid.
…eful yet.

We can rename the namespace once it has useful things for users.
@eriknw
Copy link
Member Author

eriknw commented Mar 11, 2021

I think this is ready to go in.

@eriknw eriknw merged commit 5426f3f into python-graphblas:main Mar 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants