times the number of
physical CPU cores), whereas the number of parallel tasks the work is
divided into could be limited only by memory for storing the tasks scheduled
for future execution.
Andy
On Tue, Oct 11, 2011 at 10:55 AM, j-g-faustus johannes...@gmail.comwrote:
On Tuesday, October
On Tuesday, October 11, 2011 3:55:09 AM UTC+2, Lee wrote:
Does your pmap-pool permit nesting? (That is, does it permit passing
pmap-pool a function which itself calls pmap-pool?). If so then that would
be a reason to prefer it over my pmapall.
I expect it would be possible to nest it
I made an alternative implementation using a thread pool and a queue, based
on the example at
http://clojure.org/concurrent_programming
In short, your pmapall and the pool-based implementation (below) both give
approximately
perfect scaling on my 4/8-core system (Intel i7 920 and HT).
Both
On Aug 9, 8:25 am, limux liumengji...@gmail.com wrote:
what's the meaning of
#^Server in the defn and let?
(defn #^Server run-jetty
...
(let [#^Server s (create-server (dissoc options :configurator))]
It's a type hint. In the defn it specifies the type of the return
value, in the let it
On Aug 7, 7:27 am, Meikel Brandmeyer m...@kotka.de wrote:
(defn to-env
[env-vars-map]
(- env-vars-map
(map #(str (name (key %)) = (val %)))
into-array))
And an invocation:
user= (to-env {:PATH /bin:/usr/bin :HOME /Users/mb :foo bar})
#String[] [Ljava.lang.String;@58c16b18
On Aug 7, 4:46 pm, Dave david.dreisigme...@gmail.com wrote:
(execute (str /../pdb_to_xyzr pdb-file /..)))
Here it seemed to run (the above error isn't shown) but nothing
happened and the REPL become unresponsive again.
I think the issue is that Runtime.exec doesn't start a shell, just
On Aug 7, 5:06 am, j-g-faustus johannes.fries...@gmail.com wrote:
I don't think there's a direct way to create a String array
in Clojure
Correction - there is: (into-array String [a b])
jf
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post
On Jul 23, 11:27 pm, .Bill Smith william.m.sm...@gmail.com wrote:
(filter #(and (f %) (g %) (h %)) my-list)
Here's another one, just to add to the collection:
(defn andp [ fns]
(fn [ args]
(every? #(apply % args) fns)))
(filter (andp f g h) my-list)
--
You received this message because
On Jul 24, 8:53 am, Mark Triggs mark.h.tri...@gmail.com wrote:
I cheated and used 'every?' :)
I was apparently too late. Oh well :)
--
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
You can safely ignore them.
What you are seeing is the startup log for the web/application server,
and it complains about the server log configuration.
But there's nothing there that stops the labrepl from working or that
you need to do anything about.
Regards
jf
On Jul 24, 6:58 am, Victor S
On Jul 20, 10:15 am, Laurent PETIT laurent.pe...@gmail.com wrote:
Oh, maybe I understand: by partial drafts, you mean pseudo-code,
directly written in clojure, is it this ?
It could be pseudo-code or partial implementations or code that is
more or less complete but won't compile because the
On Jul 20, 9:02 pm, Laurent PETIT laurent.pe...@gmail.com wrote:
Yeah. But again, please (I've asked this before, nobody answered), what do
you precisely mean by reload all in current REPL: a reload at the
namespace level ? Or really *only* reloading the vars you carefully and
manually sent to
I haven't tried CCW, but I am happy with Enclojure 6.8. (In 6.9 the
file navigator which lists the functions and vars in the file doesn't
work yet, and the navigator is perhaps 50% of the value I derive from
an IDE.)
Am 19.07.2010 um 20:50 schrieb Laurent PETIT:
If you work from the files,
On 17 Jul, 22:43, Isaac Hodes iho...@mac.com wrote:
It's just a shame, it seems to me, that there is such a nice way to
represent the procedure in Python or even C, yet Clojure (or any Lisp
really) struggles to idiomatically answer this question of
convolution.
I'll have to disagree with the
On 13 Jul, 01:28, j-g-faustus johannes.fries...@gmail.com wrote:
On Jul 13, 12:25 am, j-g-faustus johannes.fries...@gmail.com wrote:
I made my own cheat sheet for private use over the past month or so,
core functions only. It's at the 80% stage, I don't expect it will
ever be 100%, but I
On Jul 13, 8:37 pm, Paul Moore p.f.mo...@gmail.com wrote:
Can I suggest omitting the Table of contents sidebar when printing?
I've not tried printing the document to see how it looks, but removing
the sidebar would be an essential starting point...
Why would anyone want to print it?
I
The site looks very nice, I especially like the find real world
examples functionality and the fact that it collects documentation
for common non-core libraries as well.
I made my own cheat sheet for private use over the past month or so,
core functions only. It's at the 80% stage, I don't expect
On Jul 13, 12:25 am, j-g-faustus johannes.fries...@gmail.com wrote:
I made my own cheat sheet for private use over the past month or so,
core functions only. It's at the 80% stage, I don't expect it will
ever be 100%, but I have found it useful:
http://faustus.webatu.com/clj-quick-ref.html
On Jul 9, 5:58 am, Mike Meyer mwm-keyword-googlegroups.
620...@mired.org wrote:
The other non- project requirement (a page linking the project to the domain
name) is pretty much contrary to the quote from the Java specification.
By my reading, they are talking about something different - the
On Jul 9, 8:14 pm, James Reeves jree...@weavejester.com wrote:
Ruby and Rubygems has been using single-segment namespaces for years,
with no major problems. I don't think name clashes are a problem in
practise, because projects tend to have original names.
It works up to a point. It is claimed
On Jul 8, 5:21 am, Mike Meyer mwm-keyword-googlegroups.
620...@mired.org wrote:
You're overlooking that one of the major benefits of Clojure is that
it interoperates with other JVM languages. So any idiom it uses needs
to have some assurance that it won't clash with an idiom used by those
On Jul 7, 7:55 pm, James Reeves jree...@weavejester.com wrote:
For the purposes of this discussion, let us assume that foo is a
suitably unique library name, and it is highly unlikely there exist
any other libraries with the same name.
It sounds like Clojure doesn't have an idiom for namespace
On Jul 2, 3:44 am, Mike Meyer mwm-keyword-googlegroups.
620...@mired.org wrote:
On Thu, 1 Jul 2010 11:27:09 -0700 (PDT)
j-g-faustus johannes.fries...@gmail.com wrote:
Criterium, a benchmarking library for Clojure, seems pretty good:
The author responded here.
I noticed, my reply was sent
On Jul 2, 7:41 pm, Mike Meyer mwm-keyword-googlegroups.
620...@mired.org wrote:
On Thu, 1 Jul 2010 22:19:56 -0400
It depends on what you're benchmarking. If the loop time ... is
on the order of the same size as the standard deviation, then it can
fool you into falsely concluding that there's
chunk of the CPU time:
http://i589.photobucket.com/albums/ss334/j-g-faustus/profiling/eqv-arrays.png
From a practical standpoint I guess it means that deftype is the way
to go if you want fast numbers today.
In this case even the immutable deftype was faster than mutable Java
arrays, so you can
operations are done internally in a single
mutable deftype instance, but it is still very good - in this scenario
there was close to zero overhead from using Clojure.
On Jul 1, 4:29 pm, Nicolas Oury nicolas.o...@gmail.com wrote:
On Thu, Jul 1, 2010 at 2:27 AM, j-g-faustus
johannes.fries
On Jul 1, 6:24 pm, Heinz N. Gies he...@licenser.net wrote:
One reason here is that clojures literals as 1 2 and 3 you use for array
indexes are longs, the aget methods want int's
Agreed. If we can take the profiling snapshot I linked to at face
value, the boxing and casting adds up to ~40% of
On Jul 1, 5:42 pm, Greg g...@kinostudios.com wrote:
Ooo... sorry for the side-question, but I noticed that your code doesn't seem
to use coercions for primitives and uses type-hints instead.
I was just asking the other day on #clojure why Clojure had coercion
functions at all and why type
On Jul 1, 4:49 pm, Paul Moore p.f.mo...@gmail.com wrote:
(My biggest concern about an uberjar is that I end up with each app
having a separate bundled copy of all its dependencies. That makes
version management a huge pain - imagine a bugfix release of
clojure.jar - but is otherwise not an
On Jul 1, 7:51 pm, Peter Schuller peter.schul...@infidyne.com wrote:
Is anyone using anything more sophisticated than clojure.core/time for
benchmarking clojure code?
Criterium, a benchmarking library for Clojure, seems pretty good:
http://github.com/hugoduncan/criterium
Based on ideas in
and primitives cannot cross function boundaries?
That would explain the relative slowness of arrays.
Here is a test case http://gist.github.com/458669
And a profiler screenshot
http://i589.photobucket.com/albums/ss334/j-g-faustus/profiling/array-test-50k.png
15% CPU time goes to Double.valueOf(double
, Nicolas Oury nicolas.o...@gmail.com wrote:
On Wed, Jun 30, 2010 at 3:19 PM, j-g-faustus
johannes.fries...@gmail.comwrote:
The number of calls to Double.valueOf(double) seems to suggest that it
is called only on aset, not on aget, though I can't think of any
reason how that could be.
Does
OK, I'll try again. Thanks.
jf
On Jun 30, 6:14 pm, David Nolen dnolen.li...@gmail.com wrote:
On Wed, Jun 30, 2010 at 10:19 AM, j-g-faustus
johannes.fries...@gmail.comwrote:
Tried the equiv branch briefly: The 1.1 style version is ~4%
quicker, but still ~4x slower than Java and ~2x
-faustus/Clojure-test-code/
* 1.2 implementation:
http://github.com/j-g-faustus/Clojure-test-code/blob/master/shootout/nbody_type.clj
I haven't tried the new numeric branches, there seems to be a
sufficient number of people with opinions on those already :)
But I can add the observation
On Jun 29, 8:05 pm, j-g-faustus johannes.fries...@gmail.com wrote:
Definterface and defprotocol, on the other hand
Correction: definterface and deftype.
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to clojure
and deftype look promising, I'll try them out when I have
finished the 1.1 version.
Thanks for feedback,
jf
On Sat, Jun 26, 2010 at 6:56 PM, j-g-faustus
johannes.fries...@gmail.comwrote:
On profiling I have a bunch of intCast(Object) and doubleCast(double)
totaling ~9% CPU time
Possibly of interest here, although I've only tested it using Clojure
1.1:
I just did an implementation of the n-body problem from
http://shootout.alioth.debian.org/u32q/benchmark.php?test=nbodylang=all
The fastest code I've managed so far is here:
http://github.com/j-g-faustus/Clojure-test-code
OK. Thanks for the help to both of you.
Regards,
jf
On 13 Jun, 21:27, Meikel Brandmeyer m...@kotka.de wrote:
Hi,
Am 13.06.2010 um 19:50 schrieb Heinz N. Gies:
comment just is a function that says 'don't evaluate the stuff in here, it
still needs to be correct clojure code you can either
Hi,
I get an exception whenever I put a colon in a multiline comment:
(comment
TODO: x y z
)
= #CompilerException java.lang.Exception: Invalid token: TODO:
Is this a Clojure bug? Or related to Enclojure on NetBeans? Or some
sort of hidden feature in comments?
Regards
jf
--
You received
Thanks for responses and links.
It looks like I can't comment on those threads without signing up as a
Clojure contributor (by postal mail, even) which is a bit more
commitment than I'd like right now, so I'll post my comments here
instead.
I disagree with Stuart Sierra in the need proposal that
40 matches
Mail list logo