Skip to content

Instantly share code, notes, and snippets.

@MartinPicc
MartinPicc / main.py
Last active May 5, 2020 17:50
fichier de test pour différentes implémentations de quicksort - np.sort, pur python, basique cython
from timeit import default_timer as timer
from copy import copy
import numpy as np
from quicksort import quicksort
from quicksort1 import quicksort as quicksort1
# Test parameters
array_size = 10000 # size of test array
repeat = 5 # numbers of arrays to test
n_iter = 100 # number of tests for each array
@MartinPicc
MartinPicc / main.py
Last active May 5, 2020 17:45
fichier de test pour différentes implémentations de quicksort - np.sort et pur python
from timeit import default_timer as timer
from copy import copy
import numpy as np
# Test parameters
array_size = 10000 # size of test array
repeat = 5 # numbers of arrays to test
n_iter = 100 # number of tests for each array
functions = {