From 5cdb9b15563786195cc98cd87e7eb64151a519fc Mon Sep 17 00:00:00 2001 From: Justin Bedo Date: Thu, 8 Jan 2026 10:35:58 +1100 Subject: drop hashing scheme and use infinite precision ints --- src/PPL/Sampling.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/PPL/Sampling.hs') diff --git a/src/PPL/Sampling.hs b/src/PPL/Sampling.hs index d397ca8..256e67b 100644 --- a/src/PPL/Sampling.hs +++ b/src/PPL/Sampling.hs @@ -13,8 +13,8 @@ where import Control.Monad import Control.Monad.IO.Class import Data.IORef +import Data.Vector qualified as V import Data.Vector.Hashtables qualified as H -import Data.Vector.Unboxed qualified as V import Data.Word import Numeric.Log import PPL.Internal @@ -42,7 +42,7 @@ mh g p m = do yield (x'', w'') step g2 omega'' x'' w'' - mutate :: (MonadIO m) => StdGen -> IORef (HashMap Word64 Double, StdGen) -> m (IORef (HashMap Word64 Double, StdGen)) + mutate :: (MonadIO m) => StdGen -> IORef (HashMap Integer Double, StdGen) -> m (IORef (HashMap Integer Double, StdGen)) mutate g omega = liftIO $ do (m, g0) <- readIORef omega m' <- H.clone m -- cgit v1.2.3