public static INDArray hardTanh(INDArray ndArray, boolean dup) {
    """
	Hard tanh
	
	@param ndArray the input
	@param dup     whether to duplicate the ndarray and return it as the result
	@return the output
    """
        return exec(dup ? new HardTanh(ndArray, ndArray.dup()) : new HardTanh(ndArray));
    }
public static INDArray hardTanh(INDArray ndArray, boolean dup) {
        return exec(dup ? new HardTanh(ndArray, ndArray.dup()) : new HardTanh(ndArray));
    }
public static INDArray hardTanh ( INDArray ndArray , boolean dup ) { return exec ( dup ? new HardTanh ( ndArray , ndArray . dup ( ) ) : new HardTanh ( ndArray ) ) ; }
Hard tanh

@param ndArray the input
@param dup     whether to duplicate the ndarray and return it as the result
@return the output
Hard tanh