上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 72 下一页
摘要: x = {'a': 1, 'b': 2} y = {'b': 3, 'c': 4} z = {**x, **y} 输出结果 {'a': 1, 'b': 3, 'c': 4} 注意:如果key相同,第二个dict的item会覆盖第一个dict的item... 阅读全文
posted @ 2020-04-21 17:15 2021年的顺遂平安君 阅读(46) 评论(0) 推荐(0) 编辑
摘要: 官方说明: If both x and y are None, then this operation returns the coordinates of true elements of condition. The coordinates are r... 阅读全文
posted @ 2020-04-21 17:08 2021年的顺遂平安君 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 官方说明: If both x and y are None, then this operation returns the coordinates of true elements of condition. The coordinates are returned in a 2 D tenso 阅读全文
posted @ 2020-04-21 17:08 2021年的顺遂平安君 阅读(3868) 评论(0) 推荐(0) 编辑
摘要: 如果t是二维数组, 等价于 ;如果是三维数值, 等价于 。 和`np.newaxis`功能相同,都是增加维度。 阅读全文
posted @ 2020-04-21 15:26 2021年的顺遂平安君 阅读(1254) 评论(0) 推荐(0) 编辑
摘要: 如果t是二维数组,t[...,1]等价于t[:,1];如果是三维数值,t[...,1]等价于t[:,:,1]。 tf.newaxis和np.newaxis功能相同,都是增加维度。 t=tf.constant([[1,2,3],[4,5,6]]) t[... 阅读全文
posted @ 2020-04-21 15:26 2021年的顺遂平安君 阅读(190) 评论(0) 推荐(0) 编辑
摘要: tf.keras.backend.learning_phase() The learning phase flag is a bool tensor (0 = test, 1 = train) to be passed as input to any K... 阅读全文
posted @ 2020-04-20 22:24 2021年的顺遂平安君 阅读(70) 评论(0) 推荐(0) 编辑
摘要: The learning phase flag is a bool tensor (0 = test, 1 = train) to be passed as input to any Keras function that uses a different behavior at train tim 阅读全文
posted @ 2020-04-20 22:24 2021年的顺遂平安君 阅读(782) 评论(0) 推荐(0) 编辑
摘要: from keras.models import Sequentialfrom keras.layers import Dense, Activationmodel = Sequential([ Dense(32, input_shape=(784,... 阅读全文
posted @ 2020-04-20 20:52 2021年的顺遂平安君 阅读(95) 评论(0) 推荐(0) 编辑
摘要: mdl_A = keras.models.load("mdl_A.hf")mdl_B_on_A = keras.models.Sequential(mdl_A.layers[:-1])mdl_B_on_A.add(keras.layers.Dense(1,... 阅读全文
posted @ 2020-04-20 20:33 2021年的顺遂平安君 阅读(58) 评论(0) 推荐(0) 编辑
摘要: 需要注意的是,此时 和`mdl_B clone mdl_A mdl_B`互不影响。 只拷贝网络结构,不会拷贝权重等训练好的参数,因此 之后需要用 把`mdl_A`的参数也一同拷贝过去。 阅读全文
posted @ 2020-04-20 20:33 2021年的顺遂平安君 阅读(491) 评论(0) 推荐(0) 编辑
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 72 下一页