Hi Hugo,
I'm trying to get ritz-nrepl going with the latest lein2 and nrepl.el from
Melpa. I think I've followed the instructions on the project page, yet I
get this, when I nrepl-ritz-jack-in:
error in process sentinel: Could not start nREPL server: Exception in thread
"main" java.lang.ClassN
This course -- https://www.coursera.org/course/programdesign -- offered
next May will be taught in Racket. Racket is another Lisp-based language,
so you may find the concepts to transfer over to Clojure a little more
readily than those in the Scala class.
Brown University is also offering an onli
I'm enrolled in example course. This course is attempting to teach
functional constructs regardless of language, but the homework and examples
are done in Scala. If there were to be a Clojure course available, I would
prefer it to be more directly about Clojure than generalizations.
Currently,
On 21/09/12 17:42, Herwig Hochleitner wrote:
Sorry for the nitpick, but that would just have been (.setParallelism
pool 6), were it possible.
aaa yes of course... my brain has turned into mash!
(alter-var-root #'clojure.core.reducers/pool (constantly
(ForkJoinPool. 6)))
awesome!
:-) :-) :-
>
> (alter-var-root pool #(.setParallelism % 6))
>
Sorry for the nitpick, but that would just have been (.setParallelism pool
6), were it possible.
> I need to call the ctor and somehow rebind the 'pool' var to that object.
> How do I do that? any ideas?
(alter-var-root #'clojure.core.reducers
Stefan,
sthueb...@googlemail.com (Stefan Hübner) writes:
> a) Are you planning on updating Zi for this new release?
Yes. It might take a few days.
> b) How can ritz-nrepl or (preferably) ritz-swank be embedded in an
> application?
I just added instructions [1] to the ritz-swank README. I've n
Ok I can see there is a 'var-set' fn that seems to behave exactly as i
need...this is good stuff!
I can now do:
(var-set clojure.core.reducers/pool (ForkJoinPool. 6))
Jim
On 21/09/12 17:14, Jim foo.bar wrote:
On 21/09/12 16:54, Herwig Hochleitner wrote:
So if you're asking how to control t
On 21/09/12 16:54, Herwig Hochleitner wrote:
So if you're asking how to control the number of threads used for
folding: That's a constructor argument of ForkJoinPool, which defaults
to the number of available processors.
It's not currently exposed in the reducers API, but you could hack it
with
Ok, I got it. It was very interesting. The debugger never got to "
nrepl-server-sentinel". But the *nrepl-server* buffer said:
REPL started; server listening on localhost port 54922
Exception Unsupported option(s) supplied: :headless clojure.core/load-libs
(core.clj:5266)
clojure.core=>
The *n
TBH, I wasn't sure what exactly the question was. I'll assume for the rest
of this answer, that by 'opportunities for parallel execution' you mean
uses of fold.
So if you're asking how to control the number of threads used for folding:
That's a constructor argument of ForkJoinPool, which defaults
Hi Herwig,
Your suggestion doesn't really apply to my problem because the GA and
the minimax are completely separate...The GA runs in a fixed-size thread
pool which I'm in control of so i can easily set how many threads I want
the GA to spawn, so that is solved (at least theoretically!)...Now,
Hi Hugo,
I have two questions:
a) Are you planning on updating Zi for this new release?
b) How can ritz-nrepl or (preferably) ritz-swank be embedded in an
application?
Best Regards,
Stefan
Hugo Duncan writes:
> Ritz provides a clojure debugger for nREPL.el and SLIME, other nREPL
> middleware
Andy & Jim - thank you! This explains the whole thing perfectly.
Piotr
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient
As Andy indicated, it is almost never a good idea to wrap something
mutable in a reference type simply because the guarantees of references
do not hold for mutable things. In other words, the thing the ref points
to can be changed without going through the ref which defeats the whole
purpose of
Have you looked into work-stealing algorithms? Fork-Join (of which reducers
can take advantage) implements that. The basic idea is that you split your
work into delays (as in clojure.core/delay, called Tasks in Fork-Join)
where convenient in your algorithm and push them onto your work queue. You
th
15 matches
Mail list logo