# Path: scib/utils.py
# def check_batch(batch, obs, verbose=False):
#     if batch not in obs:
#         raise ValueError(f'column {batch} is not in obs')
#     elif verbose:
#         print(f'Object contains {obs[batch].nunique()} batches.')
# 
# Path: scib/metrics/utils.py
# class RootCellError(Exception):
#     def __init__(self, message):
#         self.message = message


import numpy as np
import pandas as pd
import scanpy as sc
from scipy.sparse.csgraph import connected_components
from ..utils import check_batch
from .utils import RootCellError



def get_root(
        adata_pre,
        adata_post,

# Path: scib/utils.py
# def check_batch(batch, obs, verbose=False):
#     if batch not in obs:
#         raise ValueError(f'column {batch} is not in obs')
#     elif verbose:
#         print(f'Object contains {obs[batch].nunique()} batches.')
# 
# Path: scib/metrics/utils.py
# class RootCellError(Exception):
#     def __init__(self, message):
#         self.message = message


# Path: scib/metrics/trajectory.py
import numpy as np
import pandas as pd
import scanpy as sc
from scipy.sparse.csgraph import connected_components
from ..utils import check_batch
from .utils import RootCellError




def get_root(
        adata_pre,
        adata_post,

        ct_key,