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

leak test data infromation #2

Closed
libo-huang opened this issue May 9, 2023 · 1 comment
Closed

leak test data infromation #2

libo-huang opened this issue May 9, 2023 · 1 comment

Comments

@libo-huang
Copy link

It seems to take the groud truth features from all test data.

In your AdaNPC, you take all the test data with ground truth labels (e.g., the name with out datasets) as the prototypes for inference.

if 'AdaNPC' in args.adapt_algorithm and str(args.test_envs[0]) not in name:
adapted_algorithm.classifier.extend_test(z.to(device), y.to(device))

Officially, the condition and 'out' not in name should be added to avoid such leakage of test-data information.

if 'KNN' in args.adapt_algorithm and str(args.test_envs[0]) not in name and 'out' not in name:
adapted_algorithm.classifier.extend_test(z.to(device), y.to(device))

@yfzhang114
Copy link
Owner

Thanks for your interest. out datasets are a part of source domains, hence the target domain data will not be leaked.

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

2 participants