Upload 2 files
Browse files- .gitattributes +1 -0
- MTCL.png +3 -0
- README.md +97 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
MTCL.png filter=lfs diff=lfs merge=lfs -text
|
MTCL.png
ADDED
|
Git LFS Details
|
README.md
ADDED
|
@@ -0,0 +1,97 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<h1 align="center">Multi-Level Transitional Contrast Learning for Personalized Image Aesthetics Assessment</h1>
|
| 2 |
+
|
| 3 |
+
<div align="center">
|
| 4 |
+
<a href="https://github.com/yzc-ippl/" target="_blank">Zhichao Yang</a><sup>1</sup>,
|
| 5 |
+
<a href="https://web.xidian.edu.cn/ldli/" target="_blank">Leida Li</a><sup>1*</sup>,
|
| 6 |
+
<a href="#" target="_blank">Yuzhe Yang</a><sup>2</sup>,
|
| 7 |
+
<a href="#" target="_blank">Yaqian Li</a><sup>2</sup>,
|
| 8 |
+
<a href="#" target="_blank">Weisi Lin</a><sup>3</sup>,
|
| 9 |
+
</div>
|
| 10 |
+
|
| 11 |
+
<div align="center">
|
| 12 |
+
<sup>1</sup>School of Artificial Intelligence, Xidian University
|
| 13 |
+
<br>
|
| 14 |
+
<sup>2</sup>OPPO Research Institute,
|
| 15 |
+
<sup>3</sup> School of Computer Science and Engineering, Nanyang Technological University
|
| 16 |
+
</div>
|
| 17 |
+
|
| 18 |
+
<div align="center">
|
| 19 |
+
<sup>*</sup>Corresponding author
|
| 20 |
+
</div>
|
| 21 |
+
|
| 22 |
+
<div align="center">
|
| 23 |
+
<img src="MTCL.png" width="800"/>
|
| 24 |
+
</div>
|
| 25 |
+
|
| 26 |
+
|
| 27 |
+
|
| 28 |
+
|
| 29 |
+
## IntroductionοΌ
|
| 30 |
+
### PyTorch implementation for the [paper](https://ieeexplore.ieee.org/abstract/document/10168279)
|
| 31 |
+
|
| 32 |
+
### Model weightοΌ[**(Hugging Face)**](https://huggingface.co/yzc002/MTCL) [**(Baidu Netdisk)**](https://pan.baidu.com/s/1wsb249NwjgaoPCBlHNRM1Q?pwd=0981)
|
| 33 |
+
|
| 34 |
+
## Inference GuideοΌ
|
| 35 |
+
|
| 36 |
+
### 1. Overview
|
| 37 |
+
This guide will help you get started with the MTCL inference code.
|
| 38 |
+
|
| 39 |
+
### 2. Model Architecture
|
| 40 |
+
|
| 41 |
+
MTCL consists of three main components:
|
| 42 |
+
```
|
| 43 |
+
**GIAA Model**: General Image Aesthetic Assessment backbone (ResNet-50 based)
|
| 44 |
+
**Contrast Model**: Contrastive learning encoder for personalized features
|
| 45 |
+
**PIAA Model**: Fusion of GIAA and Contrast features with personalized regression head
|
| 46 |
+
```
|
| 47 |
+
|
| 48 |
+
### 3. Directory Structure
|
| 49 |
+
```
|
| 50 |
+
project_root/
|
| 51 |
+
βββ code/
|
| 52 |
+
β βββ GIAA/
|
| 53 |
+
β β βββ train_GIAA_model.py # GIAA model definition
|
| 54 |
+
β βββ MTCL/
|
| 55 |
+
β β βββ Contrast_Database # Contrast data for training
|
| 56 |
+
β β βββ FlickrAES_TrainUser # Train user of FlickrAES
|
| 57 |
+
β β βββ train_Contrast_model.py # Contrast model definition
|
| 58 |
+
β βββ PIAA/
|
| 59 |
+
β βββ βββ FlickrAES_PIAA/
|
| 60 |
+
β βββ image/ # Flickr-AES images
|
| 61 |
+
β βββ label/
|
| 62 |
+
β βββ test_worker.csv # Test Worker information
|
| 63 |
+
β βββ image_labeled_by_each_worker.csv # Image ratings by workers
|
| 64 |
+
|
| 65 |
+
βββ test_PIAA_model.py # This inference script
|
| 66 |
+
```
|
| 67 |
+
|
| 68 |
+
### 4. Download Model Weight
|
| 69 |
+
Pre-trained PIAA Model: Place at
|
| 70 |
+
```
|
| 71 |
+
./model/ResNet50/ResNet50-FlickrAes-PIAA.pt
|
| 72 |
+
./model/ResNext101/ResNext101-FlickrAes-PIAA.pt
|
| 73 |
+
```
|
| 74 |
+
Flickr-AES Dataset:
|
| 75 |
+
```
|
| 76 |
+
Images: ./FlickerAes_PIAA/image/
|
| 77 |
+
Labels: ./FlickerAes_PIAA/label/
|
| 78 |
+
```
|
| 79 |
+
|
| 80 |
+
### 5. Running Inference
|
| 81 |
+
```
|
| 82 |
+
python test_PIAA_model.py
|
| 83 |
+
```
|
| 84 |
+
|
| 85 |
+
## Citation
|
| 86 |
+
If you find our work is useful, pleaes cite the paper:
|
| 87 |
+
```bibtex
|
| 88 |
+
@article{yang2023multi,
|
| 89 |
+
title={Multi-level transitional contrast learning for personalized image aesthetics assessment},
|
| 90 |
+
author={Yang, Zhichao and Li, Leida and Yang, Yuzhe and Li, Yaqian and Lin, Weisi},
|
| 91 |
+
journal={IEEE Transactions on Multimedia},
|
| 92 |
+
volume={26},
|
| 93 |
+
pages={1944--1956},
|
| 94 |
+
year={2023},
|
| 95 |
+
publisher={IEEE}
|
| 96 |
+
}
|
| 97 |
+
```
|