Skip to content

Random Sparse2dArrays#372

Open
andro2157 wants to merge 2 commits intoX-DataInitiative:masterfrom
andro2157:array2d_stuff
Open

Random Sparse2dArrays#372
andro2157 wants to merge 2 commits intoX-DataInitiative:masterfrom
andro2157:array2d_stuff

Conversation

@andro2157
Copy link
Contributor

  • Initialize Array2d with std::initializer_list using std::vector

Example :

ArrayULong2d array({
  {0,1,0},
  {1,0,1}
});

array = {
  {1,2,3,4}, {5,6,7,8}
};
  • Convert an Array2d into a SSparseArray2dPtr

@PhilipDeegan
Copy link
Member

The following is now possible

  auto random_sparse = SparseArray2d<double>::RANDOM(100, 100, .33);
  auto dense = random_sparse->as_array2d();
  auto sparse = dense.as_sparsearray2d();

@PhilipDeegan PhilipDeegan force-pushed the array2d_stuff branch 2 times, most recently from eb29ff1 to 12ecfcc Compare July 6, 2019 14:07
@PhilipDeegan PhilipDeegan force-pushed the array2d_stuff branch 3 times, most recently from e09a89a to 97a8d04 Compare May 17, 2020 12:11
@PhilipDeegan PhilipDeegan self-requested a review May 17, 2020 13:28
@PhilipDeegan PhilipDeegan requested review from Mbompr and removed request for MaryanMorel May 17, 2020 13:29
@PhilipDeegan PhilipDeegan changed the title Array2d Stuff Random Sparse2dArrays Feb 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants