text
stringlengths
83
79.5k
H: Loops in R programming, I want to update this Remaining column in this table below: How do I do this in R programming? I tried while (n.Remaining>0) { n.remaining <- n.total-n.expense} Desired Output: AI: in R you just need to do 10-cumsum(expense). This will give you the Remaining column
H: What is the possible range of SVR parameters range? I'm working on a regression problem. While tunning the Parameters of SVR I got the following values c=100, gamma= 10 and epsilon =100. For which I got 95 percent r-square. My question is what is the theoretical range of these parameters values.? AI: I support vect...
H: How to label overlapping objects for deep learning model training I am training yolov3 to detect a custom object (chickens). In a lot of my training images I have overlapping chickens (can only see a partial chicken etc). Is there a common practice for how to label the data (bounding box) in these cases? Should you...
H: The principle of LM deep model Language model(LM) is the task of predicting the next word. Does the deep model need the encoder? From the ptb code of tensor2tensor, I find the deep model do not contains the encoder. Or both with-encoder and without-encoder can do the LM task? AI: The goal of LM is to learn a probab...
H: Can a neural network compute $y = x^2$? In spirit of the famous Tensorflow Fizz Buzz joke and XOr problem I started to think, if it's possible to design a neural network that implements $y = x^2$ function? Given some representation of a number (e.g. as a vector in binary form, so that number 5 is represented as [1,...
H: Using Cross Validation technique for a CNN model I am working on a CNN model. As always, I used batches with epochs to train my model. When it completed training and validation, finally I used a test set to measure the model performance and generate confusion matrix. Now I want to use Cross Validation to train my m...
H: Supervised multiclass classification : is ANN a good idea ? or use other classifiers? I have a problem deciding what to use since i'm just beginning to creating predictive models. Let's say I have a training dataset with 5 or 6 features and a testing dataset. (With around 50k rows in training / 5k in testing). My s...
H: When to question output of model I'm unsure of how to ask a question without making it seem like a code review question. At what point does one question whether they've actually implemented the algorithm and-or model correctly? Getting spot-on results is great and all, but seems highly suspect. Also, what checks ca...
H: Action Recognition for multiple objects and localization I want to ask questions regarding the action detection on the video with proposed frames. I've used Temporal 3D ConvNet for the action recognition on video. Successfully trained it and can recognize action on videos. When I do inference, I just collect 20 fra...
H: Data Visualization with multiple dimension, and linear separability I have a dataset of two classes with several features, how can I visualise such data using Matlab to decide if it is linear separable or not? AI: You basically need a t-SNE plot, the t-SNE will convert the high dimensional feature vector (several f...
H: What skills do I need to become a data scientist? And how to show them? I have fimiliarized myself with the recommended most important concepts (Linear Algebra, Analysis, Phython, Numpy, Pandas, a bit of Statistics, Linear regression). For the last two, I don't know how deep it should go. I know what things mean an...
H: Creating new columns based on 3 column and create new data frame Heading Consider my data frame rs123 T C 0 0 1 1 0 0 1 0 0 1 0 0 rs124 T C 0 0 1 0 0 1 0 0 1 0 0 1 rs125 A A 1 0 0 1 0 0 1 0 0 1 0 0 Similarity, i have total 93 colu...
H: How do I create a data set that has a set of features for multiple options, with one option being the expected outcome? Most datasets I see are: feature 1, feature 2, feature 3, outcome Where outcome is binary e.g. if they are cancer positive outcome will be 1 and 0 if they don't have cancer. How do I create a dat...
H: multipying negated gradients by actions for the loss in actor nn of DDPG In this Udacity project code that I have been combing through line by line to understand the implementation, I have stumbled on a part in class Actor where this appears on line 55 here: https://github.com/nyck33/autonomous_quadcopter/blob/mas...
H: getting the weights of intermediate layer in keras I have an image dataset 376 classes each class has 15 pictures corresponds to a person. I would like to get the feature vector that corresponds to each person. What I have done is, after I compiled the model I then used this link as a reference to get the weights ...
H: What is Coarse-to-Fine in the context of neural networks? I read in many paper that mentions coarse-to-fine as a technique in deep learning, but I could never figure what exactly they mean. Is it related to multiscale inference, where they use coarse and fine input images? AI: "Coarse to Fine" usually refers to the...
H: How to choose between classification Vs regression approach? I need to predict the profitability of the products of a retailer. I can either predict the absolute value of the profit the products will make (continuous outcome) or predict whether the products will make a profit or not (categorical outcome). Is there ...
H: Game theory in Reinforcement Learning In one of the recent blog post by Deepmind, they have used game theory in Alpha Star algorithm. Deep Mind Alpha-Star: Mastering this problem requires breakthroughs in several AI research challenges including: Game theory: StarCraft is a game where, just like rock-paper-scisso...
H: Not able to interpret decision tree when using class_weights I'm working with an imbalanced dataset. I'm using a decision tree (scikit-learn) to build a model. For explaining my problem I've taken iris dataset. When I'm setting class_weight=None, I understood how the tree is assigning the probability scores when I...
H: How to approach a machine learning problem? I'm a beginner in machine learning, and no real statistical background ( just basic knowledge ). I comprehend half of what is said on forums about statistical methods and techniques for normalizing data and putting up plots to see data distribution. Anyway, i managed to c...
H: sklearn and pandas in AWS Lambda I made a front end where I would like to make REST calls to an AWS Lambda interfaced with AWS API Gateway. I dumped my model as a pickle file (and so my encoders) which I initially trained locally. I then stored these files in a S3 bucket. The problem is that I cannot import libra...
H: On the choice of LSTM input/output dimension for a spatio-temporal problem I am using LSTM neural networks from (R)Keras for a matter of spatio-temporal interpolation. I manage to get the network to output predictions but the results are not outstanding (very little improvement on validation loss). I am wondering a...
H: Which is better: GPT or RelGAN for text generation? Based on my understanding, gpt or gpt-2 are using language model loss to train and generate text, which do not contains GAN. So which is better: GPT vs RelGAN/LeakGAN/SeqGAN/TextGAN I am so confused about this question. AI: According to [Caccia et al., 2018], in ...
H: How to calculate which word fits the best given a context and possible words? I have this task for research purposes and searched a while for a framework or a paper which already took care of this problem. Unfortunately I don't find anything which helps me with my problem. I have a sentence like if the age of the ...
H: is it bad to have many different measurements for the same target variable? I'm working on a dataset that has repeated measurements for the same target variable. When I don't change anything and create model, cross validation overfits with 0.99 score but in testset it gives around 0.39. When I use mean, std, skew, ...
H: How to show percentage (text) next to the horizontal bars in matplotlib? I am using seaborn's countplot to show count distribution of 2 categorical data. Fine it works but I want the percentages to show on top of the bars for each of the plot. Please how do I do it? fig, ax = plt.subplots(1, 2) sns.countplot(y = df...
H: What does it mean for a prior to be improper It’s use will never result in a posterior distribution which integrates (or sums) to 1. ? AI: An improper prior doesn't integrate/sum to 1, hence it is not a proper probability distribution on its own. Depending on the likelihood, the posterior distribution may or may no...
H: What are the ways to partition a large file that does not fit into memory so it can later be fed as training data? Is there any other way to partition a large file that does not fit into memory so it can be fed as training data other than using spark? or hadoop? AI: Yes, of cause. But, it's insignificant, because S...
H: Normal distribution instead of Logistic distribution for classification Logistic regression, based on the logistic function $\sigma(x) = \frac{1}{1 + \exp(-x)}$, can be seen as a hypothesis testing problem. Where the reference distribution is the standard Logistic distribution where the p.m.f is $f(x) = \frac{\e...
H: VC dimension of hypothesis space of finite union of intervals I have the following concept: $$C = \left\{\bigcup_{i=1}^{k}(a_i, b_i): a_i, b_i \in {\Bbb R}, a_i < b_i, i=1,2,..,k\right\} $$ and was wondering how to determine the VC dimension of C? AI: VC dimension is defined for a hypothesis space $H$, e.g. a set ...
H: When does fitting happen in KNN? In training session, model fitting happens to reduce error. But does KNN do this? Reducing error only happens due to changing K value and number of features, isn't it? So training set and test set is only for do things below, right? Train model with training set Given test sample, ...
H: Can I accurately call sklearn.model_selection.train_test_split multiple times when data doesn't fit into memory? Consider a very large data set that doesn't fit into memory. Would I be able to get (nearly) the same behavior from multiple calls to train_test_split when calling train_test_split by passing batches of...
H: Building Image Dataset In a Studio I'm currently working in a problem of Object Detection, more specifically we want to count and differentiate similar species of moths. We are already testing some detection algorithms: YOLOv3 RetinaNet Mask R-CNN For the datasets, first we'll scrape the web for those images to ...
H: Calculating Feature Importance of Time Series Data I am new to time-series modeling, and I was wondering what the standard way of quantifying feature importances are in a time-series setting? What types of models allow for the greatest interpretation of the feature space? I am looking for something, which does not ...
H: Crop all written letters from image to form a website Above image has handwritten hindi / deavanagari letters all on a single image. Task is to Prepare a dataset from the given assignment.jpg image using image processing tools Idon't have clarity whether i can use photoshop editing tools like adobe photoshop e...
H: What are CRF (Conditional Random Field) Looking for language modeling, I have been finding CRF in a lot of places which is but looking online for the same isn't actually helping me a lot. I referred Edwin Chen's blog and Ravish Chawala's Medium article but rather than solving my problem, raises more question. Coul...
H: Optimizing vector values for maximum correlation I'm new to ML, linear algebra, statistics, etc. so bear with me on the terminology... I’m looking to find a vector that produces the maximum correlation for the relationship between 1) all relationships among dimensions of the vector (determined by subtraction) and 2...
H: Naive Bayes Classifier - Discriminant Function To classify my samples, I decided to use Naive Bayes classifier, but I coded it, not used built-in library functions. If I use this equality, I obtain nice classification accuracy: p1(x) > p2(x) => x belongs to C1 However, I could not understand why discriminant functi...
H: How do I identify clusters that match on categorical data? I am seeking some directions for a proper path to research the solve for this problem: My company made all our employees take a "StrengthFinders" test, which results in every employee being assigned their top five (ordered) "strengths" from a possible list ...
H: Why can decision trees have a high amount of variance? I have heard that decision trees can have a high amount of variance, and that for a data set $D$, split into test/train, the decision tree could be quite different depending on how the data was split. Apparently, this provides motivation for algorithms such as ...
H: Error: building keras model using LSTM I am trying to build a simple LSTM based model but I am getting "can't set attribute error" on the line to add LSTM layer to the model. I am unable to figure the reason as to why this error is appearing. This is the code I am using. left = Sequential() left.add(LSTM(64,activat...
H: Integrate remote sensing & GIS data in a CNN I am trying to develop a CNN model that takes as input a set of parameters derived from satellite imagery. What are the necessary steps to go through in order to make the Geotiff data acceptable as a valid input for a keras model? AI: Keras functional API can be used to ...
H: Can I create a good Speech Recognition Engine while having millions of recorded conversations? I have at my disposal millions of wav files containing recorded conversations between employees and clients, i'm doing some research on the possibility of creating a good speech recognition engine. I've tested Google's Sp...
H: Why does all of NLP literature use Noise contrastive estimation loss for negative sampling instead of sampled softmax loss? A sampled softmax function is like a regular softmax but randomly selects a given number of 'negative' samples. This is difference than NCE Loss, which doesn't use a softmax at all, it uses a ...
H: What should I observe when choosing which optimizer suits my Deep Neural Network model? I have trained my neural network model with optimizers such as RMSProp, AdaGrad, Momentum, and Adam. Currently, after running the code, I have printed out the Train and Test Accuracy of every epoch (50 in my case). However, I wo...
H: CNN output shape explanation I have the following sequential model: model = models.Sequential() model.add(Reshape(([1]+in_shp), input_shape=in_shp)) model.add(ZeroPadding2D((0, 2))) model.add(Conv2D(256, (1, 3),padding='valid', activation="relu", name="conv1",data_format="channels_first", kernel_initializer='glorot...
H: How to checkpoint by minibatch in Keras I know that I can use ModelCheckpoint in Keras for checkpointing a model every epoch (or every few epochs, depending on what I want). I am getting my data for each minibatch from a fit_generator, and it takes a very long time to evaluate each minibatch. I'd like to be able t...
H: Gradient descent with infinite gradient value Given a function $f(x)$ and $\frac{\partial f(x)}{\partial x_i}=\frac{f^2(x1,...,x_i+\pi/2,...,x_n)-f^2(x1,...,x_i-\pi/2,...,x_n)}{f(x)}$. When $f(x)\to0$, $\frac{\partial f(x)}{\partial x_i}$ could be infinitely large. ($f^2(x1,...,x_i+\pi/2,...,x_n)-f^2(x1,...,x_i-\pi...
H: Generalization bound (single hypothesis) in "Foundations of Machine Learning" I have a question about Corollary $2.2$: Generalization bound--single hypothesis in the book "Foundations of Machine Learning" Mohri et al. $2012$. Equation $2.17$ seems to only hold when $\hat{R}_S(h)<R(h)$ in equation $2.16$ because of ...
H: Why does TensorFlow convert my decoded image to float32 instead of uint8/16? I am using the following code to import a bunch of .png images and decode them using TensorFlow: from __future__ import absolute_import, division, print_function import tensorflow as tf import numpy as np import os tf.enable_eager_executi...
H: Compute specificity and sensitivity at certain thresholds I have the following table with predictive probabilities and true class labels: \begin{array}{|c|c|c|c|} \hline P(T=1) &0.54& 0.23 & 0.78 & 0.88 & 0.26 & 0.41 & 0.90 & 0.45&0.19&0.36 \\ \hline T&1&0 &0 &1 &0 &0& 1& 1& 0& 0\\ \hline \end{array} The question ...
H: How long would it take to become proficient in machine learning for someone with a non-statistical mathematical background? I am currently a postdoc and my PhD was in applied mathematics in the area of numerical analysis and electromagnetic/acoustic wave propagation. There was no statistical element to my PhD, it w...
H: Choosing a suitable learning rate based on validation or testing accuracy? I have simulated a neural network with different learning rate, ranging from 0.00001 to 0.1, and recording each test and validation accuracy. The result i obtained is as below. There is 50 epoch for each learning rate, and i note down the va...
H: How do I fit a curve into non linear data? I did an experiment in my Uni and I collected data $(ω,υ(ω))$ modeled by the equation: $$ v(ω)=\frac{C}{\sqrt{(ω^2-ω_0^2 )^2 +γ^2 ω^2}} $$ where $ω_0$ is known. Do you know how can I fit a curve to my data $(ω,υ(ω))$ ? and how to find the parameter $ γ $ through this proce...
H: An ambiguity in SVM equations about misclassified data I have encountered an ambiguity in SVM equations. As is stated in Chris Bishop's machine learning book, the optimization goal in SVM is to maximize this function: $$C\sum\limits_{n = 1}^N {{\xi _n}} + {1 \over 2}{\left\| w \right\|^2}$$ Subject to this constra...
H: Aggregate NumPy array with condition as mask I have a matrix $b$ with elements: $$b = \begin{pmatrix} 0.01 & 0.02 & \cdots & 1 \\ 0.01 & 0.02 & \cdots & 1 \\ \vdots& \vdots & \ddots & \vdots \\ 0.01 & 0.02 & \cdots & 1 \\ \end{pmatrix} $$For which through a series of calculation which is vectorised, $b$ ...
H: Any suitable way to describe the distributions of 2 Pandas Dataframes visually/graphically? I am aware of the fact that the Pandas Dataframe's Statistical description can easily be obtained using df.describe(). I am having 2 dataframes of the same dimensions (i.e. 102 columns and 800000 rows for both the dataframes...
H: Prove two equations are equivalent I'm reading Neural Networks and Deep Learning and running into trouble with the math. One of the exercises says: Write out $a'=\sigma (wa + b)$ in component form, and verify that it gives the same result as the rule $$\frac{1}{1 + \exp(-\sum_{j}w_jx_j - b)}$$for computing the outp...
H: How to add date column in python pandas dataframe I want to add a date column (from 1/1/1979 upto the data is) in pandas data frame. Currently, my data frame looks like this: 0 1 2 3 4 0 1 654 31.457899 76.930397 0.2 1 1 711 31.507900 76.880402 0.2 2 1 712 31.507900 ...
H: Why do I need pre-trained weights in transfer learning? I am using a Mask-RCNN. I first chose the resnet50 backbone then downloaded COCO pre-trained weights. Why do I need pre-trained weights for transfer learning? The transfer learning approach is to train a base network and then copy its first layers of the targ...
H: Multi-output regression problem with Keras number of features: 12 , -15 < each feature < 15 number of targets: 6 , 0 < each target < 360 number of examples: 262144 my normalization: I normalized the features so that they are between 0 and 1. I normalized the targets so that they are between 1 and 10. This is the m...
H: How to "reshape" into square matrix for numpy.linalg.solve()? I'm trying to find the intersection of lines $y=a_1x+b_1$ and $y=a_2x+b_2$ using numpy.linalg.solve(). What I can't get my head around is how to correctly make $A$ a square matrix for solve() to work. I'm familiar with solving linear equation systems, bu...
H: Why margin-based ranking loss is reversed in these two papers? For knwoledge graph completion, it is very common to use margin-based ranking loss In the paper:margin-based ranking loss is defined as $$ \min \sum_{(h,l,t)\in S} \sum_{(h',l,t')\in S'}[\gamma + d(h,l,t) - d(h',l,t')]_+$$ Here $d(\cdot)$ is the predic...
H: What loss function to use for imbalanced classes (using PyTorch)? I have a dataset with 3 classes with the following items: Class 1: 900 elements Class 2: 15000 elements Class 3: 800 elements I need to predict class 1 and class 3, which signal important deviations from the norm. Class 2 is the default “normal” ...
H: Predicting descrete value problem in regression or classification In machine learning, regression algorithms attempt to estimate the mapping function (f) from the input variables (x) to numerical or continuous output variables (y). I have one usecase where I predict shift_id. Shit_Id is ID values given to different...
H: What is the range of values of the expected percentile ranking? I'm currently reading Hu, Koren, Volinsky: Collaborative Filtering for Implicit Feedback Datasets One thing that confuses me is the "expected percentile ranking", an function the authors define to evaluate the goodness of their recommendations. They ...
H: Connect Orange 3.20 to postgresql database I installed orange 3.20 on windows 7. It works so far, the problem is connecting it to a server-based Postgres database. While the connection can be made at the moment, when you try to load a table the message "missing extension quantile" comes up. A few problems are comin...
H: neural networks error function: is global minimum desirable? In "Elements of statistical learning" page 395 the authors state that, relative to R(θ), the regression/classification error function in a neural network such as a multi layer perceptron: Typically we don’t want the global minimizer of R(θ), as this is ...
H: Effects of L2 loss and smooth L1 loss Can any one tell me what the effects of $L_2$ loss and smooth $L_1$ loss (i.e. Huber loss with $\alpha = 1$) are, and when to use each of them ? AI: First, Huber loss only works in one-dimension as it requires $$\left\|\boldsymbol{a}\right\|_2=\left\|\boldsymbol{a}\right\|_1=\d...
H: Is it possible to achieve activity recognition on a single image? If so, can you give me resources? AI: The short answer, yes and even with a good performance, although not with same accuracy as with multiple frames. There are actually many different architectures that rely on classifying each single frame as part ...
H: Sentence similarity using Doc2vec I have a list of 50k sentences such as : 'bone is making noise', 'nose is leaking' ,'eyelid is down' etc.. I'm trying to use Doc2Vec to find the most similar sentence from the 50k given a new sentence. tagged_data = [TaggedDocument(words=word_tokenize(_d.lower()), tags=[str(i)])...
H: Is image sharpening a good idea for data augmentation? I'm training segmentation networks and while the dataset is somehow decent (~5k images) I wanted to augment it, so far I'm trying: RandomFlip RandomRotate RandomBrightness changes RandomShadows Due to constraints of the problem I can't do random crops or shif...
H: How to measaure the similarity between two series? I'm confused about how to measure the similarity between two time series with the same length. For example, both time series are 2 hours in length and every 5 minutes a point. I really want to know which Distance Algorithm should I use. I have tried the Euclidean D...
H: Training an acoustic model for a speech-to-text engine What are the steps for training an acoustic model? The format of the data (the audio) includes its length and other characteristics. If anyone could provide a simple example of how to train an acoustic model, it would be greatly appreciated. AI: This paper has ...
H: Rearranging data frame from column names to key value pairs If I have data like this in R: > a = data.frame(a = c(1, 2), b = c(3, 4)) > a a b 1 1 3 2 2 4 but I would like to have it like this: > b = data.frame(k = c("a", "a", "b", "b"), + v = c(1, 2, 3, 4)) > b k v 1 a 1 2 a 2 3 b...
H: Certainity of a classifier How to build a classifier that by default will predict that it is for class 1, but if the classifier believes with 80 certainity that it belongs to 0, it will be classed as 0. How to check how certain a classifier is on it's prediction. AI: Many classifiers will give the option to get pre...
H: Column With Many Missing Values (36%) Hello this is my first machine learning project, I got a dataset with 18.000 rows and I have a column with 4244 values missing. I don't know why the values are missing since when it's appropriate there's a 0 value in it. The dtype of the column is int64 I consider this column ...
H: Efficient self study plan I am hoping for a bit of guidance from experienced practitioners / academics. I want to work through the Bishop ML book, but have minimal background. What is the fastest way to get the pre-requisites (specific books would be appreciated)? From searching around I found this potential self-...
H: How to measure the similarity between two images? I have two group images for cat and dog. And each group contain 2000 images for cat and dog respectively. My goal is try to cluster the images by using k-means. Assume image1 is x, and image2 is y.Here we need to measure the similarity between any two images. what ...
H: Working ofLSTM with multiple Units - NER I am trying to understand working of LSTM networks and kind of not clear about how different neurons in a cell interact each other. I had a look at a similar question, but still not clear about few things. Assume an NER task where each time step get embedding on one word as ...
H: How can I access to loss value in Keras LSTM implementation? I use Keras library and it's LSTM model. When I train my network I can see loss value in my program execution console. I like to know how can I access to this value in my code? AI: You can access it by assigning a variable when calling fit hist = model.fi...
H: What are the disadvantages of having a left skewed distribution? I'm currently working on a classification problem and I've a numerical column which is left skewed. i've read many posts where people are recommending to take log transformation or boxcox transformation to fix the left skewness. So I was wondering wh...
H: In CycleGAN are there two different generators and two different discriminators? I am trying to assimilate the contents of this paper. I have a confusion about how many different networks are there in the architecture of CycleGAN. To my understanding, the concept of cycle means that there is only one generator and ...
H: How to see/change learning rate in Keras LSTM? I see in some question/answers that ask to decrease the learning rate. But I don't know how can I see and change the learning rate of LSTM model in Keras library? AI: In Keras, you can set the learning rate as a parameter for the optimization method, the piece of code ...
H: Generating Similar Words (or Synonyms) with Word Embeddings (Word2Vec) We have a search engine, and when users type in Tacos, we also want to search for similar words, such as Chilis or Burritos. However, it is also possible that the user search with multiple keywords. Such as Tacos Mexican Restaurants, and we also...
H: logistic regression : highly sensitive model I am a newbie to data science and ML. I am working on a classification problem where the task is to predict loan status (granted/not granted). I am running a logistic regression model on the data. The accuracy of my model is 82%. However, my model is more sensitive (sens...
H: Training a LSTM on a time serie containing multiple inputs for each timestep I am trying to train a LSTM in order to use it for forecasting. The problem is basically a multivariate multi-step time series problem. It is simply an experiment to see how statistical models (ARIMA, Holts-Winters, ...) and neural network...
H: Decovolution function I have an image (for example (7x7x3) and a filter (3x3x3)). I convolved the image with the filter and it became a (3x3) output. If I want to do the inverse operation and want it to become the image from the output and the filter. How can I implement this operation in Python with Numpy? I don't...
H: Why real-world output of my classifier has similar label ratio to training data? I trained a neural network on balanced dataset, and it has good accuracy ~85%. But in real world positives appear in about 10% of the cases or less. When I test network on set with real world distribution it seems to assign more positi...
H: How does GlobalMaxPooling work on the output of Conv1D? In the field of text classification, it is common to use Conv1D filters running over word embeddings and then getting a single value on the output for each filter using GlobalMaxPooling1D. As I understand the process, the convolutional filter is a matrix of t...
H: Keras + Tensorflow CNN with multiple image inputs I have a CNN that needs to take in 68 images that are all 59x59 pixels. The CNN should output 136 values on the output layer My training data has shape (-1, 68, 59, 59, 1). My current approach is to use concatenate to join multiple networks like so: input_layer = [N...
H: I received this error message: Found input variables with inconsistent numbers of samples: [15573, 15600]. How do I resolve it please? Data source I received that error and when running my code, I realised that the issue lies with my X_train and y_train. The link below is the source of my data (test.csv and train....
H: How to handle columns with categorical data and many unique values I have a column with categorical data with nunique 3349 values, in a 18000k row dataset, which represent cities of the world. I also have another column with 145 nunique values that I could also use in my model that represents product category. Can...
H: Choosing k value in KNN classifier? I'm working on classification problem and decided to use KNN classifier for the problem. so if k=131 gave me auc of 0.689 and k=71 gave me auc of 0.682 what should be my ideal k? Does choosing higher k means more usage of computational resource? if that's the case can I go with k...
H: Looking for other opinions on approach to classification problem I'm looking to implement an "opt-out" filter for my company. The input is short, text-message style messages. A few examples of opt-out messages are: "remove me from your list" "remove from list" "please unsubscribe from list" etc. All other message...
H: A trick used in Rademacher complexity related Theorem I am currently working on the proof of Theorem 3.1 in the book "Foundations of Machine Learning" (page 35, First edition), and there is a key trick used in the proof (equation 3.10 and 3.11): $$\begin{align*} &E_{S,S'}\left[\underset{g \in \mathcal{G}}{\text{sup...
H: what could this mean if your "elbow curve" looks like this? This is from running kmeans clustering with k on the x-axis (ranging from 2 to 10) and the silhouette distance on the y-axis. Clearly there's peaks at k=3, k=4 and it seems to decline from there. It doesn't resemble an elbow and thought it should rise as...
H: What are the criteria for updating bias values in back propagation? During back propagation, the algorithm can modify the weight values or bias values to reduce the loss. How does the algorithm decide whether it has to modify the weight values or bias values to reduce the loss? Does it modify the weight values in ...
H: What is "posterior collapse" phenomenon? I was going through this paper on Towards Text Generation with Adversarially Learned Neural Outlines and it states why the VAEs are hard to train for text generation due to this problem. The paper states the model ends up relying solely on the auto-regressive properties ...
H: What do we visualize in showing a VAE latent space? I am trying to wrap my head around VAE's and have trouble understanding what is being visualized when people make scatter plots of the latent space. I think I understand the bottleneck concept; we go from $N$ input dimensions to $H$ hidden dimensions to a $Z$ dime...