anchor.diff:  
           let root = @"D:\a\data\marspec\MARSPEC_10m\ascii\"
           let paths = Directory.GetFiles(root, "*.asc")
  -        testRandomQuery "testAllMarspec10m" paths 100 1000 |> ignore
  +        testSimpleRandom "test simple AllMarspec10m" paths 100 1000 |> ignore
           // 39s 10000 * 10
           // 22s 1000 * 100
           // 17s 100 * 1000
  
positive.code:     let testGebco() =
          ignore // TODO
  
  module Test =
      let simpleReadWriteTest() = 
          let fileName = @"D:\temp\testSimpleReadWrite.sbg" // *.sbg simple binary grid
          let initial = [None;Some(Int32.MinValue+1);Some(Int32.MaxValue);None;Some(0);Some(1);Some(-1);None;Some(2);Some(213);None]
  
          SimpleReadWrite.writeValues fileName initial
          let expected = Seq.concat ([[initial.[4];initial.[3];initial.[4];initial.[4];initial.[2]];initial])
          let actual = SimpleReadWrite.readValues fileName (Seq.concat [[4L;3L;4L;4L;2L];[0L..(initial.LongCount()-1L)]])
          let result = Seq.zip actual expected |> Seq.forall (fun (a, b) -> a = b)
          printfn "Simple read write test returned %b" result
  
      let memoryMappedReadTest() =
          let fileName = @"D:\temp\testSimpleReadWrite.sbg" // *.sbg simple binary grid
          let initial = [None;Some(Int32.MinValue+1);Some(Int32.MaxValue);None;Some(0);Some(1);Some(-1);None;Some(2);Some(213);None]
          let expected = Seq.concat ([[initial.[4];initial.[3];initial.[4];initial.[4];initial.[2]];initial])
          let actual = MemoryMappedSimpleRead.readValues fileName (Seq.concat [[4L;3L;4L;4L;2L];[0L..(initial.LongCount()-1L)]])
          let result = Seq.zip actual expected |> Seq.forall (fun (a, b) -> a = b)
          printfn "Memory mapped read test returned %b" result
  
      let runall() =
          simpleReadWriteTest()
          memoryMappedReadTest()
          SbgReader.testSmallMarspec()
          SbgReader.testAllMarspec10m()
  Test.runall()
          
  
          
negative.code:         bitmap, values
  
      let convertTo extension converter inFileName outFileName =
          let outFileName = Path.ChangeExtension(outFileName, extension)
          if (not (File.Exists(outFileName))) then
              let (bitmap, values) = read inFileName
              converter (outFileName) bitmap (Seq.concat values) // (Seq.concat values) bitmap
          outFileName
  
      let convertToSimple = 
          convertTo ".sbg" (fun outfile _ values -> SimpleReadWrite.writeValues outfile values)
      
      let convertToSparse = 
          convertTo SparseReadWrite.valuesExtension SparseReadWrite.write
      
  module Reader =
      let simpleQuery indices fileName =
          //SimpleReadWrite.readValues fileName indices
          MemoryMappedSimpleRead.readValues fileName indices
  
      let sparseQuery indices fileName =
          SparseReadWrite.readValues fileName indices
  
  module Test =
      let simpleReadWriteTest() = 
          let fileName = @"D:\temp\testSimpleReadWrite.sbg" // *.sbg simple binary grid
          let initial = [None;Some(Int32.MinValue+1);Some(Int32.MaxValue);None;Some(0);Some(1);Some(-1);None;Some(2);Some(213);None]
  
          SimpleReadWrite.writeValues fileName initial
          let expected = Seq.concat ([[initial.[4];initial.[3];initial.[4];initial.[4];initial.[2]];initial])
          let actual = SimpleReadWrite.readValues fileName (Seq.concat [[4L;3L;4L;4L;2L];[0L..(initial.LongCount()-1L)]])
          let result = Seq.zip actual expected |> Seq.forall (fun (a, b) -> a = b)
          printfn "Simple read write test returned %b" result
  
      let memoryMappedReadTest() =
          let fileName = @"D:\temp\testSimpleReadWrite.sbg" // *.sbg simple binary grid
          let initial = [None;Some(Int32.MinValue+1);Some(Int32.MaxValue);None;Some(0);Some(1);Some(-1);None;Some(2);Some(213);None]
          let expected = Seq.concat ([[initial.[4];initial.[3];initial.[4];initial.[4];initial.[2]];initial])
          let actual = MemoryMappedSimpleRead.readValues fileName (Seq.concat [[4L;3L;4L;4L;2L];[0L..(initial.LongCount()-1L)]])
          let result = Seq.zip actual expected |> Seq.forall (fun (a, b) -> a = b)
          printfn "Memory mapped read test returned %b" result
  
      let sparseReadWriteTest() =
          let p = @"D:\temp\bathy_10m.asc"
          let (bitmap, values) = AsciiProvider.read p
          let p = AsciiProvider.convertToSparse p (Path.ChangeExtension(p, ""))
          let results = SparseReadWrite.readValues p [1L;1654L;649L;963L]
          ignore
  
  
      let testPrepareLoad converter fileName = 
          let sbg = Path.Combine(@"D:\temp\", Path.GetFileNameWithoutExtension(fileName))
          converter fileName sbg
  
      let testRandomQuery converter query name paths outerlen innerlen =
          printfn "START %s" name
          let sbgPaths = paths |> Array.map (testPrepareLoad converter)
          
          let r = new System.Random(1)
          let sw = new System.Diagnostics.Stopwatch()
  