Q1. What is Artificial Intelligence? Give an example of where AI is used on a daily basis.
“Artificial Intelligence (AI) is an area of computer science that emphasizes the creation of intelligent machines that work and react like humans.” “The capability of a machine to the intelligent imitate human behavior.”
Google’s Search Engine – Artificial Intelligence Interview Questions
Google’s Search Engine
One of the most popular AI Applications is the google search engine. If you open up your chrome browser and start typing something, Google immediately provides recommendations for you to choose from. The logic behind the search engine is Artificial Intelligence.
AI uses predictive analytics, NLP and Machine Learning to recommend relevant searches to you. These recommendations are based on data that Google collects about you, such as your search history, location, age, etc. Thus, Google makes use of AI, to predict what you might be looking for.
Convolutional Neural Network
Recurrent Neural Network(RNN) – Long Short Term Memory
Artificial Intelligence is a technique that enables machines to mimic human behavior. Whereas, Machine Learning is a subset of Artificial Intelligence. It is the science of getting computers to act by feeding them data and letting them learn a few tricks on their own, without being explicitly programmed to do so. Therefore Machine Learning is a technique used to implement Artificial Intelligence.
Deep learning imitates the way our brain works i.e. it learns from experiences. It uses the concepts of neural networks to solve complex problems.
Any Deep neural network will consist of three types of layers:
An Artificial Neuron or a Perceptron models a neuron which has a set of inputs, each of which is assigned some specific weight. The neuron then computes some function on these weighted inputs and gives the output.
Q8. What are Bayesian Networks?
A Bayesian network is a statistical model that represents a set of variables and their conditional dependencies in the form of a directed acyclic graph.
On the occurrence of an event, Bayesian Networks can be used to predict the likelihood that any one of several possible known causes was the contributing factor.
For example, a Bayesian network could be used to study the relationship between diseases and symptoms. Given various symptoms, the Bayesian network is ideal for computing the probabilities of the presence of various diseases.
The Q-learning is a Reinforcement Learning algorithm in which an agent tries to learn the optimal policy from its past experiences with the environment. The past experiences of an agent are a sequence of state-action-rewards:
Computer Vision is a field of Artificial Intelligence that is used to obtain information from images or multi-dimensional data. Machine Learning algorithms such as K-means is used for Image Segmentation, Support Vector Machine is used for Image Classification and so on.
Therefore Computer Vision makes use of AI technologies to solve complex problems such as Object Detection, Image Processing, etc.
Generally, a Reinforcement Learning (RL) system is comprised of two main components:
To understand this better, let’s suppose that our agent is learning to play counter strike. The RL process can be broken down into the below steps:
To learn more about Reinforcement Learning you can go through this video recorded by our Machine Learning experts.
The RL agent works based on the theory of reward maximization. This is exactly why the RL agent must be trained in such a way that, he takes the best action so that the reward is maximum.
Let me explain this with a small game. In the figure you can see a fox, some meat and a tiger.
The next thing to understand is, how discounting of rewards work?
To do this, we define a discount rate called gamma. The value of gamma is between 0 and 1. The smaller the gamma, the larger the discount and vice versa.
Q5. What is exploitation and exploration trade-off?
An important concept in reinforcement learning is the exploration and exploitation trade-off.
Exploration, like the name suggests, is about exploring and capturing more information about an environment. On the other hand, exploitation is about using the already known exploited information to heighten the rewards.
Exploitation & Exploration – Artificial Intelligence Interview Questions
Consider the fox and tiger example, where the fox eats only the meat (small) chunks close to him but he doesn’t eat the bigger meat chunks at the top, even though the bigger meat chunks would get him more rewards.
Grid search trains the network for every combination by using the two set of hyperparameters, learning rate and the number of layers. Then evaluates the model by using Cross Validation techniques.
It randomly samples the search space and evaluates sets from a particular probability distribution. For example, instead of checking all 10,000 samples, randomly selected 100 parameters can be checked.
This includes fine-tuning the hyperparameters by enabling automated model tuning. The model used for approximating the objective function is called surrogate model (Gaussian Process). Bayesian Optimization uses Gaussian Process (GP) function to get posterior functions to make predictions based on prior functions.
Overfitting occurs when a statistical model or machine learning algorithm captures the noise of the data. This causes an algorithm to show low bias but high variance in the outcome.
Overfitting can be prevented by using the following methodologies:
Cross-validation: The idea behind cross-validation is to split the training data in order to generate multiple mini train-test splits. These splits can then be used to tune your model.
More training data: Feeding more data to the machine learning model can help in better analysis and classification. However, this does not always work.
Remove features: Many times, the data set contains irrelevant features or predictor variables that are not needed for analysis. Such features only increase the complexity of the model, thus leading to possibilities of data overfitting. Therefore, such redundant variables must be removed.
Early stopping: A machine learning model is trained iteratively, this allows us to check how well each iteration of the model performs. But after a certain number of iterations, the model’s performance starts to saturate. Further training will result in overfitting, thus one must know where to stop the training. This can be achieved by a mechanism called early stopping.
Regularization: Regularization can be done in n number of ways, the method will depend on the type of learner you’re implementing. For example, pruning is performed on decision trees, the dropout technique is used on neural networks and parameter tuning can also be applied to solve overfitting issues.
Use Ensemble models: Ensemble learning is a technique that is used to create multiple Machine Learning models, which are then combined to produce more accurate results. This is one of the best ways to prevent overfitting. An example is Random Forest, it uses an ensemble of decision trees to make more accurate predictions and to avoid overfitting.
Dropout is a type of regularization technique used to avoid overfitting in a neural network. It is a technique where randomly selected neurons are dropped during training.
The Dropout value of a network must be chosen wisely. A value too low will result in a minimal effect and a value too high results in under-learning by the network.
Natural Language Understanding includes:
Natural Language Generation includes:
Therefore, it is better to choose supervised classification for image classification in terms of accuracy.
Image Smoothing is one of the best methods used for reducing noise by forcing pixels to be more like their neighbors, this reduces any distortions caused by contrasts.
Minimax is a recursive algorithm used to select an optimal move for a player assuming that the other player is also playing optimally.
A game can be defined as a search problem with the following components:
“In the context of artificial intelligence(AI) and deep learning systems, game theory is essential to enable some of the key capabilities required in multi-agent environments in which different AI programs need to interact or compete in order to accomplish a goal.”