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

Generalization to unseen categories #42

Open
rvinas opened this issue Feb 21, 2024 · 0 comments
Open

Generalization to unseen categories #42

rvinas opened this issue Feb 21, 2024 · 0 comments

Comments

@rvinas
Copy link

rvinas commented Feb 21, 2024

In the context transfer tutorial (predicting perturbation responses for unseen cell-types), the train set contains the OOD cell-type (B cell):

OOD split

(adata[adata.obs['split_B'] == 'ood'].obs['cell_type'].values == 'B').sum()
# Prints 774

Train split

(adata[adata.obs['split_B'] == 'train'].obs['cell_type'].values == 'B').sum()
# Prints 543

I am interested in the scenario where certain conditions are not available at train time. When I do inference on unseen conditions using a trained CPA model, I get the following error:

ValueError: Category CATEGORY_NAME not found in source registry. Cannot transfer setup without `extend_categories = True`.

How can I set up CPA to generalize to unseen categories?

@rvinas rvinas changed the title Generalization to unseen conditions Generalization to unseen categories Feb 21, 2024
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