-
大小: 25.19MB文件類型: .zip金幣: 1下載: 0 次發(fā)布日期: 2023-08-02
- 語言: 其他
- 標(biāo)簽: tensorflow??python??mnist??deeplearning??
資源簡介
包括數(shù)據(jù)集、網(wǎng)絡(luò)結(jié)構(gòu)、訓(xùn)練代碼、測試代碼,還有示范的最終模型
代碼片段和文件信息
import?tensorflow?as?tf
INPUT_NODE?=?784
OUTPUT_NODE?=?10
layer1_NODE?=?500
def?get_weight_variable(shaperegularizer):
????weights?=?tf.get_variable(“weights“shapeinitializer=tf.truncated_normal_initializer(stddev=0.1))
????if?regularizer?!=?None:
????????tf.add_to_collection(‘losses‘?regularizer(weights))
????return??weights
def?inference(input_tensor?regularizer):
????with?tf.variable_scope(‘layer1‘):
????????weights?=?get_weight_variable([INPUT_NODE?layer1_NODE]?regularizer)
????????biases?=?tf.get_variable(“biases“?[layer1_NODE]?initializer=tf.constant_initializer(0.0))
????layer1?=?tf.nn.relu(tf.matmul(input_tensor?weights)?+?biases)
????with?tf.variable_scope(‘layer2‘):
????????weights?=?get_weight_variable([layer1_NODE?OUTPUT_NODE]?regularizer)
????????biases?=?tf.get_variable(“biases“?[OUTPUT_NODE]?initializer=tf.constant_initializer(0.0))
????layer2?=?tf.nn.relu(tf.matmul(layer1?weights)?+?biases)
????return?layer2
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-10-15?19:52??mnist\
?????目錄???????????0??2018-10-15?19:52??mnist\MNIST_data\
?????文件?????1648877??2018-08-25?11:29??mnist\MNIST_data\t10k-images-idx3-ubyte.gz
?????文件????????4542??2018-08-25?11:29??mnist\MNIST_data\t10k-labels-idx1-ubyte.gz
?????文件?????9912422??2018-08-25?11:28??mnist\MNIST_data\train-images-idx3-ubyte.gz
?????文件???????28881??2018-08-25?11:29??mnist\MNIST_data\train-labels-idx1-ubyte.gz
?????文件?????????976??2018-10-15?13:18??mnist\mnist_inference.py
?????目錄???????????0??2018-10-15?19:52??mnist\mnist_model\
?????文件?????????595??2018-10-15?14:05??mnist\mnist_model\checkpoint
?????文件?????3180084??2018-10-15?14:05??mnist\mnist_model\model.ckpt-15001.data-00000-of-00001
?????文件?????????470??2018-10-15?14:05??mnist\mnist_model\model.ckpt-15001.index
?????文件???????62980??2018-10-15?14:05??mnist\mnist_model\model.ckpt-15001.me
?????文件?????3180084??2018-10-15?14:05??mnist\mnist_model\model.ckpt-16001.data-00000-of-00001
?????文件?????????470??2018-10-15?14:05??mnist\mnist_model\model.ckpt-16001.index
?????文件???????62980??2018-10-15?14:05??mnist\mnist_model\model.ckpt-16001.me
?????文件?????3180084??2018-10-15?14:05??mnist\mnist_model\model.ckpt-17001.data-00000-of-00001
?????文件?????????470??2018-10-15?14:05??mnist\mnist_model\model.ckpt-17001.index
?????文件???????62980??2018-10-15?14:05??mnist\mnist_model\model.ckpt-17001.me
?????文件?????3180084??2018-10-15?14:05??mnist\mnist_model\model.ckpt-18001.data-00000-of-00001
?????文件?????????470??2018-10-15?14:05??mnist\mnist_model\model.ckpt-18001.index
?????文件???????62980??2018-10-15?14:05??mnist\mnist_model\model.ckpt-18001.me
?????文件?????3180084??2018-10-15?14:05??mnist\mnist_model\model.ckpt-19001.data-00000-of-00001
?????文件?????????470??2018-10-15?14:05??mnist\mnist_model\model.ckpt-19001.index
?????文件???????62980??2018-10-15?14:05??mnist\mnist_model\model.ckpt-19001.me
?????文件????????1713??2018-10-15?14:04??mnist\mnist_test.py
?????文件????????2200??2018-10-15?14:01??mnist\mnist_train.py
評論
共有 條評論