mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-09-20 03:18:12 +08:00
* Introduce a config file to cellxgene The config file format is in yaml. The default config is located in server/common/default_config.py. A user may create a yaml file that contains a subset of these fields. It can be used during cellxgene launch, or for hosted cellxgene. The code has also been refactored. Much of the logic to check arguments has moved from launch to app config. It is now possible to set the tiledb context parameters using the config file. Other feature will soon be handled in a similar way.
68 lines
1.3 KiB
Python
68 lines
1.3 KiB
Python
import yaml
|
|
|
|
default_config = """
|
|
# cellxgene configuration
|
|
|
|
server:
|
|
verbose: false
|
|
debug: false
|
|
host: "127.0.0.1"
|
|
port : null
|
|
scripts : []
|
|
open_browser: false
|
|
|
|
presentation:
|
|
max_categories: 1000
|
|
|
|
multi_dataset:
|
|
dataroot: null
|
|
|
|
# The index page when in multi-dataset mode:
|
|
# false or null: this returns a 404 code
|
|
# true: loads a test index page, which links to the datasets that are available in the dataroot
|
|
# string/URL: redirect to this URL: flask.redirect(config.multi_dataset__index)
|
|
index: false
|
|
|
|
# A list of allowed matrix types. If an empty list, then all matrix types are allowed
|
|
allowed_matrix_types: []
|
|
|
|
single_dataset:
|
|
datapath: null
|
|
obs_names: null
|
|
var_names: null
|
|
about: null
|
|
title: null
|
|
|
|
user_annotations:
|
|
enable: true
|
|
type: local_file_csv
|
|
local_file_csv:
|
|
directory: null
|
|
file: null
|
|
ontology:
|
|
enable: false
|
|
obo_location: null
|
|
|
|
embeddings:
|
|
names : []
|
|
enable_reembedding: false
|
|
|
|
diffexp:
|
|
enable: true
|
|
lfc_cutoff: 0.01
|
|
|
|
adaptor:
|
|
cxg_adaptor:
|
|
tiledb_ctx:
|
|
sm.tile_cache_size: 8589934592
|
|
sm.num_reader_threads: 32
|
|
vfs.s3.region: us-east-1
|
|
|
|
anndata_adaptor:
|
|
backed: false
|
|
"""
|
|
|
|
|
|
def get_default_config():
|
|
return yaml.load(default_config, Loader=yaml.Loader)
|