Questions tagged [funcy]
funcy is a python functional helper library. "Funcy is designed to be a layer of functional tools over python."
4
questions
0
votes
0
answers
57
views
How to use Funcy "print_durations" in grequests function?
I've never used this type of module or function. I wanted to know how I can time and print the time taken to find the "response 200" link?
##################### START MODUL PARSE ############...
0
votes
3
answers
199
views
Summing duplicates in a list of dictionaries by a compound key using itertools
I have a sorted list of dictionaries like so:
dat = [
{"id1": 1, "id2": 2, "value": 1},
{"id1": 1, "id2": 2, "value": 2},
{...
7
votes
3
answers
308
views
How to accelerate the application of the following for loop and function?
I have the following for loop:
for j in range(len(list_list_int)):
arr_1_, arr_2_, arr_3_ = foo(bar, list_of_ints[j])
arr_1[j,:] = arr_1_.data.numpy()
arr_2[j,:] = arr_2_.data.numpy()
...
7
votes
2
answers
484
views
Cant Pickle memoized class instance
Here is the code I am using
import funcy
@funcy.memoize
class mystery(object):
def __init__(self, num):
self.num = num
feat = mystery(1)
with open('num.pickle', 'wb') as f:
pickle....