Environment:Huggingface Datasets Lance Dependencies
| Knowledge Sources | |
|---|---|
| Domains | Data_Loading, Vector_Database |
| Last Updated | 2026-02-14 18:00 GMT |
Overview
Optional dependency on the pylance (Lance) library for reading datasets stored in the Lance columnar format, a modern format optimized for machine learning workloads with vector data.
Description
The Lance packaged module builder (src/datasets/packaged_modules/lance/lance.py) requires the lance Python package (installed via pip install pylance) to read Lance datasets and standalone Lance files. The lance module provides lance.dataset() for opening Lance datasets with transaction/version management, and lance.file.LanceFileReader for reading individual Lance files. This is an optional dependency listed under the tests_require section of setup.py.
Dependency Details
| Package | Import Name | Version | Install Command | Required By |
|---|---|---|---|---|
| pylance | lance, lance.file |
(no minimum specified) | pip install pylance |
Lance packaged module builder |
Detection
The lance import is performed at the module level inside a try/except block. If lance is not installed, the builder will fail at runtime when attempting to load a Lance format dataset.