tiledbsoma.open

tiledbsoma.open(uri: str, mode: Literal['r', 'w'] = 'r', *, soma_type: str | None = None, context: SOMATileDBContext | None = None, tiledb_timestamp: int | datetime | None = None) TileDBObject[Wrapper[Array | Group | SOMAArray | SOMADataFrame | SOMASparseNDArray | SOMADenseNDArray]]
tiledbsoma.open(uri: str, mode: Literal['r', 'w'], *, soma_type: Type[_Obj], context: SOMATileDBContext | None = None, tiledb_timestamp: int | datetime | None = None) _Obj

Opens a TileDB SOMA object.

Parameters:
  • uri – The URI to open.

  • mode – The mode to open in: r to read (default), w to write.

  • soma_type – If set, the SOMA class you are expecting to get back. This can be provided as a SOMA type name. If the stored SOMA object is not of the correct type, an error will be raised.

  • context – If set, the SOMATileDBContext data to use.

  • tiledb_timestamp – If specified, overrides the default timestamp used to open this object. If unset, uses the timestamp provided by the context.

Returns:

The TileDB SOMA object.

Raises:
  • DoesNotExistError – If the object named by URI can not be accessed.

  • SOMAError – If the underlying TileDB object specified by uri is not recognized as a SOMA object.

  • TypeError – If the opened SOMA object type does not match the user- specified soma_type parameter.

  • TypeError – If the user-provided soma_type parameter is not a recognizable type name or value.

  • ValueError – If the user-provided mode is invalid.

Lifecycle

Experimental.