摘要: import tensorflow as tf logits = tf.random.uniform([1,10],minval=-2,maxval=2) print('logits:',logits) prob = tf.nn.softmax(logits) print('softmax后:',p 阅读全文
posted @ 2020-08-15 17:49 山…隹 阅读(843) 评论(0) 推荐(0)
摘要: import tensorflow as tf x = tf.random.normal((2,3)) # 模拟样本数据 model = tf.keras.Sequential([ # 定义全连接层结构 tf.keras.layers.Dense(4,activation='relu'), # 第一 阅读全文
posted @ 2020-08-15 17:45 山…隹 阅读(604) 评论(0) 推荐(0)