From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id p3KE0vab025082 for ; Wed, 20 Apr 2011 16:00:57 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApACANzlrk3RVaG2kWdsb2JhbACEUJMhjUMIFAEBAQEJCwsHFAQhiG+jKYo4PIIlhTcziF0BAQMGgSODTnoEjiKDf4EEhH86 X-IronPort-AV: E=Sophos;i="4.64,246,1301868000"; d="scan'208";a="106332391" Received: from mail-gx0-f182.google.com ([209.85.161.182]) by mail1-smtp-roc.national.inria.fr with ESMTP/TLS/RC4-SHA; 20 Apr 2011 16:00:51 +0200 Received: by gxk28 with SMTP id 28so304889gxk.27 for ; Wed, 20 Apr 2011 07:00:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=eUFZHA20OKzXXYtqK+sqBZ0KjlsVCOv6S6xzGri1dFo=; b=KHeBZyFgHlSDgMe2Aefc61ksCnwNldxhO28Nt3UVO2hfBJf6amqudjFBRD37ec9oGo d8G5zKkwZSkDIKIO4L4PYbGLDCTynOGcCz0cnW+SJkyvje1NYRnAo25e7OpD+mquCX++ bFYiV9MRQPom+Cj3NGna6n5PwdAptbiqRei8E= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; b=CRJLX7kY2oigfgsdSAzgZw2FQ+6WvMhvf0mbrYyZy8bguGLnpFpP8wresuNoV+WWjg DdhX9YY/c6XfFkGCp+/HFBvAmyP+uwz+9pgJPk8bhXFN8OWPU3nNGJv2bgWCB5jngKau BJsu+zW1v4+7z4GY3jIyLhtIMC8QldJ2vUOiU= Received: by 10.90.6.13 with SMTP id 13mr6269030agf.75.1303308050659; Wed, 20 Apr 2011 07:00:50 -0700 (PDT) Received: from [192.168.1.65] (99-121-78-10.lightspeed.lnngmi.sbcglobal.net [99.121.78.10]) by mx.google.com with ESMTPS id l14sm904344anc.50.2011.04.20.07.00.47 (version=SSLv3 cipher=OTHER); Wed, 20 Apr 2011 07:00:48 -0700 (PDT) Message-ID: <4DAEE70E.4060401@gmail.com> Date: Wed, 20 Apr 2011 10:00:46 -0400 From: Edgar Friendly User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.14) Gecko/20110223 Thunderbird/3.1.8 MIME-Version: 1.0 To: caml-list@inria.fr References: <2054357367.219171.1300974318806.JavaMail.root@zmbs4.inria.fr> <4D8BD02D.1010505@inria.fr> <4D8C73C8.6020801@inescporto.pt> <1301055903.8429.314.camel@thinkpad> <341494683.237537.1301057887481.JavaMail.root@zmbs4.inria.fr> <4D8C944A.9060601@inria.fr> <4D8CB859.9040709@inescporto.pt> <4D8CDDCC.4010000@ens-lyon.org> <4D8CEAA4.2030403@inescporto.pt> <1303244809.8429.1272.camel@thinkpad> <4DAE9278.4050701@inescporto.pt> In-Reply-To: <4DAE9278.4050701@inescporto.pt> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Caml-list] Efficient OCaml multicore -- roadmap? >> Hugo, I'd like to do some more experiments into this direction. Is there >> a simple version of machine learning algorithm I could try to >> parallelize? >> > If you're interested in parallelizing Machine Learning algorithms, I've had to write a number of them for a class project, and I did it from scratch in ocaml (just using BLAS primitives for some fast vector math. They're here: https://github.com/thelema/machine-learning Small parts of what I'm doing depend on libosvm, my fork of libsvm that's not published yet (just build fixes, needs more work on the types), but that's not the part you're interested in, so if you want to compile it, just remove the svm_* calls, and it should compile just fine. The algorithms are all in predict.ml, grouped into binary classifiers (which are generally online = sequential, except for klsq (kernel least squares) which is just a matrix inversion at its core) and extension routines that take a binary classifier and run it many times on the data in different ways to get a multi-way classifier. This second group is *ridiculously* parallelizable. There's also routines for running the produced classifiers on test data, which parallelize across different elements of the test data independently. I wish my deadline weren't today, as I'd love to have a parallel version of this code to run my huge dataset through. E.