Open
Conversation
… and 3) refactor & documentation.
chihming
reviewed
Nov 7, 2017
|
|
||
| // vertex vector, context vector, vertex, context, dimension, negative samples, alpha | ||
| void UpdateVertex(vector< vector<double> >&, vector< vector<double> >&, long, long, int, int, double); | ||
| void UpdateContext(vector< vector<double> >&, vector< vector<double> >&, long, long, int, int, double); |
Collaborator
There was a problem hiding this comment.
not used in the program?
chihming
reviewed
Nov 7, 2017
ICE/ICE.cpp
Outdated
| vvnet.UpdatePair(w_vertex, w_context, v1, v2, dim, negative_samples, _alpha); | ||
| } | ||
| else{ | ||
| if (v1 >= vocab_count){ |
Collaborator
There was a problem hiding this comment.
if (v1 >= vocab_count)
what's the function of this condition? (you wanna sample a node with an offset vocab_count? if yes, I think we can use "v1+vocab_count" instead)
Collaborator
|
so now we change the default version to "train stage 1 and then to train stage 2" ? or we'll have an option to do this? |
Collaborator
Author
|
Unified training method, as oppose to the 2-stage training method, can be achieved via provide the complete ICE network to the 1st stage of the latter. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added 1) weighted option: '-w' default=0, 0 uses binary weight and 1 uses real weights
2) Save ET and TT of ICE separately: Allows to save the full ICE network or its ET and TT subnetwork.
3) Refactor & documentation: Put codes into functions and added comments.
Program tested on sample code (unweighted) and self-defined weighted matrix.