TypeError: Only integers, slices (`:`), ellipsis (`...`), tf.newaxis (`None`) and scalar tf.int32/tf.int64 tensors are valid indices
franck-allou opened this issue · comments
franck-allou commented
Hi, I would like you to help and fix my problem. I'm using python 3.7 with tensorflow 2.0
def dist_pair(self, pair_ixd):
return tf.compat.v1.losses.absolute_difference(self.h[:, 2*pair_ixd, :], self.h[:, 2*pair_ixd+1, :])
TypeError: Only integers, slices (:
), ellipsis (...
), tf.newaxis (None
) and scalar tf.int32/tf.int64 tensors are valid indices