Closed songmingl closed 9 months ago
https://github.com/Teichlab/celltypist/blob/dd7e6a5c7107a1a070389df7830cc215f89da66c/celltypist/classifier.py#L116
under prob match mode, some cells may be assigned to Unassigned, which is not present in probability_matrix. This will lead to a keyerror below:
prob match
Unassigned
probability_matrix
KeyError: 'Unassigned'
Maybe use the max probability or just return a nan for these unassigned labels?
nan
unassigned
@songmingl, thank you for pointing out this. Will fix this soon.
This should be solved in the new version (1.6.1). Please reopen the issue if you have further questions.
https://github.com/Teichlab/celltypist/blob/dd7e6a5c7107a1a070389df7830cc215f89da66c/celltypist/classifier.py#L116
under
prob match
mode, some cells may be assigned toUnassigned
, which is not present inprobability_matrix
. This will lead to a keyerror below:Maybe use the max probability or just return a
nan
for theseunassigned
labels?