TorchDenseIndexer

class lightning_ir.retrieve.pytorch.dense_indexer.TorchDenseIndexer(index_dir: Path, index_config: TorchDenseIndexConfig, module: BiEncoderModule, verbose: bool = False)[source]

Bases: Indexer

__init__(index_dir: Path, index_config: TorchDenseIndexConfig, module: BiEncoderModule, verbose: bool = False) None[source]

Methods

__init__(index_dir, index_config, module[, ...])

add(index_batch, output)

save()

to_cpu()

to_gpu()