
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 33676 Articles for Programming

435 Views
The UTF-8 strings can be split using Tensorflow text. This can be done with the help of ‘UnicodeScriptTokenizer’. ‘UnicodeScriptTokenizer’ is a tokenizer that is created, after which the ‘tokenize’ method present in ‘UnicodeScriptTokenizer’ is called on the string.Read More: What is TensorFlow and how Keras work with TensorFlow to create Neural Networks?We will use the Keras Sequential API, which is helpful in building a sequential model that is used to work with a plain stack of layers, where every layer has exactly one input tensor and one output tensor.A neural network that contains at least one layer is known as ... Read More

260 Views
Tensorflow text can be used to tokenize string data with the help of the ‘WhitespaceTokenizer’ which is a tokenizer that is created, after which the ‘tokenize’ method present in ‘WhitespaceTokenizer’ is called on the string.Read More: What is TensorFlow and how Keras work with TensorFlow to create Neural Networks?We will use the Keras Sequential API, which is helpful in building a sequential model that is used to work with a plain stack of layers, where every layer has exactly one input tensor and one output tensor.A neural network that contains at least one layer is known as a convolutional layer. ... Read More

247 Views
Tensorflow text is a package that can be used with the Tensorflow library. It has to be installed explicitly before using it. It can be used to pre-process data for text-based models.Read More: What is TensorFlow and how Keras work with TensorFlow to create Neural Networks?We will use the Keras Sequential API, which is helpful in building a sequential model that is used to work with a plain stack of layers, where every layer has exactly one input tensor and one output tensor.A neural network that contains at least one layer is known as a convolutional layer. We can use ... Read More

410 Views
Once training is done, the model built can be used with new data which is augmented. This can be done using the ‘predict’ method. The data that needs to be validated with, is first loaded into the environment. Then, it is pre-processed, by converting it from an image to an array. Next, the predict method is called on this array.Read More: What is TensorFlow and how Keras work with TensorFlow to create Neural Networks?We will use the Keras Sequential API, which is helpful in building a sequential model that is used to work with a plain stack of layers, where ... Read More

826 Views
The result for splitting camel case strings into series as, enter the sring: pandasSeriesDataFrame Series is: 0 pandas 1 Series 2 Data 3 Frame dtype: objectTo solve this, we will follow the steps given below −SolutionDefine a function that accepts the input stringSet result variable with the condition as input is not lowercase and uppercase and no ’_’ in input string. It is defined below, result = (s != s.lower() and s != s.upper() and "_" not in s)Set if condition to check if the result is true the apply re.findall method to find camel case ... Read More

221 Views
Assume, you have two series and the result for combining two series into dataframe as, Id Age 0 1 12 1 2 13 2 3 12 3 4 14 4 5 15To solve this, we can have three different approaches.Solution 1Define two series as series1 and series2Assign first series into dataframe. Store it as dfdf = pd.DataFrame(series1)Create a column df[‘Age’] in dataframe and assign second series inside to df.df['Age'] = pd.DataFrame(series2)ExampleLet’s check the following code to get a better understanding −import pandas as pd series1 = pd.Series([1, 2, 3, 4, 5], name='Id') series2 = pd.Series([12, 13, 12, 14, 15], name='Age') ... Read More

12K+ Views
Assume, you have a dataframe and the result for a date, month, year column is, date day month year 0 17/05/2002 17 05 2002 1 16/02/1990 16 02 1990 2 25/09/1980 25 09 1980 3 11/05/2000 11 05 2000 4 17/09/1986 17 09 1986To solve this, we will follow the steps given below −SolutionCreate a list of dates and assign into dataframe.Apply str.split function inside ‘/’ delimiter to df[‘date’] column. Assign the result to df[[“day”, “month”, “year”]].ExampleLet’s check the following code to get a better understanding −import ... Read More

428 Views
The flower dataset, after applying augmenting and dropout methods (to avoid overfitting) can be visualized using ‘matplotlib’ library. It is done using the ‘plot’ method.Read More: What is TensorFlow and how Keras work with TensorFlow to create Neural Networks?We will use the Keras Sequential API, which is helpful in building a sequential model that is used to work with a plain stack of layers, where every layer has exactly one input tensor and one output tensor.A neural network that contains at least one layer is known as a convolutional layer. We can use the Convolutional Neural Network to build learning ... Read More

148 Views
Assume, you have a series and the result for converting to dummy variable as, Female Male 0 0 1 1 1 0 2 0 1 3 1 0 4 0 1 5 0 0 6 1 0 7 1 0To solve this, we will follow the steps given below −SolutionCreate a list with ‘Male’ and ‘Female’ elements and assign into Series.Apply get_dummies function inside series and set dummy_na value as False. It is defined below, pd.get_dummies(series, dummy_na=False)ExampleLet’s check the following code to get ... Read More

174 Views
Assume, you have a dataframe and the result for converted to latex as, \begin{tabular}{lrr} \toprule {} & Id & Age \ \midrule 0 & 1 & 12 \ 1 & 2 & 13 \ 2 & 3 & 14 \ 3 & 4 & 15 \ 4 & 5 & 16 \ \bottomrule \end{tabular}SolutionTo solve this, we will follow the steps given below −Define a dataframeApply to_latex() function to the dataframe and set index and multirow values as True. It is defined below, df.to_latex(index = True, multirow = True)ExampleLet’s ... Read More