TensorFlow-Coding icon indicating copy to clipboard operation
TensorFlow-Coding copied to clipboard

这是我在小象学院课程《深度学习之TensorFlow高级编程》的课程代码

Results 7 TensorFlow-Coding issues
Sort by recently updated
recently updated
newest added

Hello,[this issue](https://github.com/zhaoyingjun/TensorFlow-Coding/issues/12) shows the reason that I commit this PR. I sincerely wish my PR will help you.And if you think my PR has a little work,Hoping you could merge...

Hello, I found a performance issue in the definition of `train`, lessonOne/imgClassifierWeb/execute.py, [`tf.argmax(softmax_propabilities, axis=1)`](https://github.com/zhaoyingjun/TensorFlow-Coding/blob/1ff292e5d659aa98e7bf6d9cc3986ef07ac2ca81/lessonOne/imgClassifierWeb/execute.py#L151) will be created repeatedly during program execution, resulting in reduced efficiency. I think it should be...

Hello,I found a performance issue in the definition of `train_input_fn` , lessonEight/textClassiferModel.py, [dataset = dataset.map(parser)](https://github.com/zhaoyingjun/TensorFlow-Coding/blob/1ff292e5d659aa98e7bf6d9cc3986ef07ac2ca81/lessonEight/textClassiferModel.py#L116) was called without **num_parallel_calls**. I think it will increase the efficiency of your program if...

https://github.com/zhaoyingjun/TensorFlow-Coding/blob/0034d92e17f164b86accac3c49826dab0ce79fa6/lessonOne/imgClassifierWeb/cnnModel.py#L152 老师您好,我是听了小象学院课程的学生,关于这行代码有两个问题想请教: 1. 根据tf.nn.sparse_softmax_cross_entropy_with_logits的[文档](https://www.tensorflow.org/api_docs/python/tf/nn/sparse_softmax_cross_entropy_with_logits),label可以直接放入数值化的标签结果,请问您这里为什么做了One-hot处理呢? 2. 根据tf.nn.sparse_softmax_cross_entropy_with_logits的[文档](https://www.tensorflow.org/api_docs/python/tf/nn/sparse_softmax_cross_entropy_with_logits),这里的logits应该是未经softmax处理的结果(这个函数会进行softmax操作),您这里输入的为什么是经过softmax后的值呢? 初学请教,理解错误之处请您谅解;万望回复,谢谢啦!

在cnnModel.py中: 问题1: line 143: keep_prop=tf.Variable(initial_value=0.5,name="keep_prop") line 144: self.fc_result=create_CNN(input_data=self.data_tensor,num_classes=gConfig['num_dataset_classes'],keep_prop=gConfig['keeps'] keep_prop变量并没有被用到,且在144行,参数keep_prop=gConfig['keeps']不能这样写,因为后面要根据forward_only的值,传不同的参数给keep_prop变量。 我认为应该讲keep_prop定义为place_holder,以下为参考: self.keep_prop=tf.placeholder(tf.float32,name="keep_prop") self.fc_result=create_CNN(input_data=self.data_tensor,num_classes=gConfig['num_dataset_classes'],keep_prop=self.keep_prop)、 -------------------------------------- 问题2: line 200: accuracy = correct.size/(self.percent*gConfig['dataset_size']/100) 这里求accuracy的分母,要改为shuffled_data.shape[0] ------------------------------------- 问题3: cnnModel: step函数中,if forward_only:这一部分应该也需要更改或者重写,请核实