John,
I just meant that if the scikit's maintainers didn't think it was within the
scope of the project, I'd still be interested in assembling and contributing to
a collection of metric learning algorithms in the scikit's style.
-Robert
On Apr 21, 2013, at 6:25 PM, John Collins wrote:
> Hi Robert, Ken,
>
> Robert,
>
> I'm not convinced we would need a separate interface. Perhaps I'm wrong
> because I've not really been exposed to all of the metric learning
> techniques, but in all the ones I've seen the goal is to learn a matrix A.
> Calling say <metric_learning_technique_X>.fit(X, y) could create A. Perhaps
> the response variable y could be not-necessarily fully specified as is
> usually the case with a metric learning approach, i.e. some elements are
> None. Then <metric_learning_technique_X>.predict(newX) would do the usual
> thing.
>
> In any case I would also be interested in helping to implement, though I
> think it would fit nicely within the scope of sklearn.
>
> John
>
>
> On Sun, Apr 21, 2013 at 4:30 PM,
> <scikit-learn-general-requ...@lists.sourceforge.net> wrote:
> Send Scikit-learn-general mailing list submissions to
> scikit-learn-general@lists.sourceforge.net
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
> or, via email, send a message with subject or body 'help' to
> scikit-learn-general-requ...@lists.sourceforge.net
>
> You can reach the person managing the list at
> scikit-learn-general-ow...@lists.sourceforge.net
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Scikit-learn-general digest..."
>
>
> Today's Topics:
>
> 1. Re: Random patches and coordinates (Nicolas Tr?segnie)
> 2. Re: Metric Learning Algorithms (Robert McGibbon)
> 3. Re: Random patches and coordinates (Gael Varoquaux)
> 4. Re: Metric Learning Algorithms (Robert McGibbon)
> 5. Re: Random patches and coordinates (Nicolas Tr?segnie)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 22 Apr 2013 00:34:19 +0200
> From: Nicolas Tr?segnie <nicolas.treseg...@gmail.com>
> Subject: Re: [Scikit-learn-general] Random patches and coordinates
> To: scikit-learn-general@lists.sourceforge.net
> Message-ID: <5174696b.7070...@gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi Alex,
>
> Indeed, this solution wouldn't break anything but I generally avoid
> letting the parameters change the return type of a function. Is this
> approach used somewhere else in scikit-learn?
>
> After the modification of extract_patches_2d, I will probably modify
> reconstruct_from_patches_2d. I would add the possibility to:
>
> * disable the averaging
> * use the coordinates to reconstruct the image with only a subset of
> the patches
>
> Nicolas
>
> On 04/21/2013 10:01 PM, Alexandre Gramfort wrote:
> > hi Nicolas,
> >
> > I would add a bool parameter to extract_patches_2d such as
> > return_coordinates. If True it returns (patches, coords)
> >
> > Alex
> >
> > ------------------------------------------------------------------------------
> > Precog is a next-generation analytics platform capable of advanced
> > analytics on semi-structured data. The platform includes APIs for building
> > apps and a phenomenal toolset for data science. Developers can use
> > our toolset for easy data analysis & visualization. Get a free account!
> > http://www2.precog.com/precogplatform/slashdotnewsletter
> > _______________________________________________
> > Scikit-learn-general mailing list
> > Scikit-learn-general@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
> Message: 2
> Date: Sun, 21 Apr 2013 15:35:52 -0700
> From: Robert McGibbon <rmcgi...@gmail.com>
> Subject: Re: [Scikit-learn-general] Metric Learning Algorithms
> To: scikit-learn-general@lists.sourceforge.net
> Message-ID: <91613893-bd92-49d5-a76b-9e30a0949...@gmail.com>
> Content-Type: text/plain; charset="windows-1252"
>
> This would be AWESOME.
>
> I have code implementing Shen, C.; Kim, J.; Wang, L. Scalable large-margin
> Mahalanobis distance metric learning. IEEE Trans. Neural Networks 2010, 21,
> 1524?1530, but it yeah, it's not up to sklearn standards either.
>
> -Robert
>
> On Apr 21, 2013, at 12:49 PM, Kenneth C. Arnold wrote:
>
> > I have implemented a few metric learning algorithms myself. The quality of
> > that code is nowhere near sklearn standards, but I may have some incentive
> > to improve it soon.
> >
> > -Ken
> >
> >
> > On Sun, Apr 21, 2013 at 3:42 PM, John Collins <johnsso...@gmail.com> wrote:
> > Has anybody or does anybody have plans to implement metric learning
> > algorithms like ITML in sklearn?
> >
> > If not, I would like to consider working on this.
> >
> > Thanks,
> >
> > John
> >
> > ------------------------------------------------------------------------------
> > Precog is a next-generation analytics platform capable of advanced
> > analytics on semi-structured data. The platform includes APIs for building
> > apps and a phenomenal toolset for data science. Developers can use
> > our toolset for easy data analysis & visualization. Get a free account!
> > http://www2.precog.com/precogplatform/slashdotnewsletter
> > _______________________________________________
> > Scikit-learn-general mailing list
> > Scikit-learn-general@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
> >
> >
> > ------------------------------------------------------------------------------
> > Precog is a next-generation analytics platform capable of advanced
> > analytics on semi-structured data. The platform includes APIs for building
> > apps and a phenomenal toolset for data science. Developers can use
> > our toolset for easy data analysis & visualization. Get a free account!
> > http://www2.precog.com/precogplatform/slashdotnewsletter_______________________________________________
> > Scikit-learn-general mailing list
> > Scikit-learn-general@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
> Message: 3
> Date: Sun, 21 Apr 2013 16:38:13 -0600
> From: Gael Varoquaux <gael.varoqu...@normalesup.org>
> Subject: Re: [Scikit-learn-general] Random patches and coordinates
> To: scikit-learn-general@lists.sourceforge.net
> Message-ID: <20130421223813.gc3...@phare.normalesup.org>
> Content-Type: text/plain; charset=us-ascii
>
> Would a transformer, with an associated inverse_transform, be useful
> here? It seems to me that it would be the right pattern, however I don't
> have the code in mind, so I may be wrong.
>
>
>
> ------------------------------
>
> Message: 4
> Date: Sun, 21 Apr 2013 15:40:21 -0700
> From: Robert McGibbon <rmcgi...@gmail.com>
> Subject: Re: [Scikit-learn-general] Metric Learning Algorithms
> To: scikit-learn-general@lists.sourceforge.net
> Message-ID: <6f63ec10-ec76-408e-b007-f4a671769...@gmail.com>
> Content-Type: text/plain; charset="windows-1252"
>
> If people were interested in putting together a separate package in the style
> of the scikit collecting metric learning algorithms with a common API, I
> would love to contribute to that too.
>
> -Robert
>
> On Apr 21, 2013, at 3:35 PM, Robert McGibbon wrote:
>
> > This would be AWESOME.
> >
> > I have code implementing Shen, C.; Kim, J.; Wang, L. Scalable large-margin
> > Mahalanobis distance metric learning. IEEE Trans. Neural Networks 2010, 21,
> > 1524?1530, but it yeah, it's not up to sklearn standards either.
> >
> > -Robert
> >
> > On Apr 21, 2013, at 12:49 PM, Kenneth C. Arnold wrote:
> >
> >> I have implemented a few metric learning algorithms myself. The quality of
> >> that code is nowhere near sklearn standards, but I may have some incentive
> >> to improve it soon.
> >>
> >> -Ken
> >>
> >>
> >> On Sun, Apr 21, 2013 at 3:42 PM, John Collins <johnsso...@gmail.com> wrote:
> >> Has anybody or does anybody have plans to implement metric learning
> >> algorithms like ITML in sklearn?
> >>
> >> If not, I would like to consider working on this.
> >>
> >> Thanks,
> >>
> >> John
> >>
> >> ------------------------------------------------------------------------------
> >> Precog is a next-generation analytics platform capable of advanced
> >> analytics on semi-structured data. The platform includes APIs for building
> >> apps and a phenomenal toolset for data science. Developers can use
> >> our toolset for easy data analysis & visualization. Get a free account!
> >> http://www2.precog.com/precogplatform/slashdotnewsletter
> >> _______________________________________________
> >> Scikit-learn-general mailing list
> >> Scikit-learn-general@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
> >>
> >>
> >> ------------------------------------------------------------------------------
> >> Precog is a next-generation analytics platform capable of advanced
> >> analytics on semi-structured data. The platform includes APIs for building
> >> apps and a phenomenal toolset for data science. Developers can use
> >> our toolset for easy data analysis & visualization. Get a free account!
> >> http://www2.precog.com/precogplatform/slashdotnewsletter_______________________________________________
> >> Scikit-learn-general mailing list
> >> Scikit-learn-general@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
> >
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
> Message: 5
> Date: Mon, 22 Apr 2013 01:29:59 +0200
> From: Nicolas Tr?segnie <nicolas.treseg...@gmail.com>
> Subject: Re: [Scikit-learn-general] Random patches and coordinates
> To: scikit-learn-general@lists.sourceforge.net
> Message-ID: <51747677.4010...@gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> I think you are right. Moreover, a transformer already exists here
> <https://github.com/scikit-learn/scikit-learn/blob/85ec0fd1ae904f275f608b11044a2476ed4723e6/sklearn/feature_extraction/image.py#L380>.
>
> I see two solutions:
>
> * The transform() method could return the coordinates and the
> inverse_transform() method could take them as argument. The
> Transformer API
> <http://scikit-learn.org/0.13/developers/index.html#different-objects>
> doesn't specify if the transform() method can take more than one
> argument (two, to be exact) and I didn't find inverse_transform() in
> the API page. So I don't know if this approach would be consistent
> with all the others estimators/transformers.
> * The transformer could also retain the coordinates but then:
> o It would be specific to images of a certain size.
> o What kind of behaviour would be expected if the transform()
> method is called more than once? Use the same coordinates to
> extract patches in the new set of images?
> o If the transform() method was used to extract patches from
> various images, these images would need to be reconstructed
> together.
>
> Another question for later:
>
> * The two functions extract_patches_2d and reconstruct_from_patches_2d
> are part of the public API (they are not prefixed with _). I think
> they sould be deprecated if a create a more complex transformer.
> What do you think?
>
>
> On 04/22/2013 12:38 AM, Gael Varoquaux wrote:
> > Would a transformer, with an associated inverse_transform, be useful
> > here? It seems to me that it would be the right pattern, however I don't
> > have the code in mind, so I may be wrong.
> >
> > ------------------------------------------------------------------------------
> > Precog is a next-generation analytics platform capable of advanced
> > analytics on semi-structured data. The platform includes APIs for building
> > apps and a phenomenal toolset for data science. Developers can use
> > our toolset for easy data analysis & visualization. Get a free account!
> > http://www2.precog.com/precogplatform/slashdotnewsletter
> > _______________________________________________
> > Scikit-learn-general mailing list
> > Scikit-learn-general@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
> ------------------------------------------------------------------------------
> Precog is a next-generation analytics platform capable of advanced
> analytics on semi-structured data. The platform includes APIs for building
> apps and a phenomenal toolset for data science. Developers can use
> our toolset for easy data analysis & visualization. Get a free account!
> http://www2.precog.com/precogplatform/slashdotnewsletter
>
> ------------------------------
>
> _______________________________________________
> Scikit-learn-general mailing list
> Scikit-learn-general@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
>
>
> End of Scikit-learn-general Digest, Vol 39, Issue 41
> ****************************************************
>
> ------------------------------------------------------------------------------
> Precog is a next-generation analytics platform capable of advanced
> analytics on semi-structured data. The platform includes APIs for building
> apps and a phenomenal toolset for data science. Developers can use
> our toolset for easy data analysis & visualization. Get a free account!
> http://www2.precog.com/precogplatform/slashdotnewsletter_______________________________________________
> Scikit-learn-general mailing list
> Scikit-learn-general@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general
------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter
_______________________________________________
Scikit-learn-general mailing list
Scikit-learn-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general