MCPcopy Create free account
hub / github.com/RoaringBitmap/roaring / IntersectAndTranspose

Method IntersectAndTranspose

BitSliceIndexing/bsi.go:600–606  ·  view source on GitHub ↗

IntersectAndTranspose is a matrix transpose function. Return a bitmap such that the values are represented as column IDs in the returned bitmap. This is accomplished by iterating over the foundSet and only including the column IDs in the source (foundSet) as compared with this BSI. This can be use

(parallelism int, foundSet *roaring.Bitmap)

Source from the content-addressed store, hash-verified

598// the column IDs in the source (foundSet) as compared with this BSI. This can be useful for
599// vectoring one set of integers to another.
600func (b *BSI) IntersectAndTranspose(parallelism int, foundSet *roaring.Bitmap) *roaring.Bitmap {
601 if foundSet == nil {
602 foundSet = b.eBM
603 }
604 trans := &task{bsi: b}
605 return parallelExecutor(parallelism, trans, transpose, foundSet)
606}
607
608func transpose(e *task, batch []uint32, resultsChan chan *roaring.Bitmap, wg *sync.WaitGroup) {
609

Callers 1

TransposeMethod · 0.95

Calls 1

parallelExecutorFunction · 0.70

Tested by

no test coverage detected