Tim Docker wrote:
Neal Alexander wrote:
I was using the HaskellCharts library and needed the same two things; so
i rolled a quick and dirty pie chart generator (Barchart is on the TODO
list).
http://72.167.145.184:8000/Screenshot.png
http://72.167.145.184:8000/PieChart.hs
Nice! Do you mind i
Achim Schneider wrote:
You don't come across space-leaks in strict programs often because
data is usually allocated statically even if execution is non-strict.
Piping /dev/zero into a program that just sleeps does leak space,
though.
It only leaks 8K or whatever size your system buffers pipe
I finally ditched sabayon for ubuntu (one wireless problem too many),
and now I'm slowly getting stuff set up on it. Any Ubuntu people care
to share their experiences? I'm especially looking for guidelines on
what to install via apt-get and what to install independently.
Also, while I'm making Maj
On Wed, 4 Jun 2008, John Melesky wrote:
> So you use those occurrence statistics to pick a feasible next word
> (let's choose "system", since it's the highest probability here -- in
> practice you'd probably choose one randomly based on a weighted
> likelihood). Then you look for all the word pai
On Wed, 4 Jun 2008, Andrew Coppin wrote:
> Henning Thielemann wrote:
> > Sounds like a generator for scientific articles. :-)
> > Maybe
> >http://hackage.haskell.org/cgi-bin/hackage-scripts/package/markov-chain
> > can be of help for you. It's also free of randomIO.
>
> That certainly looks
Neal Alexander wrote:
> I was using the HaskellCharts library and needed the same two things; so
> i rolled a quick and dirty pie chart generator (Barchart is on the TODO
> list).
>
>
> http://72.167.145.184:8000/Screenshot.png
> http://72.167.145.184:8000/PieChart.hs
Nice! Do you mind if I refact
Hello Andrew,
Thursday, June 5, 2008, 12:50:28 AM, you wrote:
> However, if you can find me a source that explains what a "Markov chain"
> actually *is*, I'd be quite interested.
*afaik*, the idea is simple: order-1 Markov chain is just text
generated with respect of probability of each char, an
Hello Henning,
Thursday, June 5, 2008, 12:55:19 AM, you wrote:
> Sounds like a generator for scientific articles. :-)
> Maybe
>
> http://hackage.haskell.org/cgi-bin/hackage-scripts/package/markov-chain
> can be of help for you. It's also free of randomIO.
once i've used something like this t
On 2008 Jun 4, at 22:30, Paul L wrote:
The server is then very much like a VM or an interpreter of an
embedded language, with execution stacks entirely encoded and stored
in each HTML page sent to the user and back from the user as an
encoded URL or form data. So the server is entirely stateles
"Ryan Ingram" <[EMAIL PROTECTED]> wrote:
> On 6/4/08, apfelmus <[EMAIL PROTECTED]> wrote:
> > Note that lazy evaluation never wastes time; evaluating a term with
> > lazy evaluation will always take less reduction steps than doing so
> > eagerly or partly eagerly.
>
> True, but you can still have
On Wed, Jun 4, 2008 at 3:23 PM, Lanny Ripple <[EMAIL PROTECTED]> wrote:
> You might want to skim Shannon's 'A Mathematical Theory of
> Communcations'. Part 1, Section 2 and 3 are almost exactly your
> topic. (Or at least the direction you've headed in. :)
>
> http://plan9.bell-labs.com/cm/ms/wha
"Paul L" <[EMAIL PROTECTED]> wrote:
> Does such a beast exist or am I entirely day dreaming?
>
Daydreaming, at least partly: Just consider state that can't be stored
client-side at all, e.g. the contents of a wiki page.
Networking or HTML as interface isn't the real problem: It's the
multi-headed
Pardon me to hijack this thread, but I have an idea to build a
different kind of Web Framework and am not sure if somebody has
already done it.
The idea is to take REST further: every HTML page you see is a program
in its running state (as a continuation monad). Each click on its link
or form subm
On 6/4/08, apfelmus <[EMAIL PROTECTED]> wrote:
> Note that lazy evaluation never wastes time; evaluating a term with lazy
> evaluation will always take less reduction steps than doing so eagerly or
> partly eagerly.
True, but you can still have a "time leak"; this is particularily
relevant in soft
On Wed, 2008-06-04 at 10:26 -1000, Tim Newsham wrote:
> I built darcs for win32 recently and it was much more difficult than
> it should be. Probably most of the blame goes to ghc-6.8.2 binary
> release for win32. Half of the effort is getting the zlib prereq
> working.
>
> Previously to build
On Wed, 2008-06-04 at 17:22 +0200, Achim Schneider wrote:
> The question, IMHO, seems to be
>
> "How would a package manager for a posix-compilant kinetic look like?"
http://nixos.org/index.html
Duncan
___
Haskell-Cafe mailing list
Haskell-Cafe@has
You might want to skim Shannon's 'A Mathematical Theory of
Communcations'. Part 1, Section 2 and 3 are almost exactly your
topic. (Or at least the direction you've headed in. :)
http://plan9.bell-labs.com/cm/ms/what/shannonday/shannon1948.pdf
-ljr
Andrew Coppin wrote:
> Henning Thielemann
On Jun 4, 2008, at 3:50 PM, Andrew Coppin wrote:
However, if you can find me a source that explains what a "Markov
chain" actually *is*, I'd be quite interested.
In a non-rigorous nutshell:
You have the word "star". You want to pick another word to follow it.
It turns out that, based on ana
Henning Thielemann wrote:
Sounds like a generator for scientific articles. :-)
Maybe
http://hackage.haskell.org/cgi-bin/hackage-scripts/package/markov-chain
can be of help for you. It's also free of randomIO.
That certainly looks interesting. Presumably if I train it right, it'll
figure
Am Mittwoch, 4. Juni 2008 22:26 schrieb Tim Newsham:
>
> Here's a small test program which uses FFI to SleepEx which I was
> not able to get working with win32 ghc-6.8.2.
>
> --
> {-# OPTIONS -fglasgow-exts -fffi #-}
> module Main where
> import Foreign.C.Types
>
> foreign import ccall "SleepEx
Andrew Coppin <[EMAIL PROTECTED]> wrote:
> Achim Schneider wrote:
> > Andrew Coppin <[EMAIL PROTECTED]> wrote:
> >
> >
> >> I have a file that contains several thousand words, seperated by
> >> white space. [I gather that on Unix there's a standard location for
> >> this file?]
> > Looking at /
Achim Schneider wrote:
Andrew Coppin <[EMAIL PROTECTED]> wrote:
I have a file that contains several thousand words, seperated by
white space. [I gather that on Unix there's a standard location for
this file?]
Looking at /usr/share/dict/words, I'm assured that the proper seperator
is \n.
Gregory Collins wrote:
Andrew Coppin <[EMAIL PROTECTED]> writes:
Clearly, what I *should* have done is think more about a good
abstraction before writing miles of code. ;-) So how would you guys do
this?
If you want text that roughly resembles English, you're better off
getting a corp
On Wed, 4 Jun 2008, Achim Schneider wrote:
> Gregory Collins <[EMAIL PROTECTED]> wrote:
>
> > Andrew Coppin <[EMAIL PROTECTED]> writes:
> >
> > > Clearly, what I *should* have done is think more about a good
> > > abstraction before writing miles of code. ;-) So how would you guys
> > > do this?
On Wed, 4 Jun 2008, Andrew Coppin wrote:
> How would you do this?
>
> The approach I came up with is to slurp up the words like so:
>
> raw <- readFile "words.txt"
> let ws = words raw
> let n = length ws
> let wa = listArray (1,n) ws
>
> (I actually used lazy ByteStrings of characters.)
Gregory Collins <[EMAIL PROTECTED]> wrote:
> Andrew Coppin <[EMAIL PROTECTED]> writes:
>
> > Clearly, what I *should* have done is think more about a good
> > abstraction before writing miles of code. ;-) So how would you guys
> > do this?
>
> If you want text that roughly resembles English, you
Sterling Clover wrote:
>> hvac sounds interesting but at that time at least it was not clear
>> whether it was stable or would continue to be maintained.
>>
>> xhtml and HStringTemplate were overkill for what I wanted, so I
>> wound up
>> just using the FastCGI and CGI toolkits themselves. They
Andrew Coppin <[EMAIL PROTECTED]> wrote:
> I have a file that contains several thousand words, seperated by
> white space. [I gather that on Unix there's a standard location for
> this file?]
>
Looking at /usr/share/dict/words, I'm assured that the proper seperator
is \n.
> Clearly, what I *shoul
Andrew Coppin <[EMAIL PROTECTED]> writes:
> Clearly, what I *should* have done is think more about a good
> abstraction before writing miles of code. ;-) So how would you guys do
> this?
If you want text that roughly resembles English, you're better off
getting a corpus of real English text and r
Hello Andrew,
Wednesday, June 4, 2008, 10:33:00 PM, you wrote:
> I have a file that contains several thousand words, seperated by white
> space. [I gather that on Unix there's a standard location for this
> file?] I want to end up with a file that contains a randomly-chosen
> selection of words.
I built darcs for win32 recently and it was much more difficult than
it should be. Probably most of the blame goes to ghc-6.8.2 binary
release for win32. Half of the effort is getting the zlib prereq
working.
Previously to build zlib for win32 ghc I did the following:
http://www.haskell.org/pip
So anyway, today I found myself wanting to build a program that
generates some test data. I managed to make it *work* without too much
difficulty, but it wasn't exactly "elegant". I'm curios to know how
higher-order minds would approach this problem. It's not an especially
"hard" problem, and I
s.clover:
> >
> >hvac sounds interesting but at that time at least it was not clear
> >whether it was stable or would continue to be maintained.
> >
> >xhtml and HStringTemplate were overkill for what I wanted, so I
> >wound up
> >just using the FastCGI and CGI toolkits themselves. They are
> >s
On Jun 4, 2008, at 5:51 AM, Henning Thielemann wrote:
How about assisting the compiler with a helper function named
'parallel' ?
parallel :: ([a] -> b, [a] -> c) -> [a] -> (b,c)
parallel (f,g) xs = (f xs, g xs)
mean xs =
uncurry (/) $ parallel (sum,length) xs
? We could state RULES in ter
hvac sounds interesting but at that time at least it was not clear
whether it was stable or would continue to be maintained.
xhtml and HStringTemplate were overkill for what I wanted, so I
wound up
just using the FastCGI and CGI toolkits themselves. They are
surprisingly nice, and with a lit
apfelmus wrote:
I haven't heard the terms "laziness leak" and "strictness leak" before,
imho they sound a bit spooky because it's not clear to me what the
situation without leak would be. (Time vs Space? Is an O(n) algorithm a
strictness leak compared to an O(log n) algorithm?)
"Leak" refers
Jon Harrop wrote:
IRL the specification often dictates the complexity. If your code fails to
satisfy the spec then it is wrong. Are you saying that Haskell code can never
satisfy any such specification?
In addition to RL, it it should and it can in theory too:
http://www.cs.toronto.edu/~hehne
Hi,
I've just uploaded hs-pgms to hackage. It is a Haskell implementation
of Programmer's Minesweeper [1], which allows programmers to implement
minesweeper strategies and run them. (Note: ghc >= 6.8 is required.)
hs-pgms uses MonadPrompt to achieve a clean separation between
strategies, game log
ICFP 2008 poster session
September 21, 2008
Call for presentation proposals
ICFP 2008 will feature a poster session for researchers and
practitioners, including students. The session will provide friendly
feedback for work that is in gestation or ongoing, as well as
opportunities to meet each oth
Loup Vaillant wrote:
> 2008/6/3 Darrin Thompson <[EMAIL PROTECTED]>:
>> On Sun, Jun 1, 2008 at 2:44 PM, Bertram Felgenhauer
>> <[EMAIL PROTECTED]> wrote:
>>> Hi,
>>>
>>> I'm pleased to announce yet another tool for importing darcs repositories
>>> to git. Unlike darcs2git [1] and darcs-to-git [2],
Greg Matheson wrote:
> On Tue, 03 Jun 2008, John Goerzen wrote:
>
>> Hi,
>
>> HDBC-odbc version 1.1.4.4 has been uploaded to Hackage. It fixes the
>> problems some here have encountered regarding ODBC crashes or other
>> similar odd behavior on Windows.
>
> I'm getting a 'Parse error in patter
Duncan Coutts wrote:
> On Tue, 2008-06-03 at 10:23 -0700, Don Stewart wrote:
>> A new version of happs was written on a Monday a couple of months ago,
>> using fastcgi and takusen. We're running it at galois, and you can
>> find the code on code.haskell.org/hpaste. So not quite what you wanted,
>>
Duncan Coutts <[EMAIL PROTECTED]> wrote:
>
> On Wed, 2008-06-04 at 15:14 +0100, Claus Reinke wrote:
> > > I think that's fundamentally the wrong approach. We shouldn't
> > > have to build a "Haskell installation manager". Would you also
> > > want installation managers for Perl, Python, Ruby, C
On Wed, Jun 4, 2008 at 10:14 AM, Claus Reinke <[EMAIL PROTECTED]> wrote:
> - it isn't sufficient to worry about installation management,
> one has to worry about integration, lifetime and uninstall
> management as well. in short, maintain the dependency
> graphs over any of "install"/"upgrade
On Wed, 2008-06-04 at 15:14 +0100, Claus Reinke wrote:
> > I think that's fundamentally the wrong approach. We shouldn't have to
> > build a "Haskell installation manager". Would you also want installation
> > managers for Perl, Python, Ruby, C, C++, etc. each with their own different
> > use
On Wed, 2008-06-04 at 15:25 +0200, Achim Schneider wrote:
> Well, you have a point but still don't have one. Many of gentoo's
> haskell .ebuilds are seriously outdated, eg. wxhaskell still depends on
> ghc 6.4. See "Damnit, we need a CPAN"
>
> The haskell overlay features about 240 packages from
I think that's fundamentally the wrong approach. We shouldn't have to
build a "Haskell installation manager". Would you also want installation
managers for Perl, Python, Ruby, C, C++, etc. each with their own different
user interfaces and feature sets? I think not - you want a single package
On Wed, Jun 04, 2008 at 02:22:07PM +0100, Duncan Coutts wrote:
> As I see it we need both. We need to make it easy to translate cabal
> packages into distro packages. We do have tools to do that at the moment
> for Gentoo, Debian and Fedora. I'm sure they could be improved.
>
> However we cannot e
On Wed, 4 Jun 2008, David wrote:
> I'm currently running ghc under Windows XP and want to play around
> with Haskore, but I'm a little confused about how to install it, or if
> it's even possible to use it with ghc. The 'readme' file contains this
> note:
You can also use Haskore with GHC. For a
Tim Docker wrote:
Peter wrote:
Has anyone got some code for drawing charts? I don't mean
graphs of functions, ala
http://dockerz.net/twd/HaskellCharts
...
I would like something that can generate PNGs in memory, i.e. not
directly to a file.
The library at the above URL supports a range of bac
Aaron Denney wrote:
On 2008-06-04, apfelmus <[EMAIL PROTECTED]> wrote:
<-- cut -->
Or the next->topic path relies on features from next that are not
present in master . But then, you're screwed anyway
Yep.
Well not really, depends what kind the dependency is, this kind of rebase
is us
Hi!
I'm currently running ghc under Windows XP and want to play around
with Haskore, but I'm a little confused about how to install it, or if
it's even possible to use it with ghc. The 'readme' file contains this
note:
"Note that the file ghc_add/IOExtensions.hs is a partial replacement of
a libr
Ketil Malde <[EMAIL PROTECTED]> wrote:
> Achim Schneider <[EMAIL PROTECTED]> writes:
>
> Caveat: I have only a vague grasp on what exactly is being criticized
> here - using a modern Linux distribution, tons of packages are
> available, and almost all issues Claus point out seem to be taken care
On Wed, 2008-06-04 at 11:33 +0100, Simon Marlow wrote:
> Claus Reinke wrote:
>
> > - i don't want to have to remove anything explicitly, becausethat
> > would mean bypassing the haskell installation managers
> > - i would want to see a single haskell installation manager
> >for each syst
Not sure about it's current state, but a friend was working on this
until he graduated recently: http://www.acm.uiuc.edu/projects/Wipt
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ketil Malde
> Aren't there any usable third-party package managers for w
On Wed, 2008-06-04 at 14:54 +0200, Ketil Malde wrote:
> > You have a point, though, and I wouldn't mind at all cabal-install
> > being integrated into portage,
>
> I'm not too familiar with portage, but I think a better solution is to
> provide tools to automatically generate packages for the va
Achim Schneider <[EMAIL PROTECTED]> writes:
Caveat: I have only a vague grasp on what exactly is being criticized
here - using a modern Linux distribution, tons of packages are
available, and almost all issues Claus point out seem to be taken care
of - at least as far as I can see.
> Well, then t
Simon Marlow <[EMAIL PROTECTED]> wrote:
> Claus Reinke wrote:
>
> > - i don't want to have to remove anything explicitly, because
> > that would mean bypassing the haskell installation managers
> > - i would want to see a single haskell installation manager
> >for each system,
>
> I think th
On Wed, 4 Jun 2008, Luke Palmer wrote:
On Wed, Jun 4, 2008 at 9:48 AM, Loup Vaillant <[EMAIL PROTECTED]> wrote:
I see a problem with this particular fusion, though: It changes the
space complexity of the program, from linear to constant. Therefore,
with some programs, relying on this "optimiza
On Wednesday 04 June 2008 11:05:52 Luke Palmer wrote:
> To me, time and space complexity is not about correctness but
> performance.
IRL the specification often dictates the complexity. If your code fails to
satisfy the spec then it is wrong. Are you saying that Haskell code can never
satisfy an
> I wonder what can be said about "stable" optimizations which are
insensitive to their environments in some sense.
http://citeseer.ist.psu.edu/veldhuizen02guaranteed.html
Ganesh
==
Please access the attached hyperlink f
On 2008-06-04, apfelmus <[EMAIL PROTECTED]> wrote:
> Peter Hercek wrote:
>> But what about this git rebasing option? How to do it more easily
>> (than the solution I know and I described it later) in darcs?
>>
>> using "git-rebase --onto master next topic" to get from:
>> to:
>>
>> o---o---o-
On 2008-06-04, Peter Hercek <[EMAIL PROTECTED]> wrote:
> But what about this git rebasing option? How to do it more easily
> (than the solution I know and I described it later) in darcs?
>
> using "git-rebase --onto master next topic" to get from:
> o---o---o---o---o master
> \
>
Claus Reinke wrote:
- i don't want to have to remove anything explicitly, becausethat
would mean bypassing the haskell installation managers
- i would want to see a single haskell installation manager
for each system,
I think that's fundamentally the wrong approach. We shouldn't have
On Wed, Jun 4, 2008 at 9:48 AM, Loup Vaillant <[EMAIL PROTECTED]> wrote:
> I see a problem with this particular fusion, though: It changes the
> space complexity of the program, from linear to constant. Therefore,
> with some programs, relying on this "optimization" can be a matter of
> correctness
Peter Hercek wrote:
But what about this git rebasing option? How to do it more easily
(than the solution I know and I described it later) in darcs?
using "git-rebase --onto master next topic" to get from:
o---o---o---o---o master
\
o---o---o---o---o next
On Wed, 4 Jun 2008, Duncan Coutts wrote:
On Wed, 2008-06-04 at 09:32 +0200, Henning Thielemann wrote:
Now the difficult question: How to write the 'mean' function in terms of
'sum' and 'length' while getting the same performance?
There's another rather harder fusion transformation that noti
Henning Thielemann <[EMAIL PROTECTED]> writes:
> Now the difficult question: How to write the 'mean' function in terms of
> 'sum' and 'length' while getting the same performance?
Write a RULE pragma converting
\xs -> (foldl' f y0 xs,foldl' g z0 xs)
into
\xs -> foldl' (\(y,z) x -> (f y x,g
[Forgot to post to the list, sorry]
2008/6/4 Duncan Coutts <[EMAIL PROTECTED]>:
>
> On Wed, 2008-06-04 at 09:32 +0200, Henning Thielemann wrote:
>> On Tue, 3 Jun 2008, Don Stewart wrote:
>>
>> > I wrote up the second part of the tour of understanding low level
>> > performance in GHC here,
>> >
>>
Ronald Guida wrote:
So I just thought of something. If laziness leads to laziness leaks,
then is there such a thing as a strictness leak? I realized that the
answer is yes.
A lazy leak is a situation where I'm wasting resources to delay a
sequence of calculations instead of just doing them now
On Wed, 2008-06-04 at 09:32 +0200, Henning Thielemann wrote:
> On Tue, 3 Jun 2008, Don Stewart wrote:
>
> > I wrote up the second part of the tour of understanding low level
> > performance in GHC here,
> >
> > http://reddit.com/r/programming/info/6lx36/comments/
> >
> > Follows on from the d
On Wed, 04 Jun 2008, Andrew Appleyard wrote:
> >Prelude Database.HDBC Database.HDBC.ODBC> handleSqlError $ conn <-
> >connectODBC "dictation"
> >:1:0: Parse error in pattern
> Try:
> conn <- handleSqlError $ connectODBC "dictation"
C:\cygwin\home\Administrator>dictation
dictation: user error
| World.hs:42:0:
|No instances for (Eq (a (M.Map String Player)),
| Eq (a (M.Map ItemId Item)),
| Eq (a (M.Map PlayerId Player)),
| Eq (a (M.Map RoomId Room)),
| Eq (a RoomId))
| arising from the 'deriving'
Ronald Guida wrote:
[snip]
By default, a lazy language will procrastinate. By default, a strict
language will "anticrastinate". Either way, I can waste resources by
blindly accepting the default time management plan.
Nice analysis.
Would you like to put that (the whole thing, not just that
Aaron Denney wrote:
This is drifting off-topic, but...
On 2008-06-03, Peter Hercek <[EMAIL PROTECTED]> wrote:
Aaron Denney wrote:
<--- cut --->
Darcs patches are pretty much an implicit rebase.
You cannot push patch B if it depends on patch A without also
pushing A. And darcs currently does
Adam Smyczek wrote:
> data SampleType = A | B Int | C String | D -- etc.
> sampleTypes = [A, B 5, C "test"] :: [SampleType]
> How do I find for example element A in the sampleTypes list?
There have been many useful replies. But since Adam
originally announced that this is a "beginner question
Hi Ron,
I've attached a revised file that solves your problem.
The solution is actually quite subtle. If you define the class as:
class Functor f => Printable f where
exprDoc :: f t -> Doc
you can't make recursive calls to sub-expressions. There is, after
all, no reason to believe that "t"
On 04/06/2008, at 10:12 AM, Ronald Guida wrote:
I would ask, "how do I examine the evaluation order of my code", but
the answer is already available: use a debugger. Haskell already has
debugging tools that do exactly what I need.
(http://www.haskell.org/haskellwiki/Debugging)
In particular, H
On Tue, 3 Jun 2008, Don Stewart wrote:
> I wrote up the second part of the tour of understanding low level
> performance in GHC here,
>
> http://reddit.com/r/programming/info/6lx36/comments/
>
> Follows on from the discussion last week about various performance
> related things.
Now the diff
79 matches
Mail list logo