Git Product home page Git Product logo

interaction-aware-attention-network's Introduction

Interaction-aware Attention Network

Model Overview

Screen Shot 2019-10-21 at 5 11 24 PM

Data:

Data disciptions of IEMOCAP please refer to here.

Requirements

Some required libraries:

python                   >=3.6   
tensorflow-gpu           1.11.0
joblib   		 0.13.0
pandas                   0.22.0
scikit-learn             0.19.1
numpy			 1.15.3

Code:

codes descriptions
data.py Includes batch generator & data generator.
model.py main codes.
hyparams.py hyperparameters
script_train.py testing scripts
script_test.py training scripts

To evaluate under realistic scenarios of our model, we adopt leave-one-session-out cross validation.

Run:

For feature pooling to reduce computational cost:

python3 pool_feats.py --input_file INPUT_FILE --output_file OUTPUT_FILE --feat_dim FEAT_DIM --step STEP --max_size MAX_SIZE

For training:

python3 script_train.py --seq_dim SEQ_DIM \
                        --atten_size ATTEN_SIZE \
                        --batch_size BATCH_SIZE \
                        --model_dir MODEL_DIR \
                        --record_file outputs/RECORD_FILE.json \
                        --feat_dir data/XXX.pkl

For testing

python3 script_test.py  --result_file outputs/RECORD_FILE.json --feat_dir data/XXX.pkl

I include whole process and hyperparameters in a script:

sh run.sh

Citation

@inproceedings{yeh2019interaction,
  title={An interaction-aware attention network for speech emotion recognition in spoken dialogs},
  author={Yeh, Sung-Lin and Lin, Yun-Shao and Lee, Chi-Chun},
  booktitle={ICASSP 2019-2019 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP)},
  pages={6685--6689},
  year={2019},
  organization={IEEE}
}

interaction-aware-attention-network's People

Contributors

30stomercury avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

interaction-aware-attention-network's Issues

script arguments outdated

When running
python3 script_train.py -lr 0.0001 -batch_size 64 -keep_proba 0.9 -seq_dim 512 -save_path ./model/iaan/ > out.txt

I get
script_train.py: error: unrecognized arguments: -save_path ./model/iaan/

Is there a new version of the script that is not commited?

Thanks

Performance comparison with original paper

Thanks very much for the implementation @30stomercury ! It is great!

Am I right that currently there is no evaluation on a validation set during training, thus why no early stopping is used for training? There is a fixed training steps (e.g. 2000 steps).

Have you managed to replicate the results reported in the original paper? I have only been able to get 55.4 in UAR, which is far lower than what they have reported:

[[115  26  26   3]
 [ 74 149 172  47]
 [ 27  31 255  71]
 [ 15  36  49 145]]
Ave test acc: 0.535, Ave test uar: 0.567
ave uar over all data: 0.5547344560992651

Thanks again!

Question about model.py

In the model.py file, I find a problem.It is the code:
"paddings = (mask_att)*(-1e8)
vu = tf.where(tf.equal(mask_att, 0), paddings, vu)"
I think the "paddings" is no useful,in other words,it doesn't work.Because "mask_att" variable is a matrix about "0" and "1", "paddings" variable is 0 in where "mask_att" is 0, -1e8 where "mask_att" is 1.Then variable "vu" equal to
"vu = tf.where(tf.equal(mask_att, 0), mask_att, vu)"

IEMOCAP

Is there a script that helps select utterances of 4 emotions from IEMOCAP dataset?

default='./model/iaan/'

Parser. Add_argument ('--model_dir', dest='model_dir', default='./model/iaan/', type= STR) Model/IaAN file is not available, how to generate it?

missing feat_pooled.pkl

Hi! Thanks for sharing this code.

I was able to run the preprocess.py and extractSmile.py scripts on the data folder.
Then, I'm having some trouble running the script_train.py script since I don't know how to generate the "feat_pooled.pkl".

I've seen that you name data.py to have a function to generate those, but I don't know how to use it.

Is there a missing script? Or am I missing something?

Thanks a lot

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.