Skip to content

Commit 1e84c10

Browse files
author
Wimmerer
committed
docstrings
1 parent 009c6f8 commit 1e84c10

File tree

5 files changed

+8
-10
lines changed

5 files changed

+8
-10
lines changed

docs/src/arrays.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,9 @@
11
# GBArrays
22

3-
There are two datastructures in in `SuiteSparseGraphBLAS.jl`: the `GBVector` and `GBMatrix`.
3+
There are two primary datastructures in in `SuiteSparseGraphBLAS.jl`: the `GBVector` and `GBMatrix`.
44

55
Both types currently implement most of the `AbstractArray` interface and part of the `SparseArrays`
66
interface.
7-
The goal is to cover the entirety of both (applicable) interfaces as well as `ArrayInterface.jl`
8-
with the `v1.0` release.
9-
10-
Most functions accept either type, which is represented by the union
11-
`GBArray = {GBVector, GBMatrix, Transpose{<:Any, <:GBMatrix}}`.
127

138
## Matrix Construction
149
```@setup mat

docs/src/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ GraphBLAS array types are opaque to the user in order to allow the library autho
5353
SuiteSparse:GraphBLAS takes advantage of this by storing matrices in one of four formats: dense, bitmap, sparse-compressed, or hypersparse-compressed; and in either row or column major orientation.
5454

5555
!!! warning "Default Orientation"
56-
The default orientation of a `GBMatrix` is by-row, the opposite of Julia arrays, for speed
56+
The default orientation of a `GBMatrix` is by-row, the opposite of Julia arrays, for greater speed
5757
in certain operations. However, a `GBMatrix` constructed from a `SparseMatrixCSC` or
5858
`Matrix` will be stored by-column. This can be changed using `gbset(A, :format, :byrow)`.
5959

src/import.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,10 @@ end
6262
"""
6363
GBMatrix(S::SparseMatrixCSC)
6464
65-
Create a GBMatrix from SparseArrays sparse matrix `S`.
65+
Create a GBMatrix from a SparseArrays.SparseMatrixCSC `S`.
66+
67+
Note, that unlike other methods of construction, the resulting matrix will be held by column.
68+
Use `gbset(A, :format, :byrow)` to switch to row orientation.
6669
"""
6770
function GBMatrix(S::SparseMatrixCSC)
6871
return GBMatrix{eltype(S)}(_importcscmat(S.m, S.n, S.colptr, S.rowval, S.nzval))

src/matrix.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"""
44
GBMatrix{T}(nrows = libgb.GxB_INDEX_MAX, ncols = libgb.GxB_INDEX_MAX)
55
6-
Create a GBMatrix with the max size.
6+
Create a GBMatrix of the specified size, defaulting to the maximum on each dimension, 2^60.
77
"""
88
function GBMatrix{T}(nrows = libgb.GxB_INDEX_MAX, ncols = libgb.GxB_INDEX_MAX) where {T}
99
GBMatrix{T}(libgb.GrB_Matrix_new(toGBType(T),nrows, ncols))

src/types.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ end
9595
"""
9696
GBMatrix{T} <: AbstractSparseArray{T, UInt64, 2}
9797
98-
TWo-dimensional GraphBLAS array with elements of type T. Internal representation is
98+
Two-dimensional GraphBLAS array with elements of type T. Internal representation is
9999
specified as opaque, but in this implementation is stored as one of the following in either
100100
row or column orientation:
101101

0 commit comments

Comments
 (0)