@Shalom: Jak dodać rzutowanie aby nie trwało 1h do funkcji:
diffs = multi(day_diff_vectorized, np.array_split(array, cores, axis=0), processes=cores)
Próbuję podejrzeć debuggerem ale trwa już ~1h i nie może dojść do tego etapu a normalnie program wykonuje się w 5min
Tablica jest potrzebna w formacie numpy.array
do obliczeń z późniejszą tablicą i powinna zawiera wartości int
oraz mieć rozmar 50 000 x 50 000
Spróbowałem
diffs = np.array(diffs)
oraz
diffs = np.asarray(diffs, dtype=np.int)
Przykład wynikowej tablicy diff:
[array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
...,
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544]]), array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
...,
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544]]), array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
...,
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544]]), array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
...,
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544]]), array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
...,
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544]]), array([[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],
[18544, 18544, 18544, ..., 18544, 18544, 18544],