courses/machine_learning/deepdive/09_sequence/word2vec/word2vec.py
def _predict(self, analogy):
    """Predict the top 4 answers for analogy questions."""
    idx, = self._session.run([self._analogy_pred_idx], {
        self._analogy_a: analogy[:, 0],
        self._analogy_b: analogy[:, 1],
        self._analogy_c: analogy[:, 2]
    })
    return idx
Predict the top 4 answers for analogy questions.
Predict the top 4 answers for analogy questions.
Predict the top 4 answers for analogy questions .
def _predict(self, analogy):
    idx, = self._session.run([self._analogy_pred_idx], {
        self._analogy_a: analogy[:, 0],
        self._analogy_b: analogy[:, 1],
        self._analogy_c: analogy[:, 2]
    })
    return idx
def _predict ( self , analogy ) : idx , = self . _session . run ( [ self . _analogy_pred_idx ] , { self . _analogy_a : analogy [ : , 0 ] , self . _analogy_b : analogy [ : , 1 ] , self . _analogy_c : analogy [ : , 2 ] } ) return idx
Predict the top 4 answers for analogy questions.
Predict the top 4 answers for analogy questions .
"""Predict the top 4 answers for analogy questions."""
self
analogy