Skip to main content
Filter by
Sorted by
Tagged with
2 votes
2 answers
101 views

The following seems to work: import pandas as pd import sklearn df = sklearn.datasets.load_iris() df = pd.DataFrame(df.data, columns=df.feature_names) df.shuffle() However this shuffle function seems ...
robertspierre's user avatar
2 votes
1 answer
84 views

I have the following Dataframe, which contains, among others, UserID and rank_group as attribute: UserID Col2 Col3 rank_group 0 1 2 3 1 1 1 5 6 1 ... 20 1 8 ...
Carlo Allocca's user avatar
0 votes
0 answers
35 views

As you can see in the example I have 6 elements "other-news" (colored Fuchsia) on the right side of the grid stacked in 3x2 format. I want to be able to bring them to the left side and keep ...
Bart Zakkenwasser's user avatar
1 vote
1 answer
72 views

I have the following markup: <div class=""> <div class="tiled-gallery__gallery"> <div class="tiled-gallery__row columns-1"> <div class=&...
lharby's user avatar
  • 3,337
1 vote
1 answer
484 views

This question is inspired by the discussion in this link: When is shfl.sync.idx fast?, where it was debated whether __shfl_sync() and other warp-level shuffle instructions operate directly on the ...
xwt1's user avatar
  • 25
0 votes
1 answer
63 views

Let's say I have a 3D numpy matrix M with shape (c, b, a). I want to shuffle a specific cell (x, y) in M along the z-axis --- that is, I want to shuffle the array [M[z][y][x] for z in range(c)] and ...
StarDust's user avatar
  • 143
0 votes
1 answer
79 views

Using the default arguments, what is the time complexity of sample? I.e. how does the running time of sample(1:N) grow with N? Documentation for sample is here but does not specify time complexity.
Mohan's user avatar
  • 9,223
0 votes
2 answers
61 views

Thanks very much in advance. I have a numpy array called X_test X_test.shape (11829, 16, 9) I am trying to shuffle the 2nd column of each element of the array with the code below. However, X_test_s ...
eng's user avatar
  • 3
0 votes
2 answers
178 views

I am having trouble adding random images to the page by using a floating action button. After drawing an image from the .shuffle list, I want to draw another picture from the list. I could add more ...
Zoey's user avatar
  • 1
0 votes
0 answers
2k views

I've been working on a SOC project, and part of my task is to design a technical architecture using open-source tools. During my research, I stumbled upon a highly useful architecture proposed, ...
Tø' To's user avatar
  • 37
-1 votes
1 answer
278 views

I'm working with Spark and encountering an unexpected sort operation during a join of two pre-sorted and bucketed tables. Both tables have been created with the same number of buckets and are sorted ...
zqert's user avatar
  • 11
0 votes
0 answers
69 views

I have a large HDF5 file containing a single table. The table itself contains collections of ordered data that themselves are quite large but are stored contiguously in blocks. I need to shuffle the ...
Ray's user avatar
  • 13
-1 votes
1 answer
42 views

I want to write a class "SomeClass" that stores a shuffled version of the list it is initialised with. However, the list is shuffled in exactly the same way for every instance of my class. ...
3nondatur's user avatar
  • 475
-1 votes
1 answer
176 views

Was looking for shuffling an array from within Unity, remembered that .NET 8 has Random.Shuffle. It turns out that the implementation is the Fisher-Yates algorithm. But when looking at it and at ...
aybe's user avatar
  • 16.8k
2 votes
1 answer
211 views

Given the following df: data = {'Org': ['Tom', 'Kelly', 'Rick', 'Dave','Sara','Liz'], 'sum': [3, 4, 4, 4, 5, 5]} df = pd.DataFrame(data) # Org sum # 0 Tom 3 # 1 Kelly 4 # 2 ...
hadji's user avatar
  • 97
1 vote
0 answers
55 views

When running Spark App I've noticed that fetchBlocks function of both NettyBlockTransferService and my custom ShuffleClient (implementing BlockStoreClient) are being called. I know what my ...
Brave's user avatar
  • 329
1 vote
1 answer
84 views

I have two arrays like below: A from 1 to 4 repeated 8 times, B from 1 to 8 repeated 4 times. I want to shuffle B but with one correlation condition on the final Matrix. I don't want the same B value (...
Ammoinna's user avatar
3 votes
2 answers
151 views

Is there an algorithm that can be used as pseudo random value generator as if the sequence was produced by shuffling ? By that I mean that in a set of k values and k generator calls each value is ...
chmike's user avatar
  • 22.4k
0 votes
1 answer
441 views

Newbie here; I have a <QuizPage /> component with a child component called <TriviaObject /> which holds three properties; a question, a correct answer with a string value, and an array of ...
AlmondButter's user avatar
0 votes
1 answer
149 views

I want to shuffle answer options from Trivia API only when loading a new question, not every time a user selects an answer. Currently, the answers shuffle each time a user makes a selection. For ...
AranAli's user avatar
  • 57
2 votes
1 answer
190 views

Whilst reading Programming in Lua book, I came across an exercise which I'm not sure if I solved right, hence I wanted to ask you all. Problem statement: Exercise 6.4: Write a function to shuffle a ...
maniac's user avatar
  • 23
0 votes
0 answers
106 views

I am currently in the process of developing a module that involves a product archive. I've chosen to implement shuffle.js for this purpose, but I've encountered some issues along the way. My objective ...
Bent's user avatar
  • 159
0 votes
2 answers
149 views

Setup Items in a set have a weight property that can be set by an admin user. Items with more weight are more likely to achieve top position in a randomized list served to public visitors. Every item ...
David's user avatar
  • 347
5 votes
1 answer
197 views

I want a string shuffling algorithm that takes the following arguments: void CRLimitedShuffle(char* Str, uint8_t MaxConsecutiveRepetition); The function should perform a random shuffle on the input ...
埃博拉酱's user avatar
-1 votes
1 answer
429 views

I have the following dataFrame The data is from csv file and I would like to shuffle in each rows this is my code that I imported csv file df = pd.read_csv('data1.csv',header=None, names=cols) ...
Earth's user avatar
  • 1

1
2 3 4 5
47