Skip to content

Commit 4bafd2b

Browse files
authored
Merge pull request #64 from IgorErin/floattests
Float tests
2 parents 1ad11ad + b3f19f1 commit 4bafd2b

35 files changed

Lines changed: 1615 additions & 2111 deletions

File tree

benchmarks/GraphBLAS-sharp.Benchmarks/Helpers.fs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ open BenchmarkDotNet.Jobs
1414
open GraphBLAS.FSharp.Tests
1515
open FsCheck
1616
open Expecto
17+
open GraphBLAS.FSharp.Test
1718

1819
type CommonConfig() =
1920
inherit ManualConfig()
@@ -258,7 +259,7 @@ module Utils =
258259
module VectorGenerator =
259260
let private pairOfVectorsOfEqualSize (valuesGenerator: Gen<'a>) createVector =
260261
gen {
261-
let! length = Gen.sized <| fun size -> Gen.constant size
262+
let! length = Gen.sized <| Gen.constant
262263

263264
let! leftArray = Gen.arrayOfLength length valuesGenerator
264265

docsTool/templates/nav.fs

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -48,17 +48,16 @@ let navItemIconOnly link ariaLabel inner =
4848
]
4949

5050
let dropDownNavMenu text items =
51-
li [ Class "nav-item dropdown" ][
52-
a [
53-
Id (sprintf "navbarDropdown-%s" text)
54-
Href "#"
55-
DataToggle "dropdown"
56-
AriaHasPopup true
57-
AriaExpanded false
58-
Class "nav-link dropdown-toggle" ]
59-
[ normalizeStr text ]
60-
ul [ HTMLAttr.Custom ("aria-labelledby", "dropdownMenu1")
61-
Class "dropdown-menu border-0 shadow" ] items ]
51+
li [ Class "nav-item dropdown" ] [
52+
a [ Id (sprintf "navbarDropdown-%s" text)
53+
Href "#"
54+
DataToggle "dropdown"
55+
AriaHasPopup true
56+
AriaExpanded false
57+
Class "nav-link dropdown-toggle" ]
58+
[ normalizeStr text ]
59+
ul [ HTMLAttr.Custom ("aria-labelledby", "dropdownMenu1")
60+
Class "dropdown-menu border-0 shadow" ] items ]
6261

6362
let dropDownNavItem text link =
6463
li [

paket.lock

Lines changed: 141 additions & 314 deletions
Large diffs are not rendered by default.

src/GraphBLAS-sharp.Backend/Common/Utils.fs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
namespace GraphBLAS.FSharp.Backend.Common
22

3-
open Brahma.FSharp
4-
53
module internal Utils =
64
let defaultWorkGroupSize = 32
75

src/GraphBLAS-sharp.Backend/Matrix/Common.fs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,3 @@ module Common =
5151
valuesScatter processor positions allValues resultValues
5252

5353
resultRows, resultColumns, resultValues, resultLength
54-
55-

src/GraphBLAS-sharp.Backend/Predefined/PrefixSum.fs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ namespace GraphBLAS.FSharp.Backend.Predefined
22

33
open Brahma.FSharp
44
open GraphBLAS.FSharp.Backend.Common
5+
56
module internal PrefixSum =
67
let standardExcludeInplace (clContext: ClContext) workGroupSize =
78

src/GraphBLAS-sharp.Backend/Quotes/Convert.fs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,3 @@ module Convert =
2323
match rightItem with
2424
| Some _ -> (%op) leftItem None
2525
| None -> (%op) leftItem (Some value) @>
26-

src/GraphBLAS-sharp.Backend/Quotes/SubSum.fs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,3 @@ module SubSum =
3535
sumGeneral<'a> <| sequentialAccess<'a> opAdd
3636

3737
let treeSum<'a> opAdd = sumGeneral<'a> <| treeAccess<'a> opAdd
38-

src/GraphBLAS-sharp/Objects/VectorExtensions.fs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,3 @@ module ClVectorExtensions =
2222
Values = values
2323
Size = this.Size }
2424
| ClVector.Dense vector -> Vector.Dense <| vector.ToHost q
25-

tests/GraphBLAS-sharp.Tests/Algorithms/BFS.fs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ let testFixtures (testContext: TestContext) =
1616
[ let config = Utils.undirectedAlgoConfig
1717
let context = testContext.ClContext
1818
let queue = testContext.Queue
19-
let workGroupSize = 32
19+
let workGroupSize = Utils.defaultWorkGroupSize
2020

2121
let testName =
2222
sprintf "Test on %A" testContext.ClContext
@@ -40,7 +40,7 @@ let testFixtures (testContext: TestContext) =
4040
|> Utils.createArrayFromDictionary (Array2D.length1 matrix) 0
4141

4242
let matrixHost =
43-
Utils.createMatrixFromArray2D CSR matrix (fun x -> x = 0)
43+
Utils.createMatrixFromArray2D CSR matrix ((=) 0)
4444

4545
let matrix = matrixHost.ToDevice context
4646

0 commit comments

Comments
 (0)