我想使用Tensorflow来计算函数的梯度。但是,如果我使用tf.gradients函数,它会返回一个渐变列表。如何返回批次中每个点的列表?# in a tensorflow graph I have the following codetf_net #... conveniently defined neural network
tf_y = tf.p
我正在尝试使用TensorFlow的@tf.custom_gradient功能为具有多个输入的函数指定自定义渐变。我可以只为一个输入设置工作,但不能为两个或更多输入设置。train sess.run(tf.global_variables_initializer())ValueError: too many