Using PGSM with Python 3.7
Closed this issue · 0 comments
matteolepur commented
Hey Andy,
I get the following error that results from line 68 in kernels.py
TypeError: ufunc 'isinf' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ''safe''
I changed this
log_q_norm = log_sum_exp(np.array(log_q.values()))
-> log_q_norm
= log_sum_exp(list(log_q.values()))`
and works fine.
I would create a pull request but I had to swap around the directory because there were importing problems that may be due to my setup
edit:
Looks like we need to wrap any dictionary methods with list
particles_weights.keys()
-> list(particles_weights.keys())
particles_weights.values()
-> list(particles_weights.values())