Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
small updates on readme and typos
Browse files Browse the repository at this point in the history
  • Loading branch information
chentingpc committed Dec 1, 2021
1 parent dec99a8 commit 2fc637b
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 6 deletions.
14 changes: 11 additions & 3 deletions colabs/intriguing_properties/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
## Intriguing Properties of Contrastive Losses

This folder contains code for "Intriguing Properties of Contrastive Losses".
This folder contains code for the paper titled [Intriguing Properties of Contrastive Losses](https://arxiv.org/abs/2011.02803). And here is the [link](https://contrastive-learning.github.io/intriguing/) to its website/blog.

```
@article{chen2021intriguing,
title={Intriguing Properties of Contrastive Losses},
author={Chen, Ting and Luo, Calvin and Li, Lala},
journal={Advances in Neural Information Processing Systems},
volume={34},
year={2021}
}
```

Technical report: [arxiv](https://arxiv.org/abs/2011.02803).

The slides: [Google slides](https://docs.google.com/presentation/d/1nnXuqFGED-8BemqNeatbd15IIsz2naRMoQsTuTzLYqw/edit?usp=sharing).
2 changes: 1 addition & 1 deletion data_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ def center_crop(image, height, width, crop_proportion):
image_height = shape[0]
image_width = shape[1]
crop_height, crop_width = _compute_crop_shape(
image_height, image_width, height / width, crop_proportion)
image_height, image_width, width / height, crop_proportion)
offset_height = ((image_height - crop_height) + 1) // 2
offset_width = ((image_width - crop_width) + 1) // 2
image = tf.image.crop_to_bounding_box(
Expand Down
2 changes: 1 addition & 1 deletion model.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def model_fn(features, labels, mode, params=None):
# Finetune just supervised (linear) head will not update BN stats.
model_train_mode = False
else:
# Pretrain or finetuen anything else will update BN stats.
# Pretrain or finetune anything else will update BN stats.
model_train_mode = is_training
hiddens = model(features, is_training=model_train_mode)

Expand Down
2 changes: 1 addition & 1 deletion tf2/data_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ def center_crop(image, height, width, crop_proportion):
image_height = shape[0]
image_width = shape[1]
crop_height, crop_width = _compute_crop_shape(
image_height, image_width, height / width, crop_proportion)
image_height, image_width, width / height, crop_proportion)
offset_height = ((image_height - crop_height) + 1) // 2
offset_width = ((image_width - crop_width) + 1) // 2
image = tf.image.crop_to_bounding_box(
Expand Down

0 comments on commit 2fc637b

Please sign in to comment.