deepcharles / ruptures

ruptures: change point detection in Python
BSD 2-Clause "Simplified" License
1.56k stars 161 forks source link

docs: Ensemble dimensions (old) #240

Closed theovincent closed 2 years ago

theovincent commented 2 years ago

Hi,

I have implemented an ensemble method on top of rupture. The contribution is only a Jupyter Notebook showing how to replicate the algorithm shown in Katser2021. This Jupyter Notebook is added to the galery of examples in the docs. This subject was first raised in the following issue and is related to the following one.

The code was developed following the guidelines. The docs work for me on my computer when I use mkdocs serve. The only problem is that I don't see the output of the cells of the Jupyter Notebook. The problem also happens if I try to view the other examples in the gallery even if I am in the branch master.

[Katser2021] Katser, I., Kozitsin, V., Lobachev, V., & Maksimov, I. (2021). Unsupervised Offline Changepoint Detection Ensembles. Applied Sciences, 11(9), 4280.

theovincent commented 2 years ago

The workflow pre-commit.ci is not passing. It comes from the blacken-docs check. I don't think it comes from my code. Indeed, the log message reads:

Traceback (most recent call last):
  File "/pc/clone/dh2xB3GrSU6cvd4ucIO-Kw/py_env-python3/bin/blacken-docs", line 8, in <module>
    sys.exit(main())
  File "/pc/clone/dh2xB3GrSU6cvd4ucIO-Kw/py_env-python3/lib/python3.8/site-packages/blacken_docs.py", line 238, in main
    black_mode = black.FileMode(
  File "<string>", line 3, in __init__
TypeError: set object expected; got list

In ruptures the tag of the blacken-docs used is v1.12.0. Interestingly, in the new version of the blacken-docs (v1.12.1), the code line 238 in blacken_docs.py has changed and the commit message is called Fix target_versions for FileMode. I will then change the version of the blacken-docs pre-commit.

oboulant commented 2 years ago

Hi @theovincent ,

Thanks for your interest in ruptures !

FYI, as in your description you say that

I don't see the output of the cells of the Jupyter Notebook

If you want to see the results of the docs built in the CI, you can look at the artifacts generated by the GHA. For instance, the last one passing related to your PR is here. Then see the artifact, download it and you can browse locally. Spoiler alert, your cells outputs are there !

We will look into your PR in the following days !

Thx !

deepcharles commented 2 years ago

I'm ok with the code.

deepcharles commented 2 years ago

replaced by #248