Questions tagged [n-dimensional]

n-dimensional involves computation in higher dimensions

Usually used in math,physics,machine learning and computer graphics. Its common to downgrade n-dimensional problems down to 4D/3D/2D/1D using techniques like:

  • projection
  • cross-section
  • PCA

either to lower the needed processing or storage power needed to handle it or to visualize or just to simplify.

110 questions
0
votes
1 answer

Python n-dimensional array combinations

Suppose an arbitrary number of arrays of arbitrary length. I would like to construct the n-dimensional array of all the combinations from the values in the arrays. Or even better, a list of all the combinations. However, I would also like the…
user2974951
  • 9,535
  • 1
  • 17
  • 24
0
votes
1 answer

N-dimensional array into single array?

I have an array of lists and I want to convert it into single dimensional array. I can do it with 2 "for" loops but one prohibition is that I have to do it as it was N-dimensional array. original_list = [[2,4,3,[1,2]],[1,5,6], [9], [7,9,0]]
0
votes
0 answers

Python image filter working on N spatial and M measurement dimensions

In short: I’m searching for a way to calculate a multidimensional custom image filter on more than one axis of values in python. What I mean is: With scipy’s ndimage, I can use ndimage.generic_filter to apply the custom function myfunc to an…
0
votes
1 answer

Access array[][]...[] element with N "[]" automatically

First I apologize if this question has already been asked. I've search for it but found nothing. Given the following code : RHO = RHOarray(D,nbInter) print(RHO) for k in range(N): for l in range(D): j=0 …
Tiranyk
  • 41
  • 8
0
votes
1 answer

Dealing with N-Dimensional slices in functions

I am trying to write some machine learning code in golang. I can't figure a way to have a function deal with a slice of N dimensions, as different dimensions would need to return different types. Here is an example function that splits a 2d slice…
Ryan McCauley
  • 207
  • 1
  • 8
0
votes
1 answer

Discretizing/binning of N-dimensional data in Matlab for visualization purposes

This one is really giving me a headache... I have a dataset consisting of X groups of particles each with some group-specific properties. Each of these groups contain a certain amount of particles with a given velocity distribution and each particle…
slvrbld
  • 103
  • 4
0
votes
3 answers

In C, how to write a N-dimensional nested for loop where N is variable

I need to write the statement: for ( int i1 = i1_min; i1 < width; ++i1 ) for ( int i2 = i2_min; i2 < i2_max; ++i2 ) for ( int i3 = i3_min; i3 < i3_max; ++i3 ) ... for ( int iN = iN_min; iN < iN_max; ++iN…
CAMILO HG
  • 183
  • 1
  • 9
0
votes
1 answer

Creating a customisable n dimension array

This is two questions in one; if I should be splitting them, please let me know. I have a spreadsheet of HR data and I'm going to be cutting it into various cross sections. Each row currently represents an employee, the year of that particular…
Daniel V
  • 1,305
  • 7
  • 23
0
votes
1 answer

How to convert Mat to matrix of dlib

I creating program using CNN where I need insert a matrix of 192 channels. This matrix (width: 32, height: 240, channels: 192, type: uchar) is stored in Mat (OpenCV). How convert Mat to dlib matrix? std::vector>…
gulliver
  • 86
  • 2
  • 9
0
votes
2 answers

R: Identifying outliers in 2D gaussian distribution

I have a two dimensional Gaussian distribution, and I am trying to identify outliers. This is not in the sense of outlier removals, but rather to identify samples that are the most dissimilar to the bulk. https://i.stack.imgur.com/x9H1E.jpg Do you…
Esben Eickhardt
  • 3,183
  • 2
  • 35
  • 56
0
votes
2 answers

C++ matrix of classes (pointer of pointers)

So I've encountered some problem in C++ (my first programming language was C). Let's say I have the following classes: 2 headers (rectangle and grid, assume that point class is fine and another assumption is that we don't need print functions…
Itay.V
  • 169
  • 1
  • 7
0
votes
1 answer

Cartesian product of arbitrary-dimensional coordinates in arbitrary-dimensional arrays

This is somewhat related to Numpy: cartesian product of x and y array points into single array of 2D points I'm looking for a concise way to create a cartesian product of two arrays with arbitrary dimensionality. Examples: Similar to the related…
0
votes
0 answers

Unexpected deviation from absolute value in Monte Carlo N dimensional integration in c++

I have written a code in c++ for Monte Carlo in tegration, which worked fine with my other functions when I used 2 dimensional integration. I generalized the code for N dimensional integration , in this particular case, I am taking n = 10. I am…
bhjghjh
  • 889
  • 3
  • 16
  • 42
0
votes
1 answer

Spline interpolation over 3 variables for scattered data in Python?

With other words I got a set of data-points (x,y,z) associated to a value b and I would like to interpolate this data as accurate as possible. Scipy.interpolate.griddata only can do a linear interpolation, what are the other options?
Odile
  • 33
  • 1
  • 10
0
votes
2 answers

n-dimensional matrix multiplication python

I'm doing a program in Python that multiplies two matrices of the dimension that the user enters. The problem I have is that the user must enter the values ​​for each line in the input and my program can only obtain a value for each input. I've…
Elias
  • 1