1598733000

**Problem**:

Given the phrase “34+17”, the model should predict the next word in the sequence “51”. The input and output is a sequence of characters which in turn an arithmetic expression of two numbers and its result. Thus our data is represented as a sequence of two words *expression* and *result*.

**Motivation:**

As Recurrent Neural Networks(RNNs) are best suitable for processing sequential data, we are going to build a simple RNN model for solving this problem.

This can be implemented in 6 steps:

- Generating data
- Building model
- Vectoring, DE_vectoring data & remove the padding
- Creating dataset
- Training the model
- Predictions

**Import necessary Libraries**

**Step 1: Generating data**

We need to define a vocabulary with the required set of characters for the input and output strings. Thus the vocabulary consists of 0 to 9 digits, +, -, *, / and decimal(.) symbols.

The RNN model that we are building needs numeric values in tensors as an input. A suitable representation of this sequence of characters is one-hot encoded vectors. The dimension of the vector should be equal to the length of vocabulary, which is the total number of features. A dictionary needs to create to tokenize the characters into numeric values. Also, create another dictionary with indices as keys and corresponding characters as values that are used in later steps.

#python #rnn #arithmetic operations

1598733000

**Problem**:

Given the phrase “34+17”, the model should predict the next word in the sequence “51”. The input and output is a sequence of characters which in turn an arithmetic expression of two numbers and its result. Thus our data is represented as a sequence of two words *expression* and *result*.

**Motivation:**

As Recurrent Neural Networks(RNNs) are best suitable for processing sequential data, we are going to build a simple RNN model for solving this problem.

This can be implemented in 6 steps:

- Generating data
- Building model
- Vectoring, DE_vectoring data & remove the padding
- Creating dataset
- Training the model
- Predictions

**Import necessary Libraries**

**Step 1: Generating data**

We need to define a vocabulary with the required set of characters for the input and output strings. Thus the vocabulary consists of 0 to 9 digits, +, -, *, / and decimal(.) symbols.

The RNN model that we are building needs numeric values in tensors as an input. A suitable representation of this sequence of characters is one-hot encoded vectors. The dimension of the vector should be equal to the length of vocabulary, which is the total number of features. A dictionary needs to create to tokenize the characters into numeric values. Also, create another dictionary with indices as keys and corresponding characters as values that are used in later steps.

#python #rnn #arithmetic operations

1617331277

The Association of Data Scientists (AdaSci), the premier global professional body of data science and ML practitioners, has announced a hands-on workshop on deep learning model deployment on February 6, Saturday.

Over the last few years, the applications of deep learning models have increased exponentially, with use cases ranging from automated driving, fraud detection, healthcare, voice assistants, machine translation and text generation.

Typically, when data scientists start machine learning model development, they mostly focus on the algorithms to use, feature engineering process, and hyperparameters to make the model more accurate. However, model deployment is the most critical step in the machine learning pipeline. As a matter of fact, models can only be beneficial to a business if deployed and managed correctly. Model deployment or management is probably the most under discussed topic.

In this workshop, the attendees get to learn about ML lifecycle, from gathering data to the deployment of models. Researchers and data scientists can build a pipeline to log and deploy machine learning models. Alongside, they will be able to learn about the challenges associated with machine learning models in production and handling different toolkits to track and monitor these models once deployed.

#hands on deep learning #machine learning model deployment #machine learning models #model deployment #model deployment workshop

1624570140

This is the fourth part of the metric series where, we will discuss about evaluation of the ML/DL model using metric NLP model are little tricky to evaluate because the output of these model is text/sentence/paragraph. So, we have to check the syntactical, semantic and well as the context of the output of the model So we uses different types of techniques to evaluate these model.

Before we start to dig deep, lets have some basic intuition about NLP model. NLP deals with Natural Language Processing i.e. it deals with the text data. We all know that ML model take input as numerical value i.e. numeric tensor and give numeric output. So we need to convert these text data into numerical format for this we have various preprocessing techniques such as Bog of Words. Word2vector, Doc2vector, Term Frequency(TF), Inverse Term Frequency(ITF), Term Frequency-Inverse Term Frequency(TF-IDF) or you can do manually by various techniques. For now you don’t need to get carried away just assume that Text have been converted by some algorithm or method into numerical value and vice versa.

#ai #machine-learning #deep-learning #model-evaluation #artificial-intelligence #machine learning models

1619565060

**Ternary Operator in Python**

What is a ternary operator: The ternary operator is a conditional expression that means this is a comparison operator and results come on a true or false condition and it is the shortest way to writing an if-else statement. It is a **condition** in a single line replacing the multiline if-else code.

**syntax : condition ? value_if_true : value_if_false**

**condition**: A boolean expression evaluates true or false

**value_if_true**: a value to be assigned if the expression is evaluated to true.

**value_if_false**: A value to be assigned if the expression is evaluated to false.

How to use ternary operator in python here are some examples of **Python ternary operator if-else**.

Brief description of examples we have to take two variables a and b. The value of a is 10 and b is 20. find the minimum number using a ternary operator with one line of code. ( **min = a if a < b else b ) **. if a less than b then print a otherwise print b and second examples are the same as first and the third example is check number is even or odd.

#python #python ternary operator #ternary operator #ternary operator in if-else #ternary operator in python #ternary operator with dict #ternary operator with lambda

1598891580

Recently, researchers from Google proposed the solution of a very fundamental question in the machine learning community — What is being transferred in Transfer Learning? They explained various tools and analyses to address the fundamental question.

The ability to transfer the domain knowledge of one machine in which it is trained on to another where the data is usually scarce is one of the desired capabilities for machines. Researchers around the globe have been using transfer learning in various deep learning applications, including object detection, image classification, medical imaging tasks, among others.

#developers corner #learn transfer learning #machine learning #transfer learning #transfer learning methods #transfer learning resources