Open
Description
Should we extend the code generation for ops to automatically generate convenience overloads? This would help reduce the gap between Python notation and Java notation.
As an example of where we stand now, here's some Python code (keras/metrics.py, around line 2203):
dp = p[:self.num_thresholds - 1] - p[1:]
And here's the corresponding Java code (AUC.java, around line 809):
Operand<T> dP =
tf.math.sub(
tf.slice(
p, tf.constant(new int[] {0}), tf.constant(new int[] {getNumThresholds() - 1})),
tf.slice(p, tf.constant(new int[] {1}), tf.constant(new int[] {-1})));
Metadata
Metadata
Assignees
Labels
No labels