Dataset Viewer
Auto-converted to Parquet
The dataset viewer is taking too long to fetch the data. Try to refresh this page.
Server-side error
Error code:   ClientConnectionError

Blood-Brain Barrier Database (B3DB)

The Blood-Brain Barrier Database (B3DB) is a large benchmark dataset compiled from 50 published resources (as summarized at raw_data/raw_data_summary.tsv) and categorized based on the consistency between different experimental references/measurements. This dataset was published in Scientific Data and a mirror of the theochem/B3DB the official Github repo where it is occasionally uploaded with new experimental data. We used the original datasets uploaded in 2023 (regression datasets) and 2021 (classification datasets). Scientists who would like to contribute data should contact the database's maintainers (e.g., by creating a new Issue in the database).

A subset of the molecules in B3DB has numerical logBB values (1058 compounds), while the whole dataset has categorical (BBB+ or BBB-) BBB permeability labels (7807 compounds). Some physicochemical properties of the molecules are also provided.

Quickstart Usage

Load a dataset in python

Each subset can be loaded into python using the Huggingface datasets library. First, from the command line install the datasets library

$ pip install datasets

then, from within python load the datasets library

>>> import datasets

and load one of the B3DB datasets, e.g.,

>>> B3DB_classification = datasets.load_dataset("maomlab/B3DB", name = "B3DB_classification")
Downloading readme: 100%|████████████████████████| 4.40k/4.40k [00:00<00:00, 1.35MB/s]
Downloading data: 100%|██████████████████████████| 680k/680k [00:00<00:00, 946kB/s]
Downloading data: 100%|██████████████████████████| 2.11M/2.11M [00:01<00:00, 1.28MB/s]
Generating test split: 100%|█████████████████████| 1951/1951 [00:00<00:00, 20854.95 examples/s]
Generating train split: 100%|████████████████████| 5856/5856 [00:00<00:00, 144260.80 examples/s]

and inspecting the loaded dataset

>>> B3DB_classification
B3DB_classification
DatasetDict({
  test: Dataset({
     features: ['B3DB_classification_index', 'compound_name', 'IUPAC_name', 'SMILES', 'CID', 'logBB', 'Y', 'Inchi', 'threshold', 'reference', 'group', 'comments', 'ClusterNo', 'MolCount'],
     num_rows: 1951
  })
  train: Dataset({
      features: ['B3DB_classification_index', 'compound_name', 'IUPAC_name', 'SMILES', 'CID', 'logBB', 'Y', 'Inchi', 'threshold', 'reference', 'group', 'comments', 'ClusterNo', 'MolCount'],
      num_rows: 5856
  })
})

Use a dataset to train a model

One way to use the dataset is through the MolFlux package developed by Exscientia. First, from the command line, install MolFlux library with catboost and rdkit support

pip install 'molflux[catboost,rdkit]'

then load, featurize, split, fit, and evaluate the a catboost model

import json
from datasets import load_dataset
from molflux.datasets import featurise_dataset
from molflux.features import load_from_dicts as load_representations_from_dicts
from molflux.splits import load_from_dict as load_split_from_dict
from molflux.modelzoo import load_from_dict as load_model_from_dict
from molflux.metrics import load_suite

split_dataset = load_dataset('maomlab/B3DB', name = 'B3DB_classification')

split_featurised_dataset = featurise_dataset(
  split_dataset,
  column = "SMILES",
  representations = load_representations_from_dicts([{"name": "morgan"}, {"name": "maccs_rdkit"}]))

model = load_model_from_dict({
    "name": "cat_boost_classifier",
    "config": {
        "x_features": ['SMILES::morgan', 'SMILES::maccs_rdkit'],
        "y_features": ['Y']}})

model.train(split_featurised_dataset["train"])
preds = model.predict(split_featurised_dataset["test"])

classification_suite = load_suite("classification")

scores = classification_suite.compute(
    references=split_featurised_dataset["test"]['Y'],
    predictions=preds["cat_boost_classifier::Y"])

About the DB3B

Features of B3DB

  1. The largest dataset with numerical and categorical values for Blood-Brain Barrier small molecules (to the best of our knowledge, as of February 25, 2021).

  2. Inclusion of stereochemistry information with isomeric SMILES with chiral specifications if available. Otherwise, canonical SMILES are used.

  3. Characterization of uncertainty of experimental measurements by grouping the collected molecular data records.

  4. Extended datasets for numerical and categorical data with precomputed physicochemical properties using mordred.

Data splits

The original B3DB dataset does not define splits, so here we have used the Realistic Split method described in (Martin et al., 2018).

Citation

Please use the following citation in any publication using our B3DB dataset:

@article{Meng_A_curated_diverse_2021,
author = {Meng, Fanwang and Xi, Yang and Huang, Jinfeng and Ayers, Paul W.},
doi = {10.1038/s41597-021-01069-5},
journal = {Scientific Data},
number = {289},
title = {A curated diverse molecular database of blood-brain barrier permeability with chemical descriptors},
volume = {8},
year = {2021},
url = {https://www.nature.com/articles/s41597-021-01069-5},
publisher = {Springer Nature}
}
Downloads last month
595

Collection including maomlab/B3DB