caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Hugo Ferreira <hmf@inescporto.pt>
To: blue storm <bluestorm.dylc@gmail.com>
Cc: "caml-list@inria.fr" <caml-list@inria.fr>
Subject: Re: [Caml-list] Optimizing symbolic processing code
Date: Fri, 16 Jan 2009 09:44:47 +0000	[thread overview]
Message-ID: <4970570F.3070004@inescporto.pt> (raw)
In-Reply-To: <527cf6bc0901160105u67e68ea1qb3633cd51f273aa0@mail.gmail.com>

blue storm wrote:
> On 1/16/09, Hugo Ferreira <hmf@inescporto.pt> wrote:
>> I have implemented a simple Prolog like inference engine
>> to be used in machine learning algorithms (ILP). My first
>> basic test shows that inference is dismally slow (compared
>> to a Prolog compiler). Consequently I am looking for
>> information on optimizing the code.
> 
> Before trying low-level optimizations, i suggest you check carefully
> your implementation. It's a bit strange that your performance is so
> bad, and i suspect there could be improvement of algorithmic nature.
> 

Don't think it is algorithmic. The test specifically targets the
discriminant tree I developed according to the descriptions found
in various articles.

Note that the Prolog implementation tested also requires some time to
solve the problem. Now, I don't expect to have the same performance
as an optimized inference engine but... its so much slower.


> There have been successful translations of Prolog to OCaml before :
> http://groups.google.com/group/comp.lang.prolog/msg/28c4361bb5f865b8?pli=1
> , wich is quite different as it uses the ocaml compiler itself to get
> good performances.
> 

Yes I know of this. However the need to some additional stuff (forward
clause subsumption testing, coverage counting, clause ranking, etc.)
that are specific to the learning algorithm has prompted me to develop
this code.

Regards,
Hugo F.



  reply	other threads:[~2009-01-16  9:44 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-16  8:42 Hugo Ferreira
2009-01-16  9:05 ` [Caml-list] " blue storm
2009-01-16  9:44   ` Hugo Ferreira [this message]
2009-01-16 13:41 ` Jon Harrop
2009-01-16 14:15   ` Hugo Ferreira
2009-01-16 16:14     ` Peter Ilberg
2009-01-16 16:19       ` Hugo Ferreira
2009-01-16 19:09         ` Andrej Bauer
2009-01-16 20:48           ` Andrej Bauer
2009-01-17  9:28             ` Hugo Ferreira
2009-01-17 11:39               ` Andrej Bauer
2009-01-17 15:47                 ` Hugo Ferreira
2009-01-17 16:08                   ` Hugo Ferreira
2009-01-16 21:46         ` Kuba Ober
2009-01-17  9:46           ` Hugo Ferreira

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4970570F.3070004@inescporto.pt \
    --to=hmf@inescporto.pt \
    --cc=bluestorm.dylc@gmail.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).