def _dense_to_one_hot(labels_dense, num_classes):
  num_labels = labels_dense.shape[0]
  index_offset = np.arange(num_labels) * num_classes
  labels_one_hot = np.zeros((num_labels, num_classes))
  labels_one_hot.flat[index_offset + labels_dense.ravel()] = 1
  print(labels_one_hot[0])
  return labels_one_hot
Request the specified field from the OpenID user
dataset/ETHPy150Open HamedMP/ImageFlow/example_project/input_data.py/_dense_to_one_hot--crossover with--dataset/ETHPy150Open CollabQ/CollabQ/openid/extensions/sreg.py/SRegRequest.requestField