上一页 1 2 3 4 5 6 7 8 9 10 ··· 29 下一页
摘要: from tensorflow.keras.callbacks import EarlyStopping import tensorflow as tf import time import numpy as np import matplotlib.pyplot as plt import sys 阅读全文
posted @ 2021-04-28 14:28 山…隹 阅读(135) 评论(0) 推荐(0) 编辑
摘要: 流程图: self-attention: 矩阵运算: Q*K: V*(QK): 整体过程: 阅读全文
posted @ 2021-02-16 17:37 山…隹 阅读(113) 评论(0) 推荐(0) 编辑
摘要: from tensorflow import keras import tensorflow as tf from tensorflow.keras import layers import numpy as np import os import matplotlib.pyplot as plt 阅读全文
posted @ 2021-01-12 17:31 山…隹 阅读(584) 评论(0) 推荐(0) 编辑
摘要: (1)没有output_padding: # 当padding="valid"时 new_rows = (rows - 1) * strides[0] + kernel_size[0] new_cols = (cols - 1) * strides[1] + kernel_size[1] # 当pa 阅读全文
posted @ 2020-12-25 16:55 山…隹 阅读(289) 评论(0) 推荐(0) 编辑
摘要: 两个分布的对比(这里是与标准正态分布对比): import tensorflow as tf from tensorflow import keras import numpy as np import matplotlib.pyplot as plt from PIL import Image i 阅读全文
posted @ 2020-12-20 16:45 山…隹 阅读(579) 评论(0) 推荐(0) 编辑
摘要: import tensorflow as tf from tensorflow import keras import numpy as np import matplotlib.pyplot as plt from PIL import Image import os from tensorflo 阅读全文
posted @ 2020-12-20 15:56 山…隹 阅读(128) 评论(0) 推荐(0) 编辑
摘要: (x,y),(x_test,y_test) = tf.keras.datasets.cifar10.load_data() x = x/255. x = tf.cast(x,tf.float32) x_test = x_test/255. x_test = tf.cast(x_test,tf.flo 阅读全文
posted @ 2020-12-17 18:22 山…隹 阅读(301) 评论(0) 推荐(0) 编辑
摘要: # 图像增强 inputs = tf.image.random_flip_left_right(inputs) # 图像随机翻转 inputs = tf.image.random_brightness(inputs,max_delta=0.1) # 图像随机光照 inputs = tf.image. 阅读全文
posted @ 2020-12-17 13:32 山…隹 阅读(628) 评论(0) 推荐(0) 编辑
摘要: self.conv1 = tf.keras.layers.Conv2D(filter_num, (3, 3), strides=stride, padding='same',kernel_initializer=tf.keras.initializers.he_normal(stddev=0.02) 阅读全文
posted @ 2020-12-16 21:01 山…隹 阅读(567) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2020-11-16 10:56 山…隹 阅读(311) 评论(0) 推荐(1) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 29 下一页