text stringlengths 83 79.5k |
|---|
H: Inappropriate stemming in nltk.stem
I was starting to learn stemming with nltk and a few words were quite inappropriately stemmed.
For example:- very was stemmed to 'veri', important to 'import', once to 'onc', poorly to 'poorli' , etc.
I was just thinking that during data analysis, does it cause any error or thes... |
H: Are the image data augmentation generators in Keras randomly applied
I am working on an image classification problem and using data augmentation in Keras.
from keras.preprocessing.image import ImageDataGenerator
datagen = ImageDataGenerator(
rotation_range=2,
horizontal_flip=True)
I would like to know ... |
H: What should be the training frequency of a rnn model for timeseries prediction?
If I use a rnn model for time series forecasting how frequently do I have to retrain the model.
AI: It depends on any number of factors. What kind of accuracy are you currently getting? How often are you getting new predictions from you... |
H: How cross validation works for regression?
For regression type problem we know the result is a continuous value, so how is it be cross validated?
In classification type problem we know the class label so easy to compare, but how is it compare in regression type problem?
AI: In both scenarios, we pick one or more pe... |
H: Vectorizing text data for ML models
Here is the sample data I have:
Tag 1(Val: X), Tag 2(Val: Y), Tag 3(Val: Z), Label (Val: P)
Tag 1(Val: A), Tag 2(Val: B), Tag 3(Val: C), Label (Val: Q)
Tag 1(Val: D), Tag 2(Val: E), Tag 3(Val: F), Label (Val: R)
Tag 1(Val: G), Tag 2(Val: H), Tag 3(Val: I), Label (Val: S)
All the ... |
H: GlobalAveragePooling2D in inception v3 example
I'm a complete begginer at Keras. In the Inception v3 example at https://keras.io/applications/
# create the base pre-trained model
base_model = InceptionV3(weights='imagenet', include_top=False)
# add a global spatial average pooling layer
x = base_model.output
x = ... |
H: What is the reason that CNN classify some images horribly wrong
I'm trying to train a CNN for MNIST, everything goes well except for the loss stays very high in my model, while it's very low in example(which has different structure).
this model still yields high accuracy though there is high loss.
Here I attached m... |
H: Keras Callback example for saving a model after every epoch?
Can someone please post a straightforward example of Keras using a callback to save a model after every epoch? I can find examples of saving weights, but I want to be able to save a completely functioning model after every training epoch.
AI: Setting 'sav... |
H: Which algorithm should be used for an accurate job recommendation system
I'm building a testing project to get an introduction to DS & ML.
As a person part of the working force, sometimes finding a job is harder than it should be. I thought I could built a testing project to help workers find a job that best match... |
H: drop_duplicates() doesn't work in pandas
I am working on my pandas tutorial. Below is my dataframe
I am trying to drop duplicated header row using
df_FDNY_dataset.drop_duplicates(subset=['FacilityName','FacilityAddress','Borough'])
But drop_duplicates() function doesn't work in this case. Could you help me under... |
H: Shape of a distribution as a feature
How can I use the shape of a distribution as a feature in machine learning ? Do I use something like the standard deviation ?
AI: If this distribution is row specific (each sample has a different associated distribution) or category specific this is not a bad approach to encode ... |
H: Why will the accuracy of a highly unbalanced dataset reduce after oversampling?
I have created a synthetic dataset, with 20 samples in one class and 100 in the other, thus creating an imbalanced dataset. Now the accuracy of classification of the data before balancing is 80% while after balancing (i.e., 100 samples ... |
H: Why training model give great result but real data gives very bad result: Azure ML Studio
I am using Two-Class Boosted Decision Tree to train model.
Evaluation result I'd say really good.
But when I am using real dataset - the result is very bad.
What can possibly go wrong that makes such huge difference?
Below i... |
H: How to iterate and modify rows in a dataframe( convert numerical to categorical)
I have a pandas dataframe like this
0 15.55
1 15.55
2 15.55
3 15.55
4 20.84
Name: Y1, dtype: float64
I want to convert the values of Y1 to categorical (i.e) if its greater than 18.25, I want it 1 else 0
Can someone plea... |
H: When does boosting overfit more than bagging?
If we consider two conditions:
Number of data is huge
Number of data is low
For what condition does boosting or bagging overfit more compared to the other one?
AI: I read your question as: 'Is boosting more vulnerable to overfitting than bagging?'
Firstly, you need t... |
H: Transform Categorical Variables into Numerical
I'm very new to machine learning approaches. I'm reading a tutorial for build a predictive model using random forests.
One of the transformations implemented was transform categorical variables to binary.
Imagine (short sample):
Field_Desc Field_Value
A ... |
H: Why do pre-trained CNNs use low image resolution?
I want to use a pre-trained convolutional network for image classification. My base data has resolutions of 500x500px up to 1000x1000px. Pre-trained architectures often expect less (between 255 and 299px in case of Googles Inception network).
Firstly: Would it poten... |
H: How the squared Euclidean distance is an example of non-metric function?
I am reading a book on Pattern Recognition (by Prof V Susheela Devi and Prof Murty) where in the chapter of data representation 2.3.3 the non metric similarity function is defined as those which do not obey either the triangular inequality or ... |
H: What does "Norm" term mean?
In this paper (page 1 abstract) which considers regularization technique, the author used the word "norm" - what does it stand for?
Is it related to Batch Normalization / L1 or L2 Normalization?
"We stabilize the activations of Recurrent Neural Networks (RNNs) by penalizing
the squar... |
H: Does K-Means' objective function imply distance metric is Euclidean
The objective/loss function of K-Means algorithm is to minimize the sum of squared distances, written in a math form, it looks like this:
$$J(X,Z) = min\ \sum_{z\in Clusters}\sum_{x \in data}||x-z||^2$$
If we have different distance metric, for ins... |
H: Should I consider feature scaling for all gradient descent based algorithms?
In the Coursera course machine learning in the section on Multivariate Linear Regression, Andrew Ng provides the following tips on gradient descent:
Use Feature Scaling to converge quicker
Get feature into an approx -1 < x < 1 range
Mea... |
H: How to fix class imbalance in training sample?
I was very recently asked in a job interview about solutions to fix an imbalance of classes in the training dataset. Let's focus on a binary classification case.
I offered two solutions: oversampling the minority class by feeding the classifier balanced batches of data... |
H: Convolutional Neural Networks layer sizes
I am trying to understand an article Backpropagation In Convolutional Neural Networks
But I can not wrap my head around that diagram:
The first layer has 3 feature maps with dimensions 32x32. The second layer has 32 feature maps with dimensions 18x18. How is that even poss... |
H: What is clustering used for?
I know that clustering can be used for unsupervised learning and some people told me for many more techniques, but I was left with no answer, when I asked for what else clustering is used.
AI: Labeling data is not always an easy task. There are occasion that the data in hand does not ha... |
H: Exploratory Data Analysis and selecting good predictor variables ?
In what way would exploratory data analysis aid in feature selection, other than to preprocess the data ? Say, if a bivariate analysis was conducted for each predictor variable w.r.t. the target variable, in what way would this help with feature sel... |
H: NLP grouping word categories
Suppose I have a dictionary:
{apple:large apple, apple:red apple, apple:aple, orange:mandarin, orange:orang, orange:blood orange}
and so on...
And then I want to replace a large document of entries with the keys. However, occasionally a new value will come up, i.e. {apple:green apple}
... |
H: How would one impute missing values for a Discrete variable?
How would one imputing missing values (without using the mode) for a discrete variable, e.g. a variable corresponding to a count.
AI: Apart from the methods @Media mentioned, here are some more:
Imputing with info from other variables
This method is to cr... |
H: Python - Get FP/TP from Confusion Matrix using a List
I using two different classifiers to predict a binary target (Random Forests and Decision Trees). Now I want to evaluate my model creating a confusion matrix. For example, for predicting the binary value using random forests I've:
training_features, test_feature... |
H: Applying machine learning algorithms to subset of attributes in dataframe
I have this huge mixed data set consisting of both numerical and categorical attributes which upon OneHotEncoding results into a data set with very high dimensionality.
Is it wise to apply machine learning algorithms like K-means clustering,... |
H: How to plot cost versus number of iterations in scikit learn?
One of the recommendations in the Coursera Machine Learning course when working with gradient descent based algorithms is:
Debugging gradient descent. Make a plot with number of iterations on the x-axis. Now plot the cost function, J(θ) over the number ... |
H: Train Accuracy vs Test Accuracy vs Confusion matrix
After I developed my predictive model using Random Forest I get the following metrics:
Train Accuracy :: 0.9764634601043997
Test Accuracy :: 0.7933284397683713
Confusion matrix [[28292 1474]
[ 6128 889]]
... |
H: Binning which variables?
I will try to implement a k-means algorithm over this dataset:
Team_Categorical CreditAmount_Numeric Retired?_Binary
A 15.3 1
B 12 0
C 6.2 1
In order to apply k-... |
H: What is the difference between cross_validate and cross_val_score?
I understand cross_validate and how it works, but now I am confused about what cross_val_score actually does. Can anyone give me some example?
AI: cross_val_score is a helper function on the estimator and the dataset.
Would explain it with an examp... |
H: What if MNIST dataset had another feature
MNIST is a famous data set of hand written digits. Suppose we knew who wrote digits for example, female, left handed, 25 yrs old.
How would I use these information in CNN in tensorflow? or any other library.
Digits are images and that what CNN handles well but gender, dom... |
H: How to compare Timeseries Sequences?
I have multiple time series sequences and I want for each new time series to find the most alike old one.
I found that I can use the sum of errors between points. Is this a good approach?
Is there a way to be able to compare sequences with different lengths (maybe a sequence lo... |
H: Matrix Confusion - Get Model Precision
I've this matrix confusion:
[9779 107]
[2227 148]
What is the accuracy of my model? My doubt is because the confusion matrix is calculated based on Test dataset so how can it evaluate the accuracy of my model?
Thanks!
AI: A confusion matrix gives you the following:
[TP, FP]... |
H: Watermark detection in Python
I have a lot of images and I would like to be able to classify them into two groups: one containing images with watermarks and one containing images without any watermark.
There are about 40 different watermarks. I created "fake" watermarked images to train a CNN and it worked very wel... |
H: Dropout dividing by compensation term = overshoots the result?
When applying dropout mask, why is it acceptable to divide the resulting state by the percentage of survived neurons?
I understand that it's to prevent signal from dying out. But I've done the test, and found that it disproportionally magnifies the resu... |
H: Confusion Matrix - Get Items FP/FN/TP/TN - Python
After run my python code:
print(confusion_matrix(x_test, x_pred))
I get this:
[100 32
211 21]
My question is how can I get the following list:
True positive = 100
False positive = 32
False negative = 211
True negative = 21
Is this possible?
AI: Considering yo... |
H: Data augmentation: rotating images and zero values
A lot of people rotate images to create a larger training set for neural networks. For most nets, all of the inputs have to be the same size so the image rotation function has to crop the newly rotated images to match the input size. So, say you have $32\times32$ r... |
H: Classification of goods by category
i have labeled data with goods like:
"Double chamber refrigerator Hitachi R-WB 482 PU2 GBW".
I need to predict category like: laptops, household appliances etc.
How can i do this?
AI: Random forests should be able to handle categorical values natively so look for a different impl... |
H: rectangular markers in bubble plot (Python)
I would like to make a 'bubble' plot, but with rectangular markers. Is it possible to do this in Python?
On x-axis should be the day of the week (Mon, Tue, Wed,...), on y-axis - counts, how many times people came to a restaurant, the area of rectangles - the number of peo... |
H: Classification of very similar images
I have two groups of images, each one with 1000 samples.
The speckle pattern, in this context, is the same as a random pattern or "white noise" image. So these images are fundamentally different.
In group one, each figure is generated by considering a random function that retur... |
H: Train new data to pre-trained model
Let's say I've trained my model and made my predictions.
My question is... How can I append some new data to my pre-trained model without retrain the model from the beginning.
AI: I cannot comment yet. If you just load the model and use a fit method it will update the weights, n... |
H: Why use Gradient Descent when Gradient just solve the problem? (With Neural Nets)
My knowledge is that gradient actually gets to the global minimum and gradient descent try to take steps to the direction that he judges to be the lowest.
I know that calculate the gradient from complex functions is non trivial proble... |
H: Python - Feature Selection - Should I remove bad variables?
I've this code to print the importance of each variable on my model:
importances = trained_model.feature_importances_
std = np.std([trained_model.feature_importances_ for trained_model in trained_model.estimators_], axis=0)
indices = np.argsort(importances... |
H: Python - Calculate Cost profitability and benefit of the model
I've this code in Python in order to calculate the precision of my model and to print confusion matrix using Decision Trees Classifier:
coef_gini = DecisionTreeClassifier(criterion = "gini", random_state = 100, max_depth = 3, min_samples_leaf = 5)
coef_... |
H: Groupby product, return tuple
I have found out the most profitable products in my dataframe by using:
df.groupby('ProductName')['ProfitPerOrder'].sum().sort_values().tail()
It gives me the output below. each ProductName has a ProductCategory. How do I display the category next to the product name in the output bel... |
H: What is Teacher Helping technique?
I read this paper, but I am having trouble understanding what Teacher Helping technique (page 3) is in context of RNN.
Can someone explain to me what it is? Please assume I don't have much experience in statistics. I'll be glad if this explanation would be as simple as possible ... |
H: 'DecisionTreeClassifier' object has no attribute 'importances_'
I've this code in order to visualize the most important feature of each model:
dtc = DecisionTreeClassifier(min_samples_split=7, random_state=111)
rfc = RandomForestClassifier(n_estimators=31, random_state=111)
trained_model = dtc.fit(features_train, l... |
H: Words as features of a neural networks
I'm new in Machine learning and I'm working on a problem related to text. I know that in ML we can use features as numerical values as input to neural network, but I don't know how to use features as words. In some papers I read that we take features to be n words with some pr... |
H: Chi square distribution for feature selection
In one paper on ML I read that chi square distribution is used to reduce the number of features. In that paper, features are words. That paper is related to Sentiment Analysis, so we have "positive", "negative" and "neutral" category.
How to calculate chi square distri... |
H: Training neural network classifier with one class after another
Is it possible to train a neural network classifier with only one class, and after that with only another class?
For example, first train it only on recognizing dogs, and after finishing that training, only train it on recognizing cats, so in the end ... |
H: Data binning - Why we need to transform Categorical Variables?
Having a lot of categorical features and other numerics why we need to transform the categorical to binary values? Is it for using the values in mathematics functions of the algorithms?
Thanks!
AI: Yes. If you need the information of your categorical va... |
H: What type of regression should I use
I have a dataset that gives data on infertitlity and causes. The dataset is mainly 0,1 to represent "yes" and "no". However, some fields have "Sometimes", "Often" which would be represented by -1 or 2. I've only learnt how to do categorical data i.e. 1,0 and Numberical data. So ... |
H: Probability of dropout growth
In the DNN literature, is there analysis or a term on a dropout ratio (oppositely-)proportional to the depth of a layer?
By intuition, I'd like to dropout fewer neurons on the layers next to the input and drop more when approaching the end layers. For example, passing from a p_keep = 0... |
H: Unsupervised clustering without of Data which is supposed to be on a linear function
When I have a dataset where each datum has x and y,
and the (x,y) has a relation of one of y = a_i*x + b_i (i=1,2,...).
Is the process written below available? and which algorithm does it belong to?
The process is.....
I have many ... |
H: Clustering algorithm prior to model building?
I would like to understand, how a clustering algorithm can be used (if possible) to identify naturally occurring groups within a data set, prior to building predictive models/model, and to hence improve accuracy of models/model
AI: In clustering the outcome variable or ... |
H: How to create 3D images from .nii file
What are .nii files, and how is data stored in them? I have some of these and I want to know how can I create 3D image of MRI scan from them.
I can load the file in my python script using nibabel. Where to go from here next?
AI: The most common way of processing images in pyth... |
H: How to plot similarity of two datasets?
I'm performing some simulations, and at the end I get a CSV file with three columns. One column holds the values for the x-axis, which was also input to the simulation and theoretical calculations, second one holds theoretically expected values, and the other column holds the... |
H: PCA or cluster table of experimental fitness scores
I need to find patterns experimental data.
The columns are "experiments" which are chemical treatments for growth experiments. The rows are individual gene names, the values are a fitness-defect score, which reflect the genes contribution to growth.
I would like... |
H: When to remove outlier in preparing features for machine learning algorithm
I have a numeric variable (price) and it has a long tail in both training and test data sets. I found that if you remove the highest 1% of the value in both train and test data set for this variable, then the histogram of this variable in t... |
H: Cluster algorithm to group events in more general domains
I've a list of 1,300 news events, represented by only three terms coming from running LDA topic model on thousands of tweets. Here's some of them as an example:
['manchester,bony,city', 'attack,claims,responsibility', 'police,officers,nypd',
'goal,arsenal,l... |
H: Most Efficient Post Processing with Python and Pandas
This question is about best practices for working in Pandas dataframes. Speed, ease of use, and memory consumed could all impact any answers you might have. I start by pulling a data set into a dataframe like this:
Date Location Value
3/4/2018 1 ... |
H: How to use pca results for linear regression
I have a data set of 11 variables with allot of observations for each one. I want to make linear regression on the variables with the observed $\vec{y}=\alpha +\beta*\vec{X}$ when X is matrix. I'm trying to reduce my parameters so I activate pca algorithm on X. I get the... |
H: Do we need to increase training data size when increasing dropouts?
I am using a fully connected feed forward neural network built using keras for text classification. It consists of 3 hidden layer. I am planning to add a dropout layer after each hidden layer to prevent overfitting. While tuning the dropout rate, I... |
H: Purpose of weights in neural networks
I'm beginner at Neural Networks. After reading multiple articles on wikipedia, i've seen the term "weight" being used a lot, although it is a little confusing.
I know, that before the inputs are summed and passed to activation functions, they are separately weighted, after some... |
H: Multimodal distribution and GANs
What is intuition behind multimodal distribution? and
How does GANs generate samples from it?
AI: You can think of a multimodal distribution as a union of multiple unimodal distributions. In the case of GANs for image processing, each mode could be a category of images. To significa... |
H: How to structure data and model for multiclass classification in SVM?
I am trying to predict a categorial variable given a set of input variables, which are also categorical. Both the target and features variables only take the class values [below mean, mean, above mean].
I have used one-hot encoding on both the ta... |
H: MLPClassifier threshold factor to eliminate test samples that are not in match with train data
I am using MLPClassifer example from
scikit-learn
The code for training:
from sklearn.neural_network import MLPClassifier
X = [[0., 0.], [1., 1.]]
y = [0, 1]
clf = MLPClassifier(solver='lbfgs', alpha=1e-5,
... |
H: How does a Recommender System recommend movies to a New User?
Consider a New user which has never rated any movie on the Website or the System has never seen the user.
How does the System recommend Movies to the User and based on what ?
How will we evaluate the Recommendation , is the recommendation accurate or ap... |
H: Are the raw probabilities obtained from XGBoost, representative of the true underlying probabilties?
1) Is it feasible to use the raw probabilities obtained from XGBoost, e.g. probabilities obtained within the range of 0.4-0.5, as a true representation of approximately 40%-50% chance of an event occurring? (assumin... |
H: How to use correct weights in linear regression model
I'm trying to understand can we implement a simple linear regression model.
Let's say we are predicting price currencies. We want to know whether the currency will raise or not.
As i understand, we need to define two vectors for this:
$x=[1,2,3,4,5,6,7,8,9,10,11... |
H: Multi task learning architecture for Multi-label classification
I am working a classification problem. The dataset was collected from Painters by number, a competition hosted by kaggle. The task is to identify painter,style and genre given paintings.
So far, I trained individual models to predict painter,style,gen... |
H: Compare image similarity in Python
I'm using a dataset of movies and would like to group if a movie is the same across different retailers.
Example:
Movie: Beauty and the Beast
Platforms: Google, Netflix, iTunes, Amazon.
I have access to signals like:
Studio, Movie Name, Runtime, Language, Release Year, etc. Howeve... |
H: Card game for Gym: Reward shaping
I am working on a card game for openai gym and currently I ask myself how to shape the reward function for it. One round of the game consists of each player picking a card from its hand, whereas not every card can be played depending on the card which has been played by one of the ... |
H: Tactics to avoid feeling overwhelmed by machine learning
Short version: despite lots of reading, machine learning still feels like being a monkey in the dark. Any advice?
For background, I'm a researcher in computer science, in a field non-related to machine learning.
I have been trying to get more proficient in ma... |
H: Neural Network beginner level tutorial
I am trying to build a simple multi layer perceptron Neural Network in Java, but apparently my calculations are off. I am looking for a beginner-level tutorial which can help me to understand how to properly calculate forward and backward pass, preferably with examples.
AI: On... |
H: Finding optimal weights for models
I'm trying to implement an algorithm to find the minimal value of a function.
Before moving to sigmoid activation functions, i'm trying to understand linear regression.
Usually, a gradient descent algorithm is used to find an minimal value where the algorithm converges, but there ... |
H: How to maximize recall?
I'm a little bit new to machine learning.
I am using a neural network to classify images. There are two possible classes. I am using a Sigmoid activation at the last layer so the scores of images are between 0 to 1.
I expected the scores to be sometimes close to 0.5 when the neural net is no... |
H: Why adding combinations of features would increase performance of linear SVM?
I have a dataset of ~5000 elements represented by vectors composed by ~30 binary values (0 or 1)
on which I am performing binary classification with SVM with linear kernel (I use the Scikit learn lib).
For curiosity, I tried to add an ex... |
H: Multi-Class classification with CNN using keras - trained model predicts object even in a fully white picture
I built an multi classification in CNN using keras with Tensorflow in the backend. It nicely predicts cats and dogs. However, when it comes to an image which does not have any object-white background image-... |
H: How to compute precision and accuracy of a sequence that is not strictly binary?
Given a predicted sequence and actual sequence I want to compute it's precision and accuracy, for example: Note that these sequences will only contain 0, 1 or -1
predicted sequence: -1,0,1,1,-1,0,1,1,0,-1
actual sequence: -1,1,0,1,... |
H: Plots getting rid of whitespace
So I'm doing the Udemy course for Data Science in Python, and there's something weird happening with the plots. The first one in the above picture is mine, the second is the instructors.
How do I get rid of the white space on the sides, they seem to be default when using the plotti... |
H: Re: Logistic Regression
I am working on a dataset that has a dependent variable that is binary, but it contains 98% of 0's and 2% of 1's. I am trying to use Logistic regression to predict purchase of a product. But because of the huge number of 0's, the model is not predicting well and getting a large number of fal... |
H: How do I split number string with digit pattern?
I am trying to split number string to two to digit numbers
How do I get two different Numbers out that string
Example:
I want separate two numbers
x <- c("-26755.22-50150.60")
To this
-26755.22
-50150.60
I have tried stringr::str_split but I din't manage to kee... |
H: Performace of Fischer projection as dimension reduction compared to other LDA methods
How is the performance of Fischer projection compared to other LDA methods of dimension reduction? I thought that Fischer projection was a great method of dimension reduction by maximizing class separation, but when I looked at th... |
H: Get the probabilities of Tensorflow
Hi I am studying tensorflow for cifar-10 image classification using the code here
AI: I want to ask you that how to predict the probabilities of each class in test images.
At line 27 in the train.py you have the following code:
correct_prediction = tf.equal(y_pred_cls, tf.argmax... |
H: Word2Vec benefit in LSTM
if Word2Vec is nothing but a transformation of one-hot into a dense vector, why can't I just feed one-hot into LSTM (or for that matter sacrifice first dense layer, in any network that will end up using the embedding) and call it a day?
Why would I actually spend time pre-computing Word2Vec... |
H: Identify Bad Products from given parameters using neural networks
I have a problem at hand to identify Good/Bad Products using given parameters. The number of parameters are in the order of 5000s and there are multiple values for the parameters. However I do not have a labelled set of data which says these are the ... |
H: Could we use image hasing techniques for images classification tasks?
I have read some articles about image hashing, and I would like to know if we could apply this technique for general purpose images classification tasks.
Especially I would like to know which could be the drawbacks in using image hashing for this... |
H: How to use LSTM to make prediction with both feature from the past and the current ones?
Suppose I have a data frame with 2 columns, which are sales and promotions. I want to predict the next day sales based on the past sales and promotion info of 3 days, plus the promotion to be applied at the next day? How do I p... |
H: Feature selection vs Feature extraction. Which to use when?
Feature extraction and feature selection essentially reduce the dimensionality of the data, but feature extraction also makes the data more separable, if I am right.
Which technique would be preferred over the other and when?
I was thinking, since featu... |
H: Data Snooping, Information Leakage When Performing Feature Normalization
Assume that we have a training data set (with both features and labels) and a test data set (with only features).
When we build a machine learning model that requires normalization of the features, the correct way of doing normalization (to p... |
H: Proper/Possible methods for extracting unstructured data from websites
I'm working in Python, using Scrapy, and NLTK to try to understand how I can extract data from college websites.
My scraper can navigate through the university websites and find their tuition fees pages perfectly , but when trying to extract sp... |
H: Is correlation needed when building a model?
Some papers report the correlation between features when building a model and some don't. Is there a need to check the correlation between features and target feature? It won't be easy if the number of features is high.
AI: Not really, no. Sort of. It depends on how comp... |
H: How to optimize XGBoost performance accuracy?
I have dataset to predict customers dropout(yes,no), with 5 numerical features and 2 categorical features. I have applied a scaler to the numerical data and transformed the categorical features into dummies variables, creating 29 features. My dataset has shape of 6552 r... |
H: counting number of parameters keras
I'm implementing a 1D CNN in keras by following the keras tutorial on the same -
link. Once the model is built, when I execute model.summary(), I get the following output.
_________________________________________________________________
Layer (type) Output Shape... |
H: How to get rid of some parts in a string variable?
The original string is like this "965 - Vehicle parking area", how do I get rid of the "965 - " part in R? (There are two spaces before and after the dash.)
Thank you!
AI: One possibility is to use gsub function to find the first ' - ' and remove everything before ... |
H: Can't understand this simple matrix multiplication in python
Ok guys, I might be very tired here, but I can't figure out why this matrix multiplication by a scalar gives the following result (python)
Matrix named 'dx'
[ 1.6, 3.6, 0.4, 14.4, 25.6],
[10. , 10. , 0.4, 14.4, 3.6],
[ 0.4, 0... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.