shichence / autoint Goto Github PK
View Code? Open in Web Editor NEWImplementation of AutoInt: Automatic Feature Interaction Learning via Self-Attentive Neural Networks
License: MIT License
Implementation of AutoInt: Automatic Feature Interaction Learning via Self-Attentive Neural Networks
License: MIT License
As mentioned in README.md
https://github.com/shichence/AutoInt/blob/master/README.md#input-format:
In what case the categorical feature will NOT be 1? Thanks!
In the example:
python -u train.py \
--data "Criteo" --blocks 3 --heads 2 --block_shape "[64, 64, 64]" \
--is_save "True" --save_path "./test_code/Criteo/b3h2_64x64x64/" \
--field_size 39 --run_times 1 --data_path "./" \
--epoch 3 --has_residual "True" --has_wide "False" \
--batch_size 128 \
> test_code_single.out &
And default embedding size is 16.
So according to the code:
def multihead_attention():
...
Q = tf.layers.dense(queries, num_units, activation=tf.nn.relu)
K = tf.layers.dense(keys, num_units, activation=tf.nn.relu)
V = tf.layers.dense(values, num_units, activation=tf.nn.relu)
if has_residual:
V_res = tf.layers.dense(values, num_units, activation=tf.nn.relu)
# Split and concat
Q_ = tf.concat(tf.split(Q, num_heads, axis=2), axis=0)
K_ = tf.concat(tf.split(K, num_heads, axis=2), axis=0)
V_ = tf.concat(tf.split(V, num_heads, axis=2), axis=0)
...
The num_units is 64 and num_heads is 2, it seems that the embedding size is 32 but not 16. I confused about it.
Could you please share us all the parameters used for avazu and criteo? Thanks!
Hi, can you share code for preprocessing dataset Movielens?
train according to the procedure:
mkdir Criteo
python ./Dataprocess/Criteo/preprocess.py
python ./Dataprocess/Kfold_split/stratifiedKfold.py
python ./Dataprocess/Criteo/scale.py
Here's how to run the training.
python -u train.py \
--data "Criteo" --blocks 3 --heads 2 --block_shape "[64, 64, 64]" \
--is_save "True" --save_path "./test_code/Criteo/b3h2_64x64x64/" \
--field_size 39 --run_times 1 --data_path "./" \
--epoch 3 --has_residual "True" --has_wide "False" \
--batch_size 1024 \
> test_code_single.out &
but the result is not same with the example:
train logs
...
start testing!...
restored from ./test_code/Criteo/b3h2_dnn_dropkeep1_400x2/1/
test-result = 0.8088, test-logloss = 0.4430
test_auc [0.8088305055534442]
test_log_loss [0.44297631300399626]
avg_auc 0.8088305055534442
avg_log_loss 0.44297631300399626
my result is :
start testing!...
restored from ./test_code/Criteo/b3h2_64x64x64/1/
test-result = 0.5263, test-logloss = 0.5751
test_auc [0.5262644664774784]
test_log_loss [0.5751133874248523]
avg_auc 0.5262644664774784
avg_log_loss 0.5751133874248523
In your paper, the threshold is set to {10, 5, 10} for Criteo, Avazu and KDD12
And in your code( AutoInt/Dataprocess/Criteo/preprocess.py line.33.36), the threshold is 11
There is nothing wrong with Avazu and KDD12, but how does Criteo explain
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.