New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add partial_fit function to Whitening for online applications #277
base: master
Are you sure you want to change the base?
Conversation
Thank you for this contribution! However, I think there is no point in creating a new class |
Yes, it could be implemented that way as well if you think that's a better fit with the pattern of how other classes work. It would need to work fairly differently than the partial fit method of the potato though. If that architecture is preferred, let me know and I can submit a new pull request that implements it that way (as long as you don't mind that the partial_fit would work only with no dimension reduction and only with the euclidian metric - I don't plan to do the adaptation for the iterative method to work with other settings). With that change when running online it would require two lines instead of one (a partial_fit and then a transform), but that's no big deal. |
There is no need to open a new pull-request. |
I added You should find your use case:
|
I can test this out next week or the week after, working on some other
projects in the lab in the meantime. Thanks for pushing forward, I'll let
you know what I think when I can dig in or tweak accordingly for actual
online use as needed!
…On Mon, Jan 29, 2024 at 11:12 AM Quentin Barthélemy < ***@***.***> wrote:
I added partial_fit function to Whitening.
With an alpha set equal to 1/count, you should find your use case.
@brentgaisford <https://github.com/brentgaisford>, can you test this
feature? Is it ok for you?
—
Reply to this email directly, view it on GitHub
<#277 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACK2OOBDAZCMJ3WKWGWWAKTYQ7YB5AVCNFSM6AAAAABB66YQSWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJVGM4DQNZSGI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
--
Brent Gaisford - 323 533 2485
|
Hi @brentgaisford It looks like an interesting feature :) Did you have a chance to test it? |
Not yet, but I should this week. Doing a new set of closed loop experiments
with a Riemann model, so will use that as an excuse to test this out / make
any tweaks needed for that application. Will keep y'all posted!
…On Sat, Mar 2, 2024 at 12:50 PM gcattan ***@***.***> wrote:
Hi @brentgaisford <https://github.com/brentgaisford> It looks like an
interesting feature :) Did you have a chance to test it?
—
Reply to this email directly, view it on GitHub
<#277 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACK2OOC3N4OGSHM3ICOMMILYWI3SZAVCNFSM6AAAAABB66YQSWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZUHEYDKOJTGM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
--
Brent Gaisford - 323 533 2485
|
Thank you :)
Envoyé à partir de Outlook pour Android<https://aka.ms/AAb9ysg>
…________________________________
From: Brent Gaisford ***@***.***>
Sent: Sunday, March 3, 2024 1:59:52 AM
To: pyRiemann/pyRiemann ***@***.***>
Cc: gcattan ***@***.***>; Comment ***@***.***>
Subject: Re: [pyRiemann/pyRiemann] Add patial_fit function to Whitening for online applications (PR #277)
Not yet, but I should this week. Doing a new set of closed loop experiments
with a Riemann model, so will use that as an excuse to test this out / make
any tweaks needed for that application. Will keep y'all posted!
On Sat, Mar 2, 2024 at 12:50 PM gcattan ***@***.***> wrote:
Hi @brentgaisford <https://github.com/brentgaisford> It looks like an
interesting feature :) Did you have a chance to test it?
—
Reply to this email directly, view it on GitHub
<#277 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACK2OOC3N4OGSHM3ICOMMILYWI3SZAVCNFSM6AAAAABB66YQSWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZUHEYDKOJTGM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
--
Brent Gaisford - 323 533 2485
—
Reply to this email directly, view it on GitHub<#277 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABPQYJ37WRHAIBID4W3SCY3YWJYYRAVCNFSM6AAAAABB66YQSWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZUHE3DIMBTGY>.
You are receiving this because you commented.Message ID: ***@***.***>
|
@brentgaisford , were you able to test the new |
I did! I had to make some changes to get it to work, but I have it running now. I want to do some more checking though to confirm the results it returns are correct - and it also seems to be slow to run, which isn’t good online. Will reply with more details next week once I can confirm results. |
Ok, thanks for the patience everyone! Made some tweaks to make the new partial_fit function work seamlessly in online applications, and also made sure that the results were the same as running a fit every tick (which they are). It's about 7% slower than the original iterative_whitener class I had created, but I think that's a small enough difference that it's justified given the match with design of other functions in the library. So, from my perspective, I think this is ready to be merged! Anything else we need to address, or any questions? |
I simplified the code and re-added the dimension reduction. |
Yea I’ll check it out to confirm when I’m in the lab on Wednesday.
…On Thu, Apr 18, 2024 at 9:22 AM Quentin Barthélemy ***@***.***> wrote:
I simplified the code and added the dimension reduction.
@brentgaisford <https://github.com/brentgaisford> , can you confirm that
this new implementation covers your use case?
—
Reply to this email directly, view it on GitHub
<#277 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACK2OOHY6Q3KVTTEEO4QH7LY57XNXAVCNFSM6AAAAABB66YQSWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANRUGQZTIMZRGY>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Hi @brentgaisford did it work? |
Add Iterative_Whitener class to pyriemman/preprocessing