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

Maybe a Bug #88

Open
QuarTerll opened this issue May 19, 2022 · 1 comment
Open

Maybe a Bug #88

QuarTerll opened this issue May 19, 2022 · 1 comment

Comments

@QuarTerll
Copy link

In train.py, between line 54 and 69,

ASL/train.py

Lines 54 to 69 in 7068ff0

val_dataset = CocoDetection(data_path_val,
instances_path_val,
transforms.Compose([
transforms.Resize((args.image_size, args.image_size)),
transforms.ToTensor(),
# normalize, # no need, toTensor does normalization
]))
train_dataset = CocoDetection(data_path_train,
instances_path_train,
transforms.Compose([
transforms.Resize((args.image_size, args.image_size)),
CutoutPIL(cutout_factor=0.5),
RandAugment(),
transforms.ToTensor(),
# normalize,
]))

It says that

#normalize, # no need, toTensor does normalization

I have different thought. To Tensor scales images to (0, 1) while normalization to (-1, 1).
This should be different.

I do not test for this. Please Check it.

Thank you. :)

@QuarTerll
Copy link
Author

And another question,

If so, why you guys don't use normalization?

The reason ask this is that my f1-score shows 10% differences at most when I use normalization with your code with ResNet50

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