Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mountchicken/imagecaptioning-attention-pyqt5

ImageCaptioning improved with an attention mechanism. Also a PyQt5 application
https://github.com/mountchicken/imagecaptioning-attention-pyqt5

attention imagecaptioning pyqt5 pytorch

Last synced: 18 days ago
JSON representation

ImageCaptioning improved with an attention mechanism. Also a PyQt5 application

Awesome Lists containing this project

README

        

# ImageCaptioning-Attention-PyQt5
ImageCaptioning improved with attention. Also a PyQt5 applications

# Welcome !
- Hello guys, hope you are doing awesome these days !๐Ÿ˜„
- In my previous ImageCaption repository, I implemented a ImageCaption algorithm and I promised to upload an attention based version latter. And here it is ๏ผ๐Ÿ˜„
- Using the `ResNet50` pretrained on ImageNet as the backbone(no finetune) and also some attention, the model can describe image like human(most of the time).
- Moreover,`Beam Search` are also used during the inferrence part and this give another great improvment on the model's performence
- Now, let's enjoy some funny stuff๐Ÿ˜Ž

# 1.Examples๐Ÿ‘
## โ‘ .doggy doggy, juicy doggy
- ๐Ÿ˜€

## โ‘ข.You don't want to mess up with No. 1 shooter in the west
- ๐Ÿ˜€

## โ‘ฃ.๐ŸŒถโ‘ฃ๐Ÿ’‰๐Ÿ’ง๐Ÿฎ๐Ÿบ
- ๐Ÿ˜€

## โ‘ค.Portland Timbers, Assemble!
- ๐Ÿ˜€

## โ‘ฅ.mountchicken must has something to do with mountain
- ๐Ÿ˜€


# 2.Requirements
- skimage
- spacy
- PyQt5
- Pip install them

# 3.Train๐Ÿ˜ฃ
## download flickr30k
- Download the flickr30k dataset, unpack all the images into the folder `flickr30k/flickr30k-images`. I have already preprocessed the captions.txt, and you don't need to download that
- [flickr(ๆๅ–็ :hrf3)](https://pan.baidu.com/s/1r0RVUwctJsI0iNuVXHQ6kA)
## download my checkpoint(if you don't want to train it with 14h on GeForce2080ti)
- Put the downloaded checkpoint into the folder `checkpoint`
- [checkpoint(ๆๅ–็ :qny4)](https://pan.baidu.com/s/189u5i5vZbzIp9r4XoEYn6A)
## change some parameters
- `train.py` line20 - line26, set the dataset path
- `train.py` line31 - line34, `load_model`:load my checkpoint or not.
- Ok, you can train now

# 4.Inferrence๐Ÿ˜€
- `inferrence.py` line245, choose your predict image path

# 5.APP

## Run main_gui.py
### if you run the .py file succesfully, it should look like this
- ๐Ÿ˜€

### Then, you need to push the initialize button to load the model, after that, just wait the `Finished` sign appers in the right.
- ๐Ÿ˜€

### Finally, load the image with `Load Image` button and press `Detect`
- ๐Ÿ˜€

# For more issue, contact me
- `Email Address` [email protected]