Skip to content

Commit

Permalink
use c++ shape calc for Linspace
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Nett <rnett@skymind.io>
  • Loading branch information
Ryan Nett committed Aug 22, 2019
1 parent 0d2f6bd commit 703de77
Showing 1 changed file with 0 additions and 8 deletions.
Expand Up @@ -82,12 +82,4 @@ public void initFromTensorFlow(NodeDef nodeDef, SameDiff initWith, Map<String, A
public List<SDVariable> doDiff(List<SDVariable> gradients){
return Arrays.asList(f().zerosLike(arg(0)), f().zerosLike(arg(1)), f().zerosLike(arg(2)));
}

@Override
public List<LongShapeDescriptor> calculateOutputShape(){
INDArray l = arg(2).getArr();
if(l == null)
return Collections.emptyList();
return Collections.singletonList(LongShapeDescriptor.fromShape(new long[]{l.getLong(0)}, dataType));
}
}

0 comments on commit 703de77

Please sign in to comment.