pedro-morgado / score-zeroshot Goto Github PK
View Code? Open in Web Editor NEWSemantically consistent regularizer for zero-shot learning
License: Other
Semantically consistent regularizer for zero-shot learning
License: Other
Hello!
Thank you for making the code for this project public.
I would have one question: are the embeddings in Codes_Wiki_W2V_X_Y.txt
ordered according to the classes in classes.txt
?
When I tried to train GoogLeNet (fine-tuning) on CUB dataset with attributes, it did not converge. I just followed hyperparameters in SCoRe paper and this github code. The hyperparameters are as follows.
python score_train.py G_Attr CUB Attributes GoogLeNet -g 0.01 -c 1.0 --iters 700 --gpu 0 --init_lr 0.0005 --snapshot ./G_Attr/inception_v1.caffemodel |& tee ./G_Attr/train_G_Attr.log
test_iter: 20
test_iter: 20
test_interval: 100
base_lr: 0.0005
display: 20
max_iter: 700
lr_policy: "fixed"
momentum: 0.9
weight_decay: 0.0005
snapshot: 5000
I trained on Ubuntu 16.04 with GTX 1080 Ti, CUDA 8.0, and cuDNN v7.
Could you give me any hints for convergence?
Results:
I1222 15:54:06.236789 26844 solver.cpp:397] Test net output #0: SCoRe/eval/obj/accuracy = 0.0210938
I1222 15:54:06.388346 26844 solver.cpp:218] Iteration 700 (3.90624 iter/s, 5.12002s/20 iters), loss = 5.02677
I1222 15:54:06.394364 26844 solver.cpp:237] Train net output #0: SCoRe/cwReg = 0.0053981 (* 1 = 0.0053981 loss)
I1222 15:54:06.394374 26844 solver.cpp:237] Train net output 1: SCoRe/eval/obj/accuracy = 0
I1222 15:54:06.394381 26844 solver.cpp:237] Train net output 2: SCoRe/objLoss = 5.02252 (* 0.990099 = 4.9728 loss)
I1222 15:54:06.394387 26844 solver.cpp:237] Train net output #3: SCoRe/semLoss = 216.479 (* 0.000224393 = 0.0485763 loss)
I1222 15:54:06.394403 26844 sgd_solver.cpp:105] Iteration 700, lr = 0.0005
I carry out train_eval_CUB.sh use linux,inception_v1.caffemodel. When carry out to
python score_eval.py ${MODEL_DIR} CUB Attributes GoogLeNet
I meet this problem and i can't slove it.
Layer SCoRe/obj/fc_target (weights) initialized
Traceback (most recent call last):
File "score_eval.py", line 139, in
main(parse_cmd())
File "score_eval.py", line 134, in main
mca, acc, semAcc, semAUC = evaluate_model(classes, constrains, LMDBs, args)
File "score_eval.py", line 111, in evaluate_model
semAcc[mode], semAUC[mode] = eval_semantics(scores, semantics, args)
File "score_eval.py", line 50, in eval_semantics
acc[s] = (pred*(lbl-0.5) > 0).astype(float).mean()
ValueError: operands could not be broadcast together with shapes (10,) (2933,)
Can you give me some suggestion?
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.