BB,
Currently I am reading a text file and storing the output as an array a1, some
arithmetic operation on it and plotting it. I want to do the same over 1000
files.
How to loop it and how to store the input in different arrays like a2, a3 and
so on.
Also advise what is the best way to TAG or
BB,
In a numpy array of m x n size, I would like to delete few rows when a given
element in that row is 'nan' or say any other value.
For e.g. as in example given below, if I wish to delete a row when the 3rd
element of row is zero, or if 3rd, 4th, 5th element are zero or either of 3rd,
4th
One way is to use python dicts. Pseudocode:
arrays = {}
integer = 0
for file in allfiles:
integer +=1
data = file.read()
arrays['a' + '%d' % integer] = data
I would consider using the filename as the key instead of a1, a2, etc. That way
you have that information readily
Paul,
Appreciate your reply.
Cheers
Sachin
Sachin Kumar Sharma
Senior Geomodeler
-Original Message-
From: numpy-discussion-boun...@scipy.org
[mailto:numpy-discussion-boun...@scipy.org] On Behalf Of Paul Anton
On Thu, Mar 24, 2011 at 2:04 AM, Derek Homeier
de...@astro.physik.uni-goettingen.de wrote:
On 24 Mar 2011, at 00:34, Derek Homeier wrote:
tests with the fink-installed pythons on MacOS X mostly succeeded,
with one failure in python2.4 and a couple of issues seemingly
related to PPC
On Thu, Mar 24, 2011 at 10:11 AM, Pearu Peterson
pearu.peter...@gmail.comwrote:
Regarding this test failure, could you hack the
numpy/f2py/tests/test_kind.py script by adding the following code
for i in range(20):
print '%s - %s, %s' % (i, selected_real_kind(i), selectedrealkind(i))
and
On Thu, Mar 24, 2011 at 1:12 PM, Sachin Kumar Sharma ssharm...@slb.comwrote:
BB,
In a numpy array of m x n size, I would like to delete few rows when a
given element in that row is ‘nan’ or say any other value.
For e.g. as in example given below, if I wish to delete a row when the 3
hi,
when numpy in Linux apt will be updated? It's still 1.3.0 with many
bugs
I tried to install numpy from PYPI where 1.5.1 seesm to be present,
but somehow it involves 1.3.0 instead:
$ sudo easy_install numpy
install_dir /usr/local/lib/python2.6/dist-packages/
Searching
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing
computations and making text output completely non-readable.
from numpy import
Isnt [K]Ubuntu updated each 6 month?
2011/3/24 Dmitrey tm...@ukr.net:
hi,
when numpy in Linux apt will be updated? It's still 1.3.0 with many bugs
There will always be bugs, but numpy 1.3 is a stable release, unless
there is a bug that affects what your doing right now?
If you find a bug
Hi
2011/3/24 Dmitrey tm...@ukr.net
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing computations and
making text output completely non-readable.
Hi
2011/3/24 Dmitrey tm...@ukr.net
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing
Isnt [K]Ubuntu updated each 6 month?
2011/3/24 Dmitrey
tm...@ukr.net :
hi,
when numpy in Linux apt will be updated? It's still 1.3.0 with many bugs
There will always be bugs, but numpy 1.3 is a stable release, unless
there is a bug
Hi,
I got an Internal Error message when trying to log into the Trac page.
My comment:
Could there at least be a note added to the current memmap doc string,
stating that there is a problem with the current doc; also a link to
http://projects.scipy.org/numpy/ticket/97
would be much better than
hi,
is there any way to get argmin and argmax of an array w/o nans?
Currently I have
from numpy import *
argmax([10,nan,100])
1
argmin([10,nan,100])
1
But it's not the values I would like to get.
The walkaround I use: get all indeces of nans, replace them by -inf,
2011/3/24 Dmitrey tm...@ukr.net:
hi,
is there any way to get argmin and argmax of an array w/o nans?
Currently I have
from numpy import *
argmax([10,nan,100])
1
argmin([10,nan,100])
1
But it's not the values I would like to get.
The walkaround I use: get all indeces of nans, replace
Thanks for all those instructions, however, personally I don't need them, I
have sucseeded with my own manipulations and even if I wouldn't I always can
build numpy/scipy from sources.
I mere care for quality and easibility of numpy installation for ordinary
non-skilled users. They may just
On Thu, Mar 24, 2011 at 12:38 PM, Sebastian Haase seb.ha...@gmail.com wrote:
Hi,
I got an Internal Error message when trying to log into the Trac page.
That happens a lot, the solution is just to retry.
My comment:
Could there at least be a note added to the current memmap doc string,
In a numpy array of m x n size, I would like to delete few rows when
a given element in that row is ‘nan’ or say any other value.
For e.g. as in example given below, if I wish to delete a row when
the 3rd element of row is zero, or if 3rd, 4th, 5th element are zero
or either of 3rd,
2011/3/24 Dmitrey tm...@ukr.net:
Hi
2011/3/24 Dmitrey tm...@ukr.net
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing computations
and making text
On Thu, Mar 24, 2011 at 6:19 AM, Ralf Gommers
ralf.gomm...@googlemail.com wrote:
2011/3/24 Dmitrey tm...@ukr.net:
hi,
is there any way to get argmin and argmax of an array w/o nans?
Currently I have
from numpy import *
argmax([10,nan,100])
1
argmin([10,nan,100])
1
But it's not the values
2011/3/24 Dmitrey
tm...@ukr.net :
hi,
is there any way to get argmin and argmax of an array w/o nans?
Currently I have
from numpy import *
argmax([10,nan,100])
1
argmin([10,nan,100])
1
But it's not the values I would like
On Thu, Mar 24, 2011 at 9:45 AM, Ralf Gommers
ralf.gomm...@googlemail.com wrote:
2011/3/24 Dmitrey tm...@ukr.net:
Hi
2011/3/24 Dmitrey tm...@ukr.net
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled
Hi
On Thu, Mar 24, 2011 at 4:17 PM, Skipper Seabold jsseab...@gmail.comwrote:
On Thu, Mar 24, 2011 at 9:45 AM, Ralf Gommers
ralf.gomm...@googlemail.com wrote:
2011/3/24 Dmitrey tm...@ukr.net:
Hi
2011/3/24 Dmitrey tm...@ukr.net
from numpy import inf, array
inf*0
nan
(ok)
On Thu, Mar 24, 2011 at 10:52 AM, eat e.antero.ta...@gmail.com wrote:
Hi
On Thu, Mar 24, 2011 at 4:17 PM, Skipper Seabold jsseab...@gmail.com
snip
Also, as Robert pointed out to me before np.errstate is a
context-manager for ignoring these warnings. I often wrap optimization
code with it.
On Wed, Mar 23, 2011 at 9:29 PM, Ralf Gommers
ralf.gomm...@googlemail.com wrote:
On Wed, Mar 23, 2011 at 8:32 PM, Pauli Virtanen p...@iki.fi wrote:
On Wed, 23 Mar 2011 14:17:20 -0500, Bruce Southey wrote:
I can not figure out what is different between git and this version :-(
All the paths
2011/3/24 Dmitrey tm...@ukr.net:
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing computations and
making text output completely non-readable.
from numpy
On Thu, Mar 24, 2011 at 5:11 PM, Robert Kern robert.k...@gmail.com wrote:
2011/3/24 Dmitrey tm...@ukr.net:
from numpy import inf, array
inf*0
nan
(ok)
array(inf) * 0.0
StdErr: Warning: invalid value encountered in multiply
nan
My cycled calculations yields this thousands times slowing
On Thu, Mar 24, 2011 at 6:19 AM, Ralf Gommers
ralf.gomm...@googlemail.com wrote:
2011/3/24 Dmitrey tm...@ukr.net :
hi,
is there any way to get argmin and argmax of an array w/o nans?
Currently I have
from numpy import *
2011/3/24 Dmitrey tm...@ukr.net:
Are there any plans for merging bottleneck into numpy?
No plans, but no particular opposition. bottleneck is a good place to
experiment with these optimizations. When they settle, it might be
worth folding them back in.
Also, are those benchmarks valid for
I am looking for a partial least sqaures code refactoring for two (X,Y)
matrices. I found the following, but they not not work for me:
1. MDP: Factors only one matrix (am I wrong?)
2. pychem: Windows only code (I use Linux)
3. chemometrics from Koders: I get a singularity error.
4. pca_module (By
2011/3/24 Nadav Horesh nad...@visionsense.com:
I am looking for a partial least sqaures code refactoring for two (X,Y)
matrices. I found the following, but they not not work for me:
1. MDP: Factors only one matrix (am I wrong?)
2. pychem: Windows only code (I use Linux)
3. chemometrics from
On Thu, Mar 24, 2011 at 12:34 AM, Derek Homeier
de...@astro.physik.uni-goettingen.de wrote:
Hi again,
On 23 Mar 2011, at 17:07, Ralf Gommers wrote:
I am pleased to announce the availability of the first beta of NumPy
1.6.0. Due to the extensive changes in the Numpy core for this
release,
On 24/03/11 10:00, Dmitrey wrote:
hi,
when numpy in Linux apt will be updated? It's still 1.3.0 with many bugs
I have Linux KUBUNTU 10.10
D.
(k)ubuntu 11.04 (to be released in april) will have at numpy 1.5.1 (or possible
newer)
https://launchpad.net/ubuntu/+source/python-numpy
also scipy
On Thu, Mar 24, 2011 at 12:06:56PM -0700, Nadav Horesh wrote:
I am looking for a partial least sqaures code refactoring for two (X,Y)
matrices. I found the following, but they not not work for me:
We have had a PLS code contributed in the scikits learn very recently:
On Thu, Mar 24, 2011 at 08:15:12PM +0100, Olivier Grisel wrote:
2011/3/24 Nadav Horesh nad...@visionsense.com:
I am looking for a partial least sqaures code refactoring for two (X,Y)
matrices. I found the following, but they not not work for me:
1. MDP: Factors only one matrix (am I wrong?)
Yes, he is. I'll work on it early next week, and post any comment I'll have.
Documentation quality: The code doc refer to an excellent reference [Wegelin et
al. 2000], so no real problem here. If the reference is critical I would
suggest on of the following:
1. Put a link to the document.
2. Is
I have done some work on scipy.ndimage.measurements, and was adding to
it recently when I noticed I had made use of the idiom
A[X] = Y
with repeated indices in X, relying on the behavior that the last X,Y
pair at each unique X is the one that is assigned in A (last = last by
position in X).
I
On Thu, Mar 24, 2011 at 01:57:46PM -0700, Nadav Horesh wrote:
The code doc refer to an excellent reference [Wegelin et al. 2000], so
no real problem here. If the reference is critical I would suggest on
of the following:
1. Put a link to the document.
Do you have one? I'd be happy to add
On 24.03.2011, at 9:11AM, Pearu Peterson wrote:
Intel-64bit:
ERROR: test_assumed_shape.TestAssumedShapeSumExample.test_all
--
Traceback (most recent call last):
File /sw/lib/python3.2/site-packages/nose/case.py, line 372,
Hi Mark, hi all,
I noticed you did a lot of cleaning in the bug trackers, thank you for
helping there, this is sorely needed.
However, I noticed quite a few tickets were closed as wontfix even
though they are valid. I understand the concern of getting many
languishing tickets, but one should
On Fri, Mar 25, 2011 at 1:44 AM, Derek Homeier
de...@astro.physik.uni-goettingen.de wrote:
On 24.03.2011, at 9:11AM, Pearu Peterson wrote:
Intel-64bit:
ERROR: test_assumed_shape.TestAssumedShapeSumExample.test_all
--
42 matches
Mail list logo