Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in [<-.data.frame(*tmp*, col, value = c("KC33_AAACCCAAGTAGTCAA", : replacement has 76211 rows, data has 694321 Calls: read_reference -> read_adata -> read_df -> [<- -> [<-.data.frame #221

Open
reinertanalytics opened this issue Nov 8, 2024 · 0 comments

Comments

@reinertanalytics
Copy link

Hello! I am trying to use RCTD on python via the TACCO package wrapper. I have been running across this error which I haven't been able to solve on the TACCO github / python side, and I am wondering if you would have any insight as to what is going on.

I run this command:
tc.tl.annotate(
adata,
reference,
method='RCTD',
conda_env="/opt/homebrew/Caskroom/miniconda/base/envs/tacco_env",
annotation_key='v2.subclass.l2',
result_key='v2.subclass.l2',
assume_valid_counts=True,
)

and I get this error:
Starting annotation of data with shape (65124, 300) and a reference of shape (694321, 300) using the following wrapped method:
+- multi center: multi_center=None multi_center_amplitudes=True
+- core: method=RCTD annotation_prior=None conda_env=/opt/homebrew/Caskroom/miniconda/base/envs/tacco_env
[1] "reference.h5ad" "data.h5ad" "result" "0"
[5] "14" "full" "v2.subclass.l2" "x"
[9] "y" "158.0"
[1] "reading data"
[1] "csr"
[1] "reading reference"
[1] "csr"

Attaching package: ‘SparseM’

The following object is masked from ‘package:Matrix’:

det

Error in [<-.data.frame(*tmp*, col, value = c("KC33_AAACCCAAGTAGTCAA", :
replacement has 76211 rows, data has 694321
Calls: read_reference -> read_adata -> read_df -> [<- -> [<-.data.frame
Execution halted

My reference object indeed has 694321 cells, but I'm not sure where the 76211 number is coming from. I have made sure that there are no NAs, all cells are unique, etc. I am using raw counts for both reference and adata (it is a xenium anndata object, one sample only). Any help would be greatly appreciated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant