mantispy.settings.override#

settings.override(*, cache_dir=<no change>, stream_bytes=<no change>, map_table_bytes=<no change>)#

Provides local override via keyword arguments as a context manager.

Parameters:
cache_dir Path (default: <no change>)

Where mantispy.ds keeps the datasets it downloads.

stream_bytes int (default: <no change>)

How many bytes of a matrix that is not in memory a grouped operation reads at once.

The default is a sixteenth of the machine’s memory, between 256 MB and 4 GB. Groups are packed into reads of about this size, and a group larger than that is read a block of columns at a time, so a smaller value lowers the peak memory and a larger one reads the file in fewer passes. mantispy.io.read() with lazy=True also sizes its chunks so that one per dask worker fits in this many bytes. It must be positive.

map_table_bytes int (default: <no change>)

How many bytes of sorted similarities and ranks the permutation null of mantispy.tl.map() may hold.

The default is half of the machine’s memory. The null refuses a screen whose sorted similarities would exceed it. When a table of each similarity’s rank fits beside them, the draws read the ranks, which is faster; otherwise they search the sorted similarities and give the same p-values.

Return type:

AbstractContextManager[None]