From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id 10ACC8239C for ; Mon, 26 Feb 2018 07:07:31 +0100 (CET) Authentication-Results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=berenger@bioreg.kyushu-u.ac.jp; spf=None smtp.mailfrom=berenger@bioreg.kyushu-u.ac.jp; spf=None smtp.helo=postmaster@h4.hosting4.cc.kyushu-u.ac.jp Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of berenger@bioreg.kyushu-u.ac.jp) identity=pra; client-ip=133.5.13.5; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="berenger@bioreg.kyushu-u.ac.jp"; x-sender="berenger@bioreg.kyushu-u.ac.jp"; x-conformance=sidf_compatible Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of berenger@bioreg.kyushu-u.ac.jp) identity=mailfrom; client-ip=133.5.13.5; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="berenger@bioreg.kyushu-u.ac.jp"; x-sender="berenger@bioreg.kyushu-u.ac.jp"; x-conformance=sidf_compatible Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@h4.hosting4.cc.kyushu-u.ac.jp) identity=helo; client-ip=133.5.13.5; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="berenger@bioreg.kyushu-u.ac.jp"; x-sender="postmaster@h4.hosting4.cc.kyushu-u.ac.jp"; x-conformance=sidf_compatible IronPort-PHdr: =?us-ascii?q?9a23=3AXsAN/hR/9BToCNDF1/7va1Nyi9psv+yvbD5Q0YIu?= =?us-ascii?q?jvd0So/mwa6yYhKN2/xhgRfzUJnB7Loc0qyK6/umATRIyK3CmUhKSIZLWR4BhJ?= =?us-ascii?q?detC0bK+nBN3fG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ZI8OpDbwMOMl5v7r?= =?us-ascii?q?jX8hg1ARZ6ip3Z0NaHC5BPtqOUuZYWC/yusGRGwDuw57SO3xlBXWWjdWYzO2Xr?= =?us-ascii?q?kgzjA9EoOvS4nZENODmruEiQmhF5tdYWFdQnqhK1rOWKi+E6MGZTifJMBsiBQO?= =?us-ascii?q?VL+7RoBn1gCzrw/njqchJ+GS+DVO5sGr78R8++CGzUJ6zjdzFcnIjjnUHjNE21?= =?us-ascii?q?gQTjpz55hR5El0y1ONy6992acKH91U/f5GFAQrKIXc0qlnTdn5HADZLI/QFASW?= =?us-ascii?q?B+6+CDR0deofhscUahwmSd+jiQrO0GypEqIOl6HOGdo9+eTexyqpfpsv+zP9zK?= =?us-ascii?q?AkymIebI5POGmh3fct91SVB4nSj0SfmPrsfq9a3z/Q72eeiHfItUoeUhYiCag?= =?us-ascii?q?=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0AKAgCDo5NamAUNBYVcHAEBAQQBAQoBA?= =?us-ascii?q?YMigRMDbSiDVIsWjlcLgT2YGwEJI4djBgUzFQECAQEBAQEBAQEBEgEBAQEBCAs?= =?us-ascii?q?LBigvgjgMDIJ9BIEHAiYCIT4NCAEBhQsRqxyBbTqEdIJoHGqCRoEPhAyGDQyGJ?= =?us-ascii?q?gKEfoJlBYgLB4IfiAePKQkehxuMZ4JogQmHOoc0AYxRiSSBLzSBc4EFOoJDCYJ?= =?us-ascii?q?KgRABCXxojF8BAQE?= X-IPAS-Result: =?us-ascii?q?A0AKAgCDo5NamAUNBYVcHAEBAQQBAQoBAYMigRMDbSiDVIs?= =?us-ascii?q?WjlcLgT2YGwEJI4djBgUzFQECAQEBAQEBAQEBEgEBAQEBCAsLBigvgjgMDIJ9B?= =?us-ascii?q?IEHAiYCIT4NCAEBhQsRqxyBbTqEdIJoHGqCRoEPhAyGDQyGJgKEfoJlBYgLB4I?= =?us-ascii?q?fiAePKQkehxuMZ4JogQmHOoc0AYxRiSSBLzSBc4EFOoJDCYJKgRABCXxojF8BA?= =?us-ascii?q?QE?= X-IronPort-AV: E=Sophos;i="5.47,396,1515452400"; d="scan'208";a="315238996" Received: from hosting4.cc.kyushu-u.ac.jp (HELO h4.hosting4.cc.kyushu-u.ac.jp) ([133.5.13.5]) by mail2-smtp-roc.national.inria.fr with ESMTP; 26 Feb 2018 07:07:29 +0100 Received: from [192.168.2.36] (unknown [133.5.218.148]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: berenger@bioreg.kyushu-u.ac.jp) by h4.hosting4.cc.kyushu-u.ac.jp (hde-lc-postfix) with ESMTPSA id 7E8332B7DE9 for ; Mon, 26 Feb 2018 15:07:24 +0900 (JST) (envelope-from berenger@bioreg.kyushu-u.ac.jp) To: caml-list From: Francois BERENGER Message-ID: <2db0a056-4049-da6a-c12c-b36d21301014@bioreg.kyushu-u.ac.jp> Date: Mon, 26 Feb 2018 15:07:24 +0900 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: [Caml-list] [ANN] first release of orsvm-e1071 (SVM from R usable from OCaml) Hello, I created a thin OCaml wrapper to drive two famous SVM packages for R: e1071 and svmpath. The code is here: https://github.com/UnixJunkie/orsvm-e1071 This package provides two modules: - Svm: this one provides access to a Support Vector Machine with a Radial Basis Function (RBF) or a linear kernel. This is a binary classifier. --- type gamma = float type kernel = RBF of gamma | Linear type filename = string val train: ?debug:bool -> cost:float -> kernel -> filename -> filename -> Result.t val predict: ?debug:bool -> Result.t -> filename -> Result.t val read_predictions: Result.t -> float list --- - Svmpath: this one provides only access to a SVM with a linear kernel, but it allows to quickly find all values that need to be tested to obtain the best classifier. This is also a binary classifier. --- type filename = string val train: ?debug:bool -> filename -> filename -> Result.t val read_lambdas: ?debug:bool -> Result.t -> float list val predict: ?debug:bool -> lambda:float -> Result.t -> filename -> Result.t val read_predictions: Result.t -> float list --- The file src/test.ml is a working example of all functionalities. There are example data and label files under data/. I don't claim the package is super efficient. For example, data are exchanged via text files. However, it is a proof of concept on how to quickly access some functionality provided by an R package. If you want the package to be more efficient or provide access to more functionalities of the underlying R packages, your help is welcome. Thanks to Ronan Lehy for help with understanding how to use the svmpath package. The corresponding package should appear soon in opam. Regards, F.