Questions tagged [math]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
1answer
11 views

How to calculate similarity between 2 users based on the images they share?

Say there are 2 users, A and B, and they each shared 10 images (in some social media site), which I have collected in 2 folders separately. I want to calculate the similarity between the 2 users based ...
0
votes
1answer
14 views

How to train neural network a math multiplication table?

I am trying to train neural network (brain.js) a multiplication table. It is not going too well: requires lots of hidden layers, iterations and very small error threshold, and the results are still ...
0
votes
0answers
6 views

Projecting 3D Chemical Data Onto a 2D Plane in Motion

I'm trying to model the rotation of two hydrogen atoms about a carbon atom. Say I have a conceptual wheel on an axle that is attached to my car. The axle is described by two points in 3D space, as ...
0
votes
0answers
19 views

How to convert google trend relative values into more “absolute” values?

Searching key words or terms on google trends provides a time series of relative search numbers. I want to be able to analyse these trends more accurately compared to general trends in the same ...
1
vote
2answers
36 views

The exact meaning of cost function ? (Machine Learning)

I'm reading the "Python Machine Learning" book by Sebastian Raschka, and we use different cost functions. For Adaline model (with a linear activation function) we use the MSE error : (Phi is the ...
2
votes
2answers
42 views

Formal math notation of masked vector

I'm struggling to write my algorithm in a concise and correct way. The following is an explanation for an optimizer's update step of part of a vector of weights (not a matrix in my case). I have a ...
2
votes
2answers
19 views

Notation for features (general notation for continuous and discrete random variables)

I'm looking for the right notation for features from different types. Let us say that my samples as $m$ features that can be modeled with $X_1,...,X_m$. The features Don't share the same distribution (...
0
votes
1answer
22 views

when x is a vector, derivative of vector diag(f'(x)) is formal notation?

https://web.stanford.edu/class/cs224n/readings/gradient-notes.pdf (4) this note says this $$ \frac{\partial \textbf{z}}{\partial \textbf{x}} = \text{diag}(f'(\textbf{x})) $$ I know this means make ...
0
votes
1answer
31 views

Chain function in backpropagation

I'm reading a Neural Networks Tutorial. In order to answer my question you might have to take a brief look at it. I understand everything until something they declare as "chain function": It's ...
0
votes
1answer
11 views

Norm type in cost function of ANN

I'm reading a tutorial about ANN. They use the following cost function: As you can see this equation includes a norm. I'm new to the concept of norm. My question is what kind of norm they use here (...
0
votes
1answer
29 views

Relationship between log-odds and weighted sums in Logistic Regression

I've read several articles/tutorials on Logistic Regression and I've come across this idea of log-odds being equal to the weighted sum of features. i.e. if $p$ is the probability of a sample ...
0
votes
0answers
45 views

What is “position” in CNN (im2latex) for Positional Encoding?

I'm trying to build a model that maps images of math formulas into LaTeX markup. I found an acticle (https://arxiv.org/ftp/arxiv/papers/1908/1908.11415.pdf) that proposes an encoder-decoder ...
0
votes
0answers
7 views

how to write a learning set with different element indexes?

we assume we have a set $U=\{u_1,...,u_N\}$ , a set $T=\{u_1,...,t_M\}$ and a set $E=\{e_1,...,e_P\}$. I'm going to write down the training set mathematically to a learning machine, the size of ...
0
votes
1answer
22 views

When can you reorder log operations?

For example, you can reorder a softmax + nl (negative likelihood) to log_softmax + nll (negative log-likelihood) Essentially changing log(softmax(x)) to softmax(log(x)) However, what are the ...
1
vote
1answer
36 views

How are the channels handled in CNN? Is it independently processed or fused?

Let's assume that we are talking about 2D convolutions applied on images. In a grayscale image, the data is a matrix of dimensions $w \times h$, where $w$ is the width of the image and $h$ is its ...
0
votes
0answers
11 views

What is the difference between “letter”-dimensional vector types?

What is the difference between D-dimensional vectors and S-dimensional vectors? Are there any other "letter"-dimensional vectors which one should be aware of? I am reading about occupancy modeling ...
1
vote
1answer
24 views

What level of math is required for machine learning research

There are several levels of math understanding: Know the math Know the intuitions behind math concepts Know the intuitions and proofs of math concepts Know the intuitions, proofs of math concepts and ...
2
votes
1answer
31 views

Encoding correlation

I have rather theory-based question as I'm not that experienced in encoders, embeddings etc. Scientifically I'm mostly oriented around novel evolutionary model-based methods. Let's assume we have ...
3
votes
1answer
185 views

Need of maxpooling layer in CNN and confusion regarding output size & number of parameters

In my CNN architecture for binary classification, I have 2 convolutional layers, 2 maxpooling layers, 2 batchnormalization operations, 1 RELu and 1 fullyconnected layer. Case1: When the number of ...
0
votes
0answers
22 views

How to calculate precision and recall?

There is a class-imbalanced labeled dataset with 100'000 samples. 90'000 is "0" and 10'000 is "1". There is a model that predicts the labels. It was runned on the class-balanced (10'000 of "0" and 10'...
3
votes
1answer
192 views

How to find the various matrix sizes in designing a CNN

I am trying to understand CNN especially the maths and working mechanism using Matlab as the coding language. I have few confusion regarding the concept and the associated programming and will be ...
0
votes
1answer
35 views

Why multiply by 2 when calculating partial derivatives during backpropagation?

I'm wondering why we multiple by 2 when calculating partial derivatives. I'm referencing the 2's that I've circled below, from here. We also see this in the python implementation, ...
1
vote
0answers
12 views

Question regarding: Vectorization Math of Backpropagation in a Neural Network

Formula: These are the formula I use for backpropagation from Brilliant: Question: If we consider a Neural Network with the structure (3,2): And we would start calculating the derivative (for 1 ...
0
votes
0answers
6 views

What is the best approach (and why) to identify a conic section given the the points along its cross-section and its vector magnitudes over time?

I have an N-body simulation that calculates the position, velocity, and acceleration of each body at every frame over the course of some duration. As an example, I tested the algorithm using our solar ...
0
votes
1answer
26 views

Python - Appending a new Dataframe column that is a function of two separate numerical columns

I have a dataset that gives me the geographic coordinates of residential properties. My goal is to append a new column to this dataframe that shows the properties' distances to various prominent ...
0
votes
1answer
308 views

Does this line in Python indicate that KNN is weighted?

Does this line in Python indicate that KNN is weighted? clf = KNeighborsClassifier(n_neighbors=5, metric='euclidean', weights='distance') Are the weights the ...
1
vote
0answers
25 views

How to Manually Classify using SVM?

Consider points x1 = (1,1), x2=(1,0), x3=(1,-1) from class C1 and points x4 = (-1,1), x5=(-1-1) from class C2. Classify the given data with SVM How do we manually classify data by finding the ...
0
votes
1answer
26 views

Can continuous dataset have negative values? [closed]

As in the description, I want to choose continuos dataset with temperatures and the minimun value is -40 and maximum is 51. Is that OK? Can we have negative values in continuous distribution?
0
votes
0answers
20 views

Static and Dynamic neural networks process

Neural networks can be classified into static (convention feedforward networks) and dynamic categories (RNN, LSTMs). ...
1
vote
0answers
58 views

Transitioning from Math PhD to ML research [closed]

I am currently a Math PhD about to defend in January. I work in a field in functional analysis that uses a lot of measure theory (but no stats). I have been considering transitioning careers since I ...
1
vote
0answers
40 views

Convergence speed of perceptron algorithm

I was reading the convergence proof for the perceptron algorithm. It says under the assumption that there are some $R$, $\theta^*$ with $|\theta^*| = 1$ and $\gamma > 0$, such that $y_t(x_t\cdot \...
0
votes
0answers
16 views

Is this interpretation of spectral normalisation mathematically correct?

Hello everyone, this is my first post. I was thinking about the mathematical interpretation for spectral normalization in neural networks the other day, and I came up with an explanation that feels ...
1
vote
1answer
39 views

SVM hyperplane margin

so that $H_0$ is equidistant from $H_1$ and $H_2$. However, here the variable $\delta$ is not necessary. So we can set $\delta=1$ to simplify the problem. $$w\cdot x+b=1 $$ and $$w\cdot x+b=−1$$ Why ...
0
votes
2answers
393 views

Solving Bayes Theorem equation -> I can't calculate proper result

I am solving questions for an edx course on Machine Learning. One particular question is giving me a problem: Assume a patient comes into the doctor’s office to test whether they have a particular ...
0
votes
1answer
331 views

Understanding REINFORCE loss

The loss used in REINFORCE algorithm is confusing me. From Pytorch documentation : loss = -m.log_prob(action) * reward We want to minimize this loss. If a ...
1
vote
2answers
129 views

Skew and Kurtosis are so similar?

I've been taking the histogram of the optical flow in videos and plotting the kurtosis and skewness of each frame. At the end of the video, I noticed that the skewness and kurtosis follow each other - ...
0
votes
2answers
69 views

How to learn certain Maths to understand machine Learning papers?

I have done the deeplearning.ai course on deep learning. But I cannot Understand equations like minGmaxDV(D,G)=Ex∼pdata(x)[logD(x)]+Ez∼pz(z)[log(1−D(G(z)))] ...
1
vote
1answer
29 views

Choose points to maximize volume of convex hull

Suppose I have N points (labeled 1, 2, ..., k, ..., N) in D dimensions. I'd like to choose ...
1
vote
0answers
67 views

How to determine percent contribution to classification in logistic regression?

I'm trying to understand the contribution of each feature towards a specific classification. Let's say I have clients as my data and their features are income, debt and age. We're trying to predict ...
1
vote
1answer
84 views

bias variance decomposition for classification problem

It is given that: MSE = bias$^2$ + variance I can see the mathematical relationship between MSE, bias, and variance. However, how do we understand the mathematical intuition of bias and variance for ...
1
vote
0answers
19 views

How to add extra constraints to an equation?

Background: I have an equation which looks like as follows: $W \times P = R$ $\left[\begin{array} &{1}&{0}&{0}&-\frac{w_{1}}{w_{o1}} &\dots &{0} &-\frac{w_{1}}{w_{0} } \\...
2
votes
2answers
52 views

Neural networks, optimization math intuition

When I look into the following partial derivative, I see it as being the key element of any optimization algorithm out there. Correct me if I'm wrong, but this gets us the slope of the loss function, ...
5
votes
1answer
128 views

Estimating the value of $\pi$ with a Monte Carlo dartboard: $<$ or $\leq$?

I'm trying to figure out which is the proper way to estimate $\pi$ using the Monte Carlo method randomly distributing points in a square that also contains an inscribed circle. Some sources say to ...
3
votes
1answer
117 views

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 ...
1
vote
1answer
729 views

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 ...
1
vote
1answer
39 views

Meaning of this notion in 0-1 loss?

I am reading a paper and encountered this notion: $$1_{\{Y=1\}}$$ To me it seems to be the expression as below, but I am not entirely sure and I don't think the author explictly explained it: <...
0
votes
1answer
16 views

Looking for help calculating a probability formula

How do I put this into a calculator or a excel spreadsheet formula. I have never done this math before, but I want to figure it out.
0
votes
2answers
26 views

compare log and division of numbers

What is the difference between (a) taking the logarithm of a set of numbers (b) dividing the set of numbers by an integer. Both appear to reduce the scale of set of numbers, so can they be used ...
0
votes
1answer
15 views

What is the first tool to learn start your your data science projects? [closed]

What is the first tool to learn start your your data science projects?
3
votes
1answer
128 views

How can positional encodings including a sine operation be linearly transformable for any offset?

In the paper "Attention is all you need" the authors add a positional encoding to each token in the sequence (section 3.5). The following encoding is chosen: $ PE(pos, 2dim) = sin(pos / 10000 ^ {2dim/...