INNER CODE UNIT · Python
n_sample
BigDataBiology/SemiBin · SemiBin/main.py:1170
n_sample = (data.shape[1] - 136) // 2 if not is_combined else (data.shape[1] - 136)
else:
is_combined = False
n_sample = 1
depth_metabat2 = pd.read_csv(depth_metabat2, sep='\t')
depth_metabat2.set_index(['contigName'], inplace=True)
depth_metabat2.drop(['contigLen', 'totalAvgDepth'], axis=1, inplace=True)
depth_metabat2.index.name = None
data = pd.merge(data, depth_metabat2, how='inner', on=None,
left_index=True, right_index=True, sort=False)
if data.shape[1] != 138:
logger.error(
"Depth file from Metabat2 can only be used for single-sample binning!")
sys.exit(1)
model_path = model_path if environment is None else get_model_path(environment)
if environment is not None:
if data.shape[1] != 138: