The way PyTorch’s *scatter_(dim, index, src)* function works can be a bit confusing. So, I will take a visual approach in explaining the function as I believe it will be more clearer in grasping the concept further.

The *scatter_()* function takes three arguments: The *dimension* across which we will be filling out the data. If dim=0, this means that we will be filling the data across the rows, and if dim=1, we will be filling the data across the columns.

The second argument, *index*, is where in the respective dimension (row or column) the value to fill out will be placed. The third argument, *src*, represents the values we would like to fill out in the tensor upon which the scatter_() function will be affected. …

I was reading in Bart Kosko’s book: Fuzzy Thinking, where he mentioned that in much of our science, math, logic, and culture, we have assumed a world of blacks and whites that doesn’t change. In other words, everything is either true or false. Even our computers are based on this concept of black and white, especially when we notice how it is based on the binary strings of 0s (black) and 1s (white).

This belief of a *bivalence* world is not new. For instance, Aristotle wrote what he felt were the black-and-white (binary) laws of logic, laws which scientists and mathematicians still use to describe the gray universe. …

In an interview I conducted with Jürgen Schmidhuber, a German computer scientist and artist known for his work in many fields including machine learning, Artificial Intelligence (AI), and artificial neural networks, I asked him where he sees Deep Learning (a form of machine learning) in the coming 10-years. I got an interesting answer to this question which I would like to share a part of in this post. Jürgen mentioned that by 2025, even minor extensions of existing machine learning and neural network algorithms will achieve many important superhuman feats.

He also added that he expects huge recurrent neural networks (RNNs) on dedicated hardware to simultaneously perceive and analyse an immense number of multimodal data streams (speech, texts, video, many other modalities) from many sources, learning to correlate all those inputs and use the extracted information to achieve a myriad of commercial and non-commercial goals. Those RNNs will continually and quickly learn new skills on top of those they already know. This should have innumerable applications, and will change society in innumerable ways. …

Deep Learning is a very hot topic nowadays, either in academia or industry. Big companies like Google and Facebook are relying heavily on Deep Learning, and academia is using this technology to solve complex research problems for its state-of-the-art solutions.

Talking about the usage of Deep Learning with skin cancer (i.e. melanoma), from the academic perspective, we can notice the increased number of publications recently published on the topic. In other words, many algorithms are now employing Deep Learning to solve skin cancer issues, like melanoma detection for instance.

Deep Learning in itself is not new. The earliest Deep Learning like algorithms can be traced back to 1965. What is *very* new however is the use of Deep Learning techniques for melanoma detection. If you search for research papers employing Deep Learning for melanoma detection, you will notice that they were published between 2015 and 2016 only! With most of the papers published in 2016. A thesis in Sweden has even been written on this topic this year also, titled: To be, or not to be melanoma. Details on algorithms developed during those 2-years will not be explained here as they are beyond the aim of this post. …

I will be sharing a script using Keras for training a Convolutional Neural Network (CNN) with transfer learning for melanoma detection. You can find the code in **this GitHub repository**. In the **previous post**, the CNN was trained from scratch without augmenting the data.

Before proceeding, make sure that you structure the data as follows (the numbers represent the number of images in each file):

I will be sharing a script using Keras for training a Convolutional Neural Network (CNN) from scratch for melanoma detection. You can view the code from **this GitHub repository**.

Before proceeding however, make sure that you structure the data as follows (the numbers represent the number of images in each file):

I will be sharing a script using Keras for training a Convolutional Neural Network (CNN) from scratch with data augmentation for melanoma detection. You can view the code from **this GitHub repository**. In the **previous post**, the CNN was trained from scratch without augmenting the data.

Before proceeding, make sure that you structure the data as follows (the numbers represent the number of images in each file):

So in **Part-I** I gave a simple introduction on what linear regression is and how we can find the equation of the best fit line for our data. In this post, I will show you how to implement the task we worked on in Part-I in PyTorch. So, let’s get started!

The first step is to import the libraries we will be using:

`import torch`

import torch.nn as nn

import numpy as np

import matplotlib.pyplot as plt

Now, we need to set the hyperparameters, as follows:

`input_size = 1`

output_size = 1

epochs = 50

learning_rate = 0.0001

The input size is set to 1 since our inputs to the model are scalars *h* (hour in the day). The output is also set to 1 since we will get only one value returned for *r* (number of pages being read). So, basically, we will leave our program to find the best values for *B_0* and *B_1* that we calculated in the previous part of this tutorial. …

The term *linear regression *might seem a bit complex at first, but don’t worry, it is a simple but powerful concept. Let us go through an example to understand the concept better.

I will throw some random data here and see what happens. Say that we have two variables *h* and *r*, that refer to the time of the day and how many pages a person read, respectively.

Let’s assume that the person starts reading at 9:00 AM and finishes at 2:00 PM. …

About