epfl-lts2 / pygsp

Graph Signal Processing in Python
https://pygsp.rtfd.io
BSD 3-Clause "New" or "Revised" License
483 stars 93 forks source link

Diag gird2d #47

Closed cgallay closed 5 years ago

cgallay commented 5 years ago

This PR add the ability to set the value of the diagonal to something else than zero in the grid graph. Here is an example output:

G = Grid2d(6, 7, diag_value=0.5)
G.plot()

diag_example

coveralls commented 5 years ago

Coverage Status

Coverage decreased (-0.09%) to 88.078% when pulling 18e999c9e780fd2b85bd9dce1c118d11a79a09e6 on cgallay:diag_gird2d into 7b3884bf8552470f8a74ca843fe866d67c77076b on epfl-lts2:master.

mdeff commented 5 years ago

Thanks @cgallay! Can you rename diag_value to diagonal? I prefer plain names over concatenated abbreviations. ;)

mdeff commented 5 years ago

Thanks!