Skip to content
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

Extreme events functionality /ies #189

Open
Datseris opened this issue Jul 6, 2022 · 14 comments
Open

Extreme events functionality /ies #189

Datseris opened this issue Jul 6, 2022 · 14 comments
Labels
discussion rare-events Related with extremes and rare events wanted_feature

Comments

@Datseris
Copy link
Member

Datseris commented Jul 6, 2022

So extreme events analysis is currently very popular in nonlinear dynamics and we could get more functions that support this kind of stuff.

At the moment we have mean_return_times and exit_entry_times, but more would be useful.

What I am thinking as interface is a function extreme_events(ds::DynamicalSystem, event, ...) . event is a function of the state that encodes when an event happens. E.g., 3rd variable of the system exceeds some threshold. Then, the function creates an integrator and evolves for arbitrary amount of time, and then returns the times the events happened, and maybe the state of the system when they happened.

Anyone reading this working on extreme events please do feel free to chime in and say what kind of extreme events algorithms you are interested in and whether the aforemention function is useful.

@SergeyNovak777
Copy link
Contributor

SergeyNovak777 commented Jul 6, 2022

Hello, i analysis extreme events in neurodynamics. In neurobiological terms extreme events(EV) is extreme synchronization membrane potential neurons in ensemble. For example i have 3 coupled neuron Rulkov and for right analysis EV we need variable x_sum = x1 + x2 + x3. What I mean to say is that the user can select a variable or enter a new one.

In many articles extreme values detected how events which below or equal some threshold. Also important moment that is use local maximums (peaks) or minimum variable x_sum. For this in python i use function argrelextrema (example : argrelextrema(variable, np.greater).

Famous threshold which used in analysis extreme events is mean of all peaks plus k standard deviation of all peaks. I've been in situations where EV is negative events. That is I mean to say user need input equation which calculate threshold or choose from some list.

Main difficult with analysis extreme events is computing time and computer resources ( for example need many memory). That is I mean to say need use integator which optimizated for extreme events. For example which used little memmory and have ability to parallel computing.

For more information on EV in neurodynamics, I will leave a link to one of the articles
https://pubmed.ncbi.nlm.nih.gov/30011519/

@SergeyNovak777
Copy link
Contributor

SergeyNovak777 commented Jul 6, 2022

For detailed analysis extreme events i think need several functions. For example calcatuon map largest lyapunov exponents. Map largest lyapunov exponents is needed for detecting regions of chaos (EV can only be in chaos). I mean map lyapunov exponents can show regions with potential EV. Also can be added function for map EV. This map show count EV.

Several dynamical systems have multistability and during computation can be situation when the trajectory files off its attractor. This situatuion can be avoided if use inheritance of initial conditions. Inheritance of initial conditions it is when last dots from trajectory uses how initial condition for another system. One possible inheritance is from the main diagonal. For a better understanding, here is an image. In ensembles with symmetric elements, inheritance give a symmetric map. Note that the absence of symmetry usually indicates multistability. For example map lyapunov exponent for three coupled elements rulkov from my course work.
I have code in python with inheritance of initial conditions from main diagonal if need i can share it.
image
image

@PythagoreanCult
Copy link

Might be an obvious comment, but from the times at which the orbit enters the set you can estimate the extremal index as well. One option is the intervals estimator [Ferro & Segers,2003], but there are more.

@Datseris
Copy link
Member Author

Datseris commented Jul 7, 2022

what is an external index? Also, can you please give the full reference, and a link to it?

@SergeyNovak777
Copy link
Contributor

If I understand correctly, he is talking about EV return times

@PythagoreanCult
Copy link

The extremal index is a number between 0 and 1 that measures the presence of clusters of exceedences, and it does modify the shape of the extreme value distribution of a process. It arises when there are short range correlations.

More info on the extremal index: https://hal.archives-ouvertes.fr/hal-02334271/file/extremal_index.pdf

Here is a link to the paper on the estimator: http://mistis.inrialpes.fr/docs/EXTREMES/Ferro2003.pdf

@SergeyNovak777
Copy link
Contributor

I also forgot to add that it is possible to identify them by percentile. I have list of article about this.

@SergeyNovak777
Copy link
Contributor

SergeyNovak777 commented Jul 7, 2022

this is a link with some articles on EV : https://drive.google.com/drive/folders/16RXgBCH_MmK18VFmwOFvkagYlGJhDqpb?usp=sharing

@Datseris
Copy link
Member Author

Datseris commented Jul 28, 2022

Just saw this JuliaCon talk on Extremes.jl. I haven't actually seen the talk yet, but there seems to be some functionality about Extreme Values in Julia. Will post an update here after I had a look at the talk. Maybe we can integrate it here and save a lot of inner-most code writing!

https://github.com/jojal5/Extremes.jl

CC @jojal5 the package owner .

@Datseris
Copy link
Member Author

Also CC @houton199 the talk presenter

@houton199
Copy link

Hi @Datseris, thanks for reaching out! @jojal5 might be slow to respond as he will be away for a month.

I’m not exactly knowledgeable in extremes value analysis in nonlinear dynamics but I’ll be happy to help if there are some Extremes.jl functionalities that can be integrated. Note that the extremal index estimators, as mentioned by PythagoreanCult, are not yet implemented in Extremes.jl but it is planned for this autumn.

For the moment, I believe you may run into compatibility problems as Extremes.jl is still using Mamba,jl, a not so well maintained package that forces very old versions of certain packages. We plan to replace this package as soon as we have the time to do so.

By the way, your collaborator on JuliaClimate, Philippe Roy (Balinus), was my master’s thesis co-supervisor with @jojal5 👪 😄

@Datseris
Copy link
Member Author

ooof Mamba.jl has Julia 0.3 in its README, doesn't look good hahahhahahaha

By the way, your collaborator on JuliaClimate, Philippe Roy (Balinus), was my master’s thesis co-supervisor with @jojal5 👪 😄

Yes, I've noticed, it is a rather small world isn't it? ;)

@SergeyNovak777
Copy link
Contributor

I have been thinking about the implementation of extreme events in a package and a rather controversial point has arisen. The user can try to look for extreme events in regular modes where they cannot be. In that case, a search for extreme events would yield nothing. So I think it would be worth checking largest lyapunov exponent before try found extreme events.

@PythagoreanCult
Copy link

Following @SergeyNovak777 comment, as I understand it it will also depend on how you look for and define the extreme events, Block maxima method will always find data points and label them as extremes. Numerically, there will be always some spread on the maxima, which can be fitted to a distribution. One option is to perform a test to evaluate how well the extremes fit a distribution. But yes, on principle the distribution on a regular mode should be degenerate.

P.D.: I did try to use Extremes and DynamicalSystems at the same time and it did not work.

@Datseris Datseris added the rare-events Related with extremes and rare events label Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion rare-events Related with extremes and rare events wanted_feature
Projects
None yet
Development

No branches or pull requests

4 participants