godot11

Results 7 comments of godot11

> I add the `exit 0` in the end after the line of calling `main` function in > > > ~/.tmux/plugins/tpm/tpm > > And it won't return 126 in bash....

Please hold on with merging this one. `pylab.find` may not have been what I thought it was. It seems it was `matplotlib.mlab.find` which is simply ``` import numpy as np...

As a workaround, getting rid of the conflicting module in anaconda as ```console mv ~/anaconda3/envs/simex/lib/libgio-2.0.so.0 ~/anaconda3/envs/simex/lib/libgio-2.0.so.0.backup ``` solved it for now, but I'm not sure if this hack doesn't break...

FWIW, in general the usage of `pylab` is discouraged as it's merely a convenience alias for numpy, scipy and matplotlib modules; it's better to directly reference the corresponding libraries. In...

The following seems to work, but I'm not sure it is conceptually equivalent to pylab.find: ``` xsnp['q'] = numpy.array([xsnp['ff'][(numpy.array(xsnp['T'])==numpy.array(x)), 0] for x in xsnp['xyz']]).reshape(N,) ```

> This solution looks fine to me. It may be simplified as: > > ``` > xsnp['q'] = numpy.array([xsnp['ff'][xsnp['T']==x][0] for x in xsnp['xyz']]).reshape(N,) > ``` Tested but doesn't work as...

@JunCEEE Seems I was wrong. The above fix made the code working by all means, but the results for some charges don't make too much sense. It seems pylab.find may...