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

CSC (class-specific context) CoOp/CoCoOp in "base-new" and "cross-dataset". #69

Open
galaxyzen opened this issue Nov 8, 2023 · 0 comments

Comments

@galaxyzen
Copy link

galaxyzen commented Nov 8, 2023

CSC (class-specific context) will generate context for every class:

  # CoOp.py
  # random initialization
  if cfg.TRAINER.COOP.CSC:
      print("Initializing class-specific contexts")
      ctx_vectors = torch.empty(n_cls, n_ctx, ctx_dim, dtype=dtype)
  1. If I train the model with the setting cfg.TRAINER.COOP.CSC on a dataset which has 10 classes, can I eval this model on another dataset which may have 11 classes? I think the setting cfg.TRAINER.COOP.CSC causes the model is specific to n_cls .
  2. If the cfg.TRAINER.COOP.CSC is turned on, I think the "base-new" experiment can't be conducted as well.
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