Skip to content

Instantly share code, notes, and snippets.

View PRFina's full-sized avatar

Pio Raffaele Fina PRFina

  • Turin
View GitHub Profile
@PRFina
PRFina / py
Created November 6, 2021 10:33
import numpy as np
N=10
K=5
array = np.arange(100)
windows = np.lib.stride_tricks.sliding_window_view(array, N)
strides = windows[::K]
print(strides)
@PRFina
PRFina / TDA_resources.md
Last active November 2, 2020 09:48 — forked from calstad/TDA_resources.md
List of resources for TDA

Quick List of Resources for Topological Data Analysis with Emphasis on Machine Learning

This is just a quick list of resourses on TDA that I put together for @rickasaurus after he was asking for links to papers, books, etc on Twitter and is by no means an exhaustive list.

Survey Papers

Both Carlsson's and Ghrist's survey papers offer a very good introduction to the subject

Other Papers and Web Resources

@PRFina
PRFina / .py
Created August 21, 2020 12:31
Replicable code for medium comment about RMLSE
# fake data
true1 = 100.0
predicted1 = 90.0
# 2 order of magnitude bigger
true2 = true1 * 100.0
predicted2 = predicted1 * 100.0
np.sqrt(mean_squared_log_error([true1],[predicted1])) # => 0.10426101032440993
np.sqrt(mean_squared_log_error([true2],[predicted2])) # => 0.10534940571943174