A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/bmrs_8h_source.html below:

NCBI C++ ToolKit: include/util/bitset/bmrs.h Source File

1 #ifndef BMRS__H__INCLUDED__ 2 #define BMRS__H__INCLUDED__ 39 template

<

typename

BVAlloc>

96  const unsigned

* bcount,

165  const unsigned char _lut

[65536] = {0, };

169  #if defined(BM64_SSE4) || defined(BM64_AVX2) || defined(BM64_AVX512) 172  const unsigned

cutoff_bias = 0;

175  for

(

unsigned

nbit_right = 0; nbit_right < 65536; ++nbit_right)

255  const_cast<unsigned char

*

>

(

_lut

),

256

nbit_right, (

unsigned char

)sub);

273 template

<

typename

BVAlloc>

282 template

<

typename

BVAlloc>

285

sblock_count_.resize(0);

286

sblock_row_idx_.resize(0);

287

block_matr_.resize(0, 0,

false

);

288

sub_block_matr_.resize(0, 0,

false

);

290

total_blocks_ = sblock_rows_ = max_sblock_ = 0;

295 template

<

typename

BVAlloc>

301  BM_ASSERT

(sblock_count == (new_size / 256) + 3);

302

sblock_count_.resize(sblock_count);

303

sblock_row_idx_.resize(sblock_count);

308 template

<

typename

BVAlloc>

323 template

<

typename

BVAlloc>

326  if

(nb >= total_blocks_)

329  size_type

sb_count = get_super_block_count(

i

);

338  unsigned

row_idx = sblock_row_idx_[

i

+1];

339  const unsigned

*

row

= block_matr_.row(row_idx);

342

bc = (!j) ?

row

[j] :

row

[j] -

row

[j-1];

348 template

<

typename

BVAlloc>

354  return

sblock_count_[max_sblock_ + 1];

359 template

<

typename

BVAlloc>

364  size_type

sb_rcount =

i

? get_super_block_rcount(

i

-1) :

i

;

366  unsigned

sb_count = get_super_block_count(

i

);

374

sb_rcount += sb_count;

378  unsigned

row_idx = sblock_row_idx_[

i

+1];

379  const unsigned

*

row

= block_matr_.row(row_idx);

380  unsigned

bc =

row

[j];

388 template

<

typename

BVAlloc>

397 template

<

typename

BVAlloc>

403  unsigned

sub_cnt = unsigned(sub);

404  unsigned first

= sub_cnt & 0xFFFF;

405  unsigned

second = sub_cnt >> 16;

423 template

<

typename

BVAlloc>

429  unsigned i

= find_super_block(rank);

451  unsigned

row_idx = sblock_row_idx_[

i

+1];

452  const unsigned

*

row

= block_matr_.row(row_idx);

463 template

<

typename

BVAlloc>

466  if

(nb >= total_blocks_)

470  size_type

sb_count = get_super_block_count(

i

);

480  return

(aux0 << 32) | (aux1 << 48) | (second << 16) |

first

;

483  unsigned

row_idx = sblock_row_idx_[

i

+1];

484  const bm::id64_t

* sub_row = sub_block_matr_.row(row_idx);

491 template

<

typename

BVAlloc>

500  unsigned i

= find_super_block(*rank);

501  if

(

i

> max_sblock_)

546  unsigned

row_idx = sblock_row_idx_[

i

+1];

547  const unsigned

*

row

= block_matr_.row(row_idx);

555  const bm::id64_t

* sub_row = sub_block_matr_.row(row_idx);

556  unsigned first

= sub_row[j] & 0xFFFF;

557  unsigned

second = (sub_row[j] >> 16) & 0xFFFF;

585 template

<

typename

BVAlloc>

588  if

(

i

> max_sblock_)

590

sblock_count_[

i

+1] = sblock_count_[

i

];

591

sblock_row_idx_[

i

+1] = 0

U

;

596 template

<

typename

BVAlloc>

604 template

<

typename

BVAlloc>

607  if

(

i

> max_sblock_)

610

sblock_count_[

i

+1] = sblock_count_[

i

] + bcount;

613

sblock_row_idx_[

i

+1] = 0;

617

sblock_row_idx_[

i

+1] = sblock_rows_;

624 template

<

typename

BVAlloc>

627  if

(

i

> max_sblock_)

633  return

unsigned(

cnt

);

638 template

<

typename

BVAlloc>

642  if

(

i

> max_sblock_)

644  return

sblock_count_[

i

+1];

649 template

<

typename

BVAlloc>

665 template

<

typename

BVAlloc>

672  return

max_sblock_ + 1;

678 template

<

typename

BVAlloc>

687 template

<

typename

BVAlloc>

689  const unsigned

* bcount,

695  if

(

i

> max_sblock_)

699

sblock_row_idx_[

i

+1] = sblock_rows_;

700  unsigned

*

row

= block_matr_.row(sblock_rows_);

701  bm::id64_t

* sub_row = sub_block_matr_.row(sblock_rows_);

709

sub_row[j] = sub_count_in[j];

714

sblock_count_[

i

+1] = sblock_count_[

i

] + bc;

Rank-Select acceleration index.

sblock_count_vector_type sblock_count_

super-block accumulated counts

void init() BMNOEXCEPT

init arrays to zeros

bm::id64_t sub_count(block_idx_type nb) const BMNOEXCEPT

return sub-clock counts (64-bit for additional information)

size_type super_block_size() const BMNOEXCEPT

return number of super-blocks

unsigned get_super_block_count(unsigned i) const BMNOEXCEPT

return bit-count in super-block

bm::heap_vector< unsigned, bv_allocator_type, false > sblock_row_vector_type

bm::dynamic_heap_matrix< bm::id64_t, bv_allocator_type > blocks_matrix64_type

void set_super_block(unsigned i, size_type bcount) BMNOEXCEPT

set super block count

blocks_matrix_type block_matr_

blocks within super-blocks (matrix)

static unsigned find_sub_range(unsigned block_bit_pos) BMNOEXCEPT

determine the sub-range within a bit-block

size_type get_super_block_rcount(unsigned i) const BMNOEXCEPT

return running bit-count in super-block

bm::pair< bm::gap_word_t, bm::gap_word_t > sb_pair_type

bm::id_t sblock_count_type

size_type rcount(block_idx_type nb) const

return running bit-count for specified block

blocks_matrix64_type sub_block_matr_

sub-block counts

size_type count() const

return total bit-count for the index

void resize(block_idx_type new_size)

reserve the capacity for block count

unsigned find_super_block(size_type rank) const BMNOEXCEPT

Find super-block with specified rank.

void resize_effective_super_blocks(size_type sb_eff)

set size of true super-blocks (not NULL and not FFFFF)

bm::heap_vector< sblock_count_type, bv_allocator_type, false > sblock_count_vector_type

void set_full_super_block(unsigned i) BMNOEXCEPT

set FULL (all bits set super-block)

void copy_from(const rs_index &rsi)

copy rs index

bm::dynamic_heap_matrix< unsigned, bv_allocator_type > blocks_matrix_type

sblock_row_vector_type sblock_row_idx_

super-block row numbers

size_type total_blocks_

total bit-blocks in the index

bm::gap_word_t select_sub_range(block_idx_type nb, size_type &rank) const BMNOEXCEPT

determine block sub-range for rank search

size_type get_total() const

get total blocks

unsigned max_sblock_

max. superblock index

bool find(size_type *rank, block_idx_type *nb, bm::gap_word_t *sub_range) const

find block position and sub-range for the specified rank

void set_null_super_block(unsigned i) BMNOEXCEPT

set empty (no bits set super-block)

BVAlloc bv_allocator_type

void set_total(size_type t)

set total blocks

void register_super_block(unsigned i, const unsigned *bcount, const bm::id64_t *sub_count)

Add block list belonging to one super block.

static DLIST_TYPE *DLIST_NAME() first(DLIST_LIST_TYPE *list)

static DLIST_TYPE *DLIST_NAME() prev(DLIST_LIST_TYPE *list, DLIST_TYPE *item)

const unsigned set_array_mask

const unsigned set_block_mask

const unsigned set_sub_array_size

const unsigned rs3_half_span

void set_nibble(unsigned char *arr, unsigned idx, unsigned char v) noexcept

set nibble in the array

unsigned char get_nibble(const unsigned char *arr, unsigned idx) noexcept

get nibble from the array

unsigned long long int id64_t

const unsigned rs3_border0_1

const unsigned rs3_border1

unsigned lower_bound_u32(const unsigned *arr, unsigned target, unsigned from, unsigned to) noexcept

Hybrid, binary-linear lower bound search in unsigned array.

const unsigned set_array_shift

unsigned short gap_word_t

const unsigned rs3_border1_1

const unsigned rs3_border0

const unsigned gap_max_bits

unsigned lower_bound_u64(const unsigned long long *arr, unsigned long long target, unsigned from, unsigned to) noexcept

Hybrid, binary-linear lower bound search in unsigned LONG array.

double r(size_t dimension_, const Int4 *score_, const double *prob_, double theta_)

#define row(bind, expected)

const unsigned char _lut[65536]

Precalculated decision table fdr interval selection.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4