Re: map-par slower than map

2022-10-13 Thread Damien Mattei
ok , i think the problem comes both from my code and from guile parmap so. Obviously parmap could be slower on other codes because of the nature of list i think, it is hard to split a list in sublist and send them to thread and after redo a single list, i better use vector. As mentioned and forget

Re: http-request bearer token syntax for Twitter v2 api

2022-10-13 Thread Maxime Devos
On 12-10-2022 12:30, Mortimer Cladwell wrote: Hi, Has anyone successfully submitted a bearer token to Twitter v2 api using http-request? What syntax did you use? Without success I have tried many permutations/splellings/capitalizations of: Note that Guile sometimes sends uncapitalised headers

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
ok 'parallelization code and hash table' in google show no real solution, i have another idea,instead of function-unify-two-minterms-and-tag ,just unify the minterms and tag them (which use hash table) later out of the // region, after if it still sucks i will drop list for vectors, making it step

Re: map-par slower than map

2022-10-13 Thread Olivier Dion via General Guile related discussions
On Thu, 13 Oct 2022, Damien Mattei wrote: > ok , i think the problem comes both from my code and from guile parmap so. > Obviously parmap could be slower on other codes because of the nature of > list i think, it is hard to split a list in sublist and send them to thread > and after redo a single

Re: map-par slower than map

2022-10-13 Thread Olivier Dion via General Guile related discussions
On Thu, 13 Oct 2022, Damien Mattei wrote: > i trying to use your code but it seems there is a ) mismatch > somewhere? Right there's a missing ')' a the end to close the procedure, sorry about that. -- Olivier Dion oldiob.dev

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
i trying to use your code but it seems there is a ) mismatch somewhere? On Wed, Oct 12, 2022 at 11:55 PM Olivier Dion wrote: > On Wed, 12 Oct 2022, Damien Mattei wrote: > > Hello, > > all is in the title, i test on a approximately 3 element list , i got > > 9s with map and 3min 30s with par

Re: http-request bearer token syntax for Twitter v2 api

2022-10-13 Thread Ricardo Wurmus
Hi Mortimer, > Has anyone successfully submitted a bearer token to Twitter v2 api using > http-request? What syntax did you use? The validator for the Authorization header does not permit the “bearer” method with a single string. It expects that authentication methods other than Basic always p

Fwd: map-par slower than map

2022-10-13 Thread Damien Mattei
sorry google always do reply to single author... -- Forwarded message - From: Damien Mattei Date: Thu, Oct 13, 2022 at 1:56 PM Subject: Re: map-par slower than map To: Olivier Dion ah just at the end? i had noticed, but i get #unspecifeid ? so my new code is not good if your pr

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
the code did not worked when data length were more little than number of cpus (6 on my host) (iota 5) returns #unsepcified: scheme@(guile-user)> (use-modules (ice-9 threads)) scheme@(guile-user)> {v <+ (list->vector (iota 5))} #(0 1 2 3 4) scheme@(guile-user)> (par-map-vector sqrt v) scheme@(guile

Re: map-par slower than map

2022-10-13 Thread Olivier Dion via General Guile related discussions
On Thu, 13 Oct 2022, Damien Mattei wrote: > the code did not worked when data length were more little than number of > cpus (6 on my host) (iota 5) returns #unsepcified: Yeah sorry I miss indended the output and the rest. Here's a version that should work: --8<---cut here

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
i do not see what has changed in your code ? really strange,even with bad code the moment it crash should be the same, sometimes works,crash or freeze On Thu, Oct 13, 2022 at 2:41 PM Olivier Dion wrote: > On Thu, 13 Oct 2022, Damien Mattei wrote: > > the code did not worked when data length

Re: map-par slower than map

2022-10-13 Thread Olivier Dion via General Guile related discussions
On Thu, 13 Oct 2022, Damien Mattei wrote: > i do not see what has changed in your code ? Just copy it. Trust me it has changed. > really strange,even with bad code the moment it crash should be the same, > sometimes works,crash or freeze I don't get any of these problem .. running with (io

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
On Thu, Oct 13, 2022 at 4:06 PM Olivier Dion wrote: > On Thu, 13 Oct 2022, Damien Mattei wrote: > > i do not see what has changed in your code ? > > Just copy it. Trust me it has changed. > really ? :-) i read it 3 times line by line, yes the end is cut ,still no ending ) and i use it and freez

Re: map-par slower than map

2022-10-13 Thread Damien Mattei
ok i have the proof, this time (second time) the process stopped itself on your example ("processus stoppé " in french) : mattei@pc-mattei:~/Dropbox/git/library-FunctProg$ guile GNU Guile 3.0.1 Copyright (C) 1995-2020 Free Software Foundation, Inc. Guile comes with ABSOLUTELY NO WARRANTY; for det

Re: http-request bearer token syntax for Twitter v2 api

2022-10-13 Thread Mortimer Cladwell
Thanks Ricardo. I used your over-writes and modified my code below: (let* ( (uri "https://api.twitter.com/2/tweets";) (data "{\"text\":\"Hello world!\"}") (access-token "abcdemyaccesstoken") (my-headers `((Content-type . "application/json")(authorization . (bearer . ,access-token)) )) )