About 8,190,000 results
Open links in new tab
  1. What does .shape [] do in "for i in range (Y.shape [0])"?

    shape is a tuple that gives you an indication of the number of dimensions in the array. So in your case, since the index value of Y.shape[0] is 0, your are working along the first dimension of …

  2. Difference between numpy.array shape (R, 1) and (R,)

    Shape n, expresses the shape of a 1D array with n items, and n, 1 the shape of a n-row x 1-column array. (R,) and (R,1) just add (useless) parentheses but still express respectively 1D …

  3. Numpy Typing with specific shape and datatype - Stack Overflow

    Feb 14, 2022 · Currently, shape type information is reflected in ndarray.shape. However, most numpy functions that change the dimension or size of an array, however, don't necessarily …

  4. arrays - what does numpy ndarray shape do? - Stack Overflow

    Nov 30, 2017 · 82 yourarray.shape or np.shape() or np.ma.shape() returns the shape of your ndarray as a tuple; And you can get the (number of) dimensions of your array using …

  5. Pandas Dataframe ValueError: Shape of passed values is (X, ), …

    Pandas Dataframe ValueError: Shape of passed values is (X, ), indices imply (X, Y) Asked 12 years ago Modified 7 years, 8 months ago Viewed 60k times

  6. How to merge color, line style and shape legends in ggplot

    May 10, 2016 · It is often appropriate to have redundant shape/color group definitions. In many scientific publications, color is the most visually effective way to distinguish groups, but you …

  7. OpenCV shape matching between two similar shapes

    Apr 5, 2019 · OpenCV shape matching between two similar shapes Asked 6 years, 7 months ago Modified 3 years, 2 months ago Viewed 33k times

  8. Understanding the shape of spectrograms and n_mels

    Jun 26, 2020 · I am going through these two librosa docs: melspectrogram and stft. I am working on datasets of audio of variable lengths, but I don't quite get the shapes. For example: …

  9. python - Explaining the differences between dim, shape, rank, …

    Mar 1, 2014 · I'm new to python and numpy in general. I read several tutorials and still so confused between the differences in dim, ranks, shape, aixes and dimensions. My mind …

  10. How do I create an empty array and then append to it in NumPy?

    I want to create an empty array and append items to it, one at a time. xs = [] for item in data: xs.append(item) Can I use this list-style notation with NumPy arrays?