From gwking at metabang.com Fri Oct 19 18:28:34 2007 From: gwking at metabang.com (Gary King) Date: Fri, 19 Oct 2007 14:28:34 -0400 Subject: [cl-variates-devel] Re: problem with cl-variates In-Reply-To: <20071017180216.GA11330@pu100877.student.princeton.edu> References: <20071013184602.GA6737@pu100877.student.princeton.edu> <20071017180216.GA11330@pu100877.student.princeton.edu> Message-ID: (cc'd to list) Hi Tamas, I'm still not sure what's up with the need for LIFT but I'm glad that things are working for you. I am just about to announce the CL-Variates simplification; if you upgrade / side-grade, please let me know if anything breaks. One downside of now have CL-MathStats is that I lose gamma-ln which means no Poisson distribution; I'm thinking of re-arranging things so that it's easier to do what makes sense. I would love to add the distributions that you mention to CL- Variates; please do send them along! On Oct 17, 2007, at 2:02 PM, Tamas K Papp wrote: > Hi Gary, > > I found that putting > > (require :lift) > > before (require :cl-variates) solves my problem. Perhaps it is a > dependency issue, and I didn't find any dependency on lift in > cl-variates.asd (but maybe something else should load it so it is not > an issue?) > > Since I use CL for quite a bit of numerical work, I would be very > interested in the simplification you mention, in the long run. In the > short run, I think I will send you extensions of cl-variates that I > find useful. Eg things like > > (defun lognormal-random (generator mean standard-deviation) > "Returns a lognormally distributed double-float pseudo random number > with using 'mean' and 'standard-deviation'." > (exp (normal-random generator mean standard-deviation))) > > and other distributions I use (I have some code for multivariate > normal, but that needs cleaning up). > > Thanks, > > Tamas > > > On Sun, Oct 14, 2007 at 02:00:10PM -0400, Gary King wrote: >> Hi Tamas, >> >> I've been unable to recreate the issue you found either in Allegro >> Common >> Lisp or SBCL (though I'm still on version 1.0). The error message is >> confusing because I don't see the LIFT package referenced anywhere >> within >> the file variates. One thing to try would be to see if (ASDF-) >> installing >> LIFT (my test package helps get through this). >> >> Also, as I was looking at CL-Variates again, I realized how little it >> actually relies on CL-MathStats or Metatilities. I'm now intending to >> simplify it so that using the package is easier. I don't know how >> long it >> will take me to realize this goal but if I know that you're >> interested, it >> may make me do something more quickly . >> >> Please let me know if you learn any more about what is causing the >> problem >> you're found and/or how to fix it. >> >> thanks, >> >> >> On Oct 13, 2007, at 2:46 PM, Tamas K Papp wrote: >> >>> Hi Gary, >>> >>> When trying to load cl-variates (installed with asdf-install, >>> everything went smoothly, using sbcl 1.0.9.0) I get the backtrace >>> >>> The name "LIFT" does not designate any package. >>> [Condition of type SB-KERNEL:SIMPLE-PACKAGE-ERROR] >>> >>> Restarts: >>> 0: [RETRY] Retry performing # on >>> #. >>> 1: [ACCEPT] Continue, treating # on >>> # as having been >>> successful. >>> 2: [ABORT] Return to SLIME's top level. >>> 3: [TERMINATE-THREAD] Terminate this thread (#>> {AADF059}>) >>> >>> Backtrace: >>> 0: (SB-INT:%FIND-PACKAGE-OR-LOSE "LIFT") >>> 1: (SB-INT:FIND-UNDELETED-PACKAGE-OR-LOSE "LIFT") >>> 2: (SB-FASL::FOP-PACKAGE) >>> 3: (SB-FASL::LOAD-FASL-GROUP >>> #>> /var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> {B5CEA79}>) >>> 4: ((FLET SB-THREAD::WITH-RECURSIVE-LOCK-THUNK)) >>> 5: (SB-UNIX::CALL-WITH-LOCAL-INTERRUPTS >>> #>> {B73A639D}> >>> T) >>> 6: ((FLET SB-UNIX::WITHOUT-INTERRUPTS-THUNK) T) >>> 7: ((FLET SB-UNIX::RUN-WITHOUT-INTERRUPTS)) >>> 8: (SB-UNIX::CALL-WITHOUT-INTERRUPTS >>> #>> {B73A648D}>) >>> 9: (SB-THREAD::CALL-WITH-RECURSIVE-LOCK >>> #>> {B73A650D}> >>> #S(SB-THREAD:MUTEX >>> :NAME "big compiler lock" >>> :VALUE #)) >>> 10: (SB-FASL::LOAD-AS-FASL >>> #>> /var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> {B5CEA79}> >>> NIL >>> #) >>> 11: (SB-FASL::INTERNAL-LOAD >>> >>> #P"/var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> >>> #P"/var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> :ERROR >>> NIL >>> NIL >>> :BINARY >>> NIL) >>> 12: (SB-FASL::INTERNAL-LOAD >>> >>> #P"/var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> >>> #P"/var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl" >>> :ERROR >>> NIL >>> NIL >>> NIL >>> :DEFAULT) >>> 13: (LOAD >>> >>> #P"/var/cache/common-lisp-controller/1000/sbcl/local/home/ >>> tpapp/.asdf-install-dir/site/cl-variates/dev/variates.fasl") >>> 14: ((SB-PCL::FAST-METHOD ASDF:PERFORM >>> (ASDF:LOAD-OP ASDF:CL-SOURCE-FILE)) >>> # >>> # >>> # >>> #) >>> 15: ((LAMBDA >>> (SB-PCL::.PV-CELL. SB-PCL::.NEXT-METHOD-CALL. SB- >>> PCL::.ARG0. >>> SB-PCL::.ARG1.)) >>> # >>> # >>> # >>> #) >>> 16: ((LAMBDA ())) >>> 17: ((FLET SB-THREAD::WITH-RECURSIVE-LOCK-THUNK)) >>> 18: (SB-UNIX::CALL-WITH-LOCAL-INTERRUPTS >>> #>> {B73A68FD}> >>> T) >>> 19: ((FLET SB-UNIX::WITHOUT-INTERRUPTS-THUNK) T) >>> 20: ((FLET SB-UNIX::RUN-WITHOUT-INTERRUPTS)) >>> 21: (SB-UNIX::CALL-WITHOUT-INTERRUPTS >>> #>> {B73A69ED}>) >>> 22: (SB-THREAD::CALL-WITH-RECURSIVE-LOCK >>> #>> {B73A6A6D}> >>> #S(SB-THREAD:MUTEX >>> :NAME "big compiler lock" >>> :VALUE #)) >>> 23: (SB-C::%WITH-COMPILATION-UNIT #) >>> 24: (ASDF:OPERATE ASDF:LOAD-OP :CL-VARIATES) >>> 25: (ASDF::MODULE-PROVIDE-ASDF :CL-VARIATES) >>> 26: ((LAMBDA (#:G[REQUIRE]18)) ASDF::MODULE-PROVIDE-ASDF) >>> 27: (SB-IMPL::%MAP-FOR-EFFECT-ARITY-1 >>> # >>> (ASDF::MODULE-PROVIDE-ASDF SB-IMPL::MODULE-PROVIDE-CONTRIB)) >>> 28: (REQUIRE :CL-VARIATES NIL) >>> 29: (SB-INT:SIMPLE-EVAL-IN-LEXENV (REQUIRE :CL-VARIATES) #>> LEXENV>) >>> 30: ((LAMBDA ())) >>> 31: ((LAMBDA (SWANK-BACKEND::FN)) #) >>> 32: (SWANK::CALL-WITH-BUFFER-SYNTAX #>> {AAAD995}>) >>> 33: (SB-INT:SIMPLE-EVAL-IN-LEXENV >>> (SWANK:INTERACTIVE-EVAL "(require :cl-variates)") >>> #) >>> 34: ((LAMBDA ())) >>> 35: ((LAMBDA (SWANK-BACKEND::HOOK SWANK-BACKEND::FUN)) >>> # >>> #) >>> 36: ((LAMBDA ())) >>> 37: ((LAMBDA (SWANK-BACKEND::HOOK SWANK-BACKEND::FUN)) >>> # >>> #) >>> 38: (SWANK::CALL-WITH-REDIRECTED-IO >>> # >>> #) >>> 39: (SWANK::CALL-WITH-CONNECTION >>> # >>> #) >>> 40: (SWANK::HANDLE-REQUEST #) >>> 41: (SWANK::CALL-WITH-BINDINGS NIL #) >>> 42: ((FLET SB-THREAD::WITH-MUTEX-THUNK)) >>> 43: (SB-UNIX::CALL-WITH-LOCAL-INTERRUPTS >>> #>> {B73A709D}> >>> T) >>> 44: ((FLET SB-UNIX::WITHOUT-INTERRUPTS-THUNK) T) >>> 45: ((FLET SB-UNIX::RUN-WITHOUT-INTERRUPTS)) >>> 46: (SB-UNIX::CALL-WITHOUT-INTERRUPTS >>> #>> {B73A718D}>) >>> 47: (SB-THREAD::CALL-WITH-MUTEX >>> # >>> #S(SB-THREAD:MUTEX >>> :NAME "thread result lock" >>> :VALUE #) >>> # >>> T) >>> 48: ((LAMBDA ())) >>> 49: ("foreign function: #x8063B4C") >>> 50: ("foreign function: #x8051DE1") >>> 51: ("foreign function: #x805B69D") >>> 52: ("foreign function: #xB7FB22D3") >> >> -- >> Gary Warren King, metabang.com >> Cell: (413) 559 8738 >> Fax: (206) 338-4052 >> gwkkwg on Skype * garethsan on AIM >> >> >> >> -- Gary Warren King, metabang.com Cell: (413) 559 8738 Fax: (206) 338-4052 gwkkwg on Skype * garethsan on AIM