Home
last modified time | relevance | path

Searched refs:np_matrix (Results 1 – 3 of 3) sorted by relevance

/external/tensorflow/tensorflow/contrib/factorization/python/ops/
Dfactorization_ops_test_utils.py40 def remove_empty_rows_columns(np_matrix): argument
54 nz_row_ids = np.where(np.sum(np_matrix, axis=1) != 0)[0]
55 nz_col_ids = np.where(np.sum(np_matrix, axis=0) != 0)[0]
56 mat = np_matrix[np.ix_(nz_row_ids, nz_col_ids)]
60 def np_matrix_to_tf_sparse(np_matrix, argument
66 indices = np.nonzero(np_matrix)
91 val = np_matrix[indices].astype(np.float32)
Dwals_test.py82 def input_fn(self, np_matrix, batch_size, mode, argument
122 np_matrix, nz_row_ids, nz_col_ids = (
123 factorization_ops_test_utils.remove_empty_rows_columns(np_matrix))
125 nz_row_ids = np.arange(np.shape(np_matrix)[0])
126 nz_col_ids = np.arange(np.shape(np_matrix)[1])
142 num_rows = np.shape(np_matrix)[0]
143 num_cols = np.shape(np_matrix)[1]
146 sp_mat = self.np_array_to_sparse(np_matrix)
260 input_fn = self.input_fn(np_matrix=self.input_matrix,
271 input_fn = self.input_fn(np_matrix=self.input_matrix,
[all …]
/external/tensorflow/tensorflow/contrib/losses/python/metric_learning/
Dmetric_loss_ops_test.py199 def convert_to_list_of_sparse_tensor(np_matrix): argument
201 nrows, ncols = np_matrix.shape
205 if np_matrix[i][j] == 1: