Code Monkey home page Code Monkey logo

htestu's People

Contributors

idontgetoutmuch avatar nkartashov avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

htestu's Issues

Example fails to compile

I am probably missing something but I had to make the changes below to get the example to compile.

2 files changed, 5 insertions(+), 4 deletions(-)
doc/examples/TestGen.hs | 3 ++-
htestu.cabal            | 6 +++---

modified   doc/examples/TestGen.hs
@@ -1,8 +1,9 @@
 module TestGen where

 import System.Random (RandomGen, next, split)
-import Test.HTestU (runBatteryToResults, c_smallCrush, c_crush)
+import Test.HTestU (TestResult, runBatteryToResults, c_smallCrush, c_crush)
 import Test.HTestU.Streaming (nextStreamFromGen)
+import Test.HTestU.Wrapping (Battery)

 -- | Pretend that this a data type of a PRNG
 data TestGen
modified   htestu.cabal
@@ -31,11 +31,11 @@ source-repository head

 library
   exposed-modules:     Test.HTestU,
-                       Test.HTestU.Streaming
-  other-modules:       Test.HTestU.BatteryResult,
+                       Test.HTestU.Streaming,
+                       Test.HTestU.BatteryResult,
                        Test.HTestU.Wrapping
   other-extensions:    ForeignFunctionInterface, CPP
-  build-depends:       base >=4.7 && < 4.8,
+  build-depends:       base >=4.7 && < 4.9,
                        random

   hs-source-dirs:      src

fyi: hs code does wrong interval test

in the underlying c code, the logic for "bad" is if the P-value is too close to 0 OR 1,

   for (j = 0; j < N; j++) {
      if (pVal[j] < 0.0)          /* That test was not done: pVal = -1 */
         continue;
      if ((pVal[j] < gofw_Suspectp) || (pVal[j] > 1.0 - gofw_Suspectp)) {
         co++;
         break;
      }
   }

i'm making a wee fork that addresses this over on my github, but this means we're underestimating the failures in a certain sense

StdGen Fails Small Crush Test

For

runCrush crush = (\g -> runBatteryToResults nextStreamFromGen g crush ) `fmap` newStdGen

I get

./doc/examples/TestGen
[Fail,Fail,OK,OK,OK,Fail,Fail,OK,OK,OK,Fail,Fail,Fail,Fail,Fail]

Is this expected?

/Users/nikita_kartashov/Documents/Work/haskell/htestu/dist/build/lib/libprobdist.0.dylib referenced - why?

htestu $ stack exec ghci -- -Lcbits/testu/src/.libs -ltestu01
GHCi, version 7.10.3: http://www.haskell.org/ghc/  :? for help
<command line>: user specified .o/.so/.DLL could not be loaded (dlopen(cbits/testu/src/.libs/libtestu01.dylib, 5): Library not loaded: /Users/nikita_kartashov/Documents/Work/haskell/htestu/dist/build/lib/libprobdist.0.dylib
  Referenced from: /Users/dom/Dropbox/Private/Libraries/htestu/cbits/testu/src/.libs/libtestu01.dylib
  Reason: image not found)
Whilst trying to load:  (dynamic) cbits/testu/src/.libs/libtestu01.dylib
Additional directories searched:   cbits/testu/src/.libs

Why is a file on your computer being referenced? How do I load and run e.g. src/Test/HTestU.hs in ghci?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.