Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Random Sparse2dArrays #372

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

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 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.

None yet

2 participants