from tensorflow.examples.tutorials.mnist import input_data
Getting following error for above statement. Please suggest..
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
<ipython-input-5-daba117be2f2> in <module>
6 import numpy as np
7 import matplotlib.pyplot as plt
----> 8 from tensorflow.examples.tutorials.mnist import input_data
ModuleNotFoundError: No module named 'tensorflow.examples.tutorials'
Under the current COVID-19 situation, E&ICT Academy is working with a limited workforce. Since the certificate is issued from E&ICT -IIT Roorkee, the concerned authority will take a bit more time than the usual time to check your work and update.
We will be issuing the certificate within the time span of a minimum 15 days. Hope you understand the situation.
shape=(7, 7, 1, 3) here 1 denotes no. of channels by how it is 1 we have converted rgb to grey so 3rd channel(colored) is removed so now no. of channels for grey image should be 2 but here why it is 1??
That is a very broad description of CNN but yes, you can use that. However, that definition will not be entirely accurate as CNNs apply to natural language processing and other kinds of cognitive tasks.
For every 2x2 pooling the output size is reduced by half along each dimension. For strided convolutions, you also divide the size of each dimension by the stride. You may have to shave off some of the dimension depending on if you use padding for your convolutions. The simplest case is to use padding = floor(kernel size/2), so that a convolution dose not have any extra change on the output size.
is the input in different channels need to be scaled (or normalized) before feeding to the CNN? I ask this because channels may contain different kind of information rather than just the pixel intensities
My data is related to remote sensing so, in addition to RGB, there can be other data as well such as Infrared data. For this particular case, can functional API of Keras be a better choice than a sequential model?
Please login to comment
28 Comments
from tensorflow.examples.tutorials.mnist import input_data
Upvote ShareHi,
Please use Python3 kernel in your jupyter notebook.
Thanks.
Upvote ShareHi,
What is the difference between tf.layers.conv2d() and tf.nn.conv2d()?
Thanks
1 Upvote ShareHi,
Good question!
Please check the below link for a detailed explanation:
https://stackoverflow.com/questions/42785026/tf-nn-conv2d-vs-tf-layers-conv2d
Thanks.
Upvote ShareBased on the ppt, there is no code given for actually running the model, to classify with a given image
Can you please provide a line of code
Upvote ShareHi,
Have you checked our GitHub repository for the CNN Jupyter notebook?
Thanks.
Upvote Sharepls share the link of the repository
Upvote ShareHi Dhruv,
Please find below the link to our Machine Learning and Deep Learning repository on GitHub:
https://github.com/cloudxlab/ml
Thanks.
Upvote Shareis it the cnn_with_keras.ipynb?
Upvote ShareHi,
Please find the link to the CNN notebook below:
https://github.com/cloudxlab/ml/blob/master/deep_learning/convolutional_neural_networks.ipynb
Thanks.
Upvote ShareHi
I have completed the course but didnt get certificate. Could you please guide me what should I do to get certificate?
Thanks
Prachi
Upvote ShareHI Prachi
We have repsonded to you.
Please check your mail.
Upvote ShareHi Malavika
I just checked your email but Could you please tell me atleast approximate time how can I get certificate?
Thanks
Prachi
Upvote ShareHI Prachi
Under the current COVID-19 situation, E&ICT Academy is working with a limited workforce. Since the certificate is issued from E&ICT -IIT Roorkee, the concerned authority will take a bit more time than the usual time to check your work and update.
Upvote ShareWe will be issuing the certificate within the time span of a minimum 15 days. Hope you understand the situation.
Hi,
In the below code of the cnn example,
fmap = np.zeros(shape=(7, 7, 1, 3), dtype=np.float32)
fmap[:, 3, 0, 0] = 1
fmap[3, :, 0, 1] = 1
fmap[3, 3, 0, 2] = 1
plot_image(fmap[:, :, 0, 2])
plt.show()
shape=(7, 7, 1, 3) here 1 denotes no. of channels by how it is 1 we have converted rgb to grey so 3rd channel(colored) is removed so now no. of channels for grey image should be 2 but here why it is 1??
Hi,
A greyscale image has one channel.
Thanks.
Upvote ShareThis comment has been removed.
Can I summarize CNNs as reducing the image to what is relevant to our prediction?
Upvote ShareHi,
That is a very broad description of CNN but yes, you can use that. However, that definition will not be entirely accurate as CNNs apply to natural language processing and other kinds of cognitive tasks.
Thanks.
Upvote ShareHi
How we would decide size of receptive field and stride size?
Upvote ShareHi,
For every 2x2 pooling the output size is reduced by half along each dimension. For strided convolutions, you also divide the size of each dimension by the stride. You may have to shave off some of the dimension depending on if you use padding for your convolutions. The simplest case is to use padding = floor(kernel size/2), so that a convolution dose not have any extra change on the output size.
Thanks.
Upvote Shareis the input in different channels need to be scaled (or normalized) before feeding to the CNN? I ask this because channels may contain different kind of information rather than just the pixel intensities
Upvote ShareYes. We generally do that by simply dividing the color by 254 because the color values are between 0 to 254.
I am curious to know what else can channels have other than pixel intensities of each color R, G and B.
Upvote ShareMy data is related to remote sensing so, in addition to RGB, there can be other data as well such as Infrared data. For this particular case, can functional API of Keras be a better choice than a sequential model?
Upvote ShareYes, it would be. You define the shape of the input as per your choice.
Upvote ShareYes, tensorflow keras will be a good starting point.
Upvote Shareis the number of filters a hyperparameter to be tuned?
Upvote Shareyes, we need to decide the type of filters and how many of those filters should be added. Therefore, you can say that these are hyper parameters.
Upvote Share