dwavesystems / dwavesystems/dimod

CooBQM

Open
#604 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
143
Forks
91
Avg merge
1h 24m
Merged PRs (30d)
3

Description

#533 adds a variety of BQMs of different formats. Another one we could consider implementing would be a non-shapeable bqm that keeps its biases in [coordinate form](https://en.wikipedia.org/wiki/Sparse_matrix#Coordinate_list_(COO)) in numpy arrays. This would be a nice reference example to go alongside the `AdjDictBQM`. It would also be a useful intermediate representation for methods like `BQM.to_numpy_vectors` and `BQM.to_serializable`

Scipy [provides a nice explanation of the benefits of COO format](https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.coo_matrix.html#scipy.sparse.coo_matrix).

Another benefit over the existing BQMs is that this format would use less memory (at the cost of slower access).

Construction would look something like
```
>>> bqm = CooBQM(arr, dimod.SPIN)
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.