Hi,
this is probaby an unusual question here from someone used to numpy who is
forced to work with matlab and it is not exactly the right place to ask. Sorry
for that.
Is there something like broadcasting in matlab? E.g. how can I do something
like that:
a = ones((50,50), dtype=float)
time =
Or
np.multiply.outer(a,b)
Nadav
-הודעה מקורית-
מאת: numpy-discussion-boun...@scipy.org בשם Robert Kern
נשלח: ה 17-ספטמבר-09 00:40
אל: Discussion of Numerical Python
נושא: Re: [Numpy-discussion] array multiplication
2009/9/16 Ernest Adrogu? :
> Hi,
>
> I have two 1-d arrays (a and b)
On 16-Sep-09, at 8:22 PM, Gökhan Sever wrote:
> Hello all,
>
> I want to be able to count predefined simple rectangle shapes on an
> image as
> shown like in this one: http://img7.imageshack.us/img7/2327/particles.png
>
> Which is in my case to count all the blue pixels (they are ice-snow
> fl
On 9/16/2009 8:22 PM, Gökhan Sever wrote:
> I want to be able to count predefined simple rectangle shapes on an
> image as shown like in this one:
> http://img7.imageshack.us/img7/2327/particles.png
ch.9 of
http://www.amazon.com/Beginning-Python-Visualization-Transformation-Professionals/dp/14302
Hello all,
I want to be able to count predefined simple rectangle shapes on an image as
shown like in this one: http://img7.imageshack.us/img7/2327/particles.png
Which is in my case to count all the blue pixels (they are ice-snow flake
shadows in reality) in one of the column.
What is the way to
2009/9/16 Ernest Adrogué :
> Hi,
>
> I have two 1-d arrays (a and b), and I want to create a
> third 2-d array, whose rows are of the form a[i]*b:
>
> c = np.zeros((len(a),b))
>
> c[0] = a[0]*b
> c[1] = a[1]*b
> .
> .
> .
>
> Is there an easy way to do this (e.g, without a loop)?
c = a[:,np.newaxi
Hi,
I have two 1-d arrays (a and b), and I want to create a
third 2-d array, whose rows are of the form a[i]*b:
c = np.zeros((len(a),b))
c[0] = a[0]*b
c[1] = a[1]*b
.
.
.
Is there an easy way to do this (e.g, without a loop)?
Thanks!
--
Ernest
___
N
On Wed, 16 Sep 2009 11:41:15 -0500
Robert Kern wrote:
> On Wed, Sep 16, 2009 at 11:39, Nils
>Wagner wrote:
>> Ran 2235 tests in 25.593s
>>
>> FAILED (KNOWNFAIL=1, errors=28, failures=1)
>> >failures=1>
> import numpy
> numpy.__version__
>> '1.4.0.dev7400'
>>
>> =
On Wed, Sep 16, 2009 at 11:39, Nils Wagner wrote:
> Ran 2235 tests in 25.593s
>
> FAILED (KNOWNFAIL=1, errors=28, failures=1)
>
import numpy
numpy.__version__
> '1.4.0.dev7400'
>
> ==
> ERROR: test_basic (test_defmatrix.
Ran 2235 tests in 25.593s
FAILED (KNOWNFAIL=1, errors=28, failures=1)
>>> import numpy
>>> numpy.__version__
'1.4.0.dev7400'
==
ERROR: test_basic (test_defmatrix.TestAlgebra)
-
My apologizes. I had remembered to remove the previous build
directory but not the target installation directory. After having
removed all traces of the previous numpy installation and do a clean
install I receive no new errors. Sorry for the false alarm.
Chris
--
Christopher Hanley
Se
On Thu, Sep 17, 2009 at 12:32 AM, Christopher Hanley wrote:
> Hi,
>
> When I try running the tests on a fresh build from the trunk I receive
> 28 errors. Most of the errors are of the form:
>
> "NameError: global name 'matrix' is not defined"
>
> It looks like there was some change to the numpy
Hi,
When I try running the tests on a fresh build from the trunk I receive
28 errors. Most of the errors are of the form:
"NameError: global name 'matrix' is not defined"
It looks like there was some change to the numpy namespace. I can
provide a full listing of the unit test errors if de
On Wed, Sep 16, 2009 at 5:10 AM, wrote:
> On Wed, Sep 16, 2009 at 4:42 AM, Pierre GM wrote:
>>
>> On Sep 16, 2009, at 4:25 AM, josef.p...@gmail.com wrote:
>>
>>> I have two structured arrays of different types. How can I
>>> horizontally concatenate the two arrays? Is there a direct way, or do
>
On Wed, Sep 16, 2009 at 4:42 AM, Pierre GM wrote:
>
> On Sep 16, 2009, at 4:25 AM, josef.p...@gmail.com wrote:
>
>> I have two structured arrays of different types. How can I
>> horizontally concatenate the two arrays? Is there a direct way, or do
>> I need to start from scratch?
>
> Check numpy.l
On Wed, Sep 16, 2009 at 4:25 AM, wrote:
> I have two structured arrays of different types. How can I
> horizontally concatenate the two arrays? Is there a direct way, or do
> I need to start from scratch?
>
> nobs = 10
> testdata = np.random.randint(3,
> size=(nobs,4)).view([('a',int),('b',int),(
On Sep 16, 2009, at 4:25 AM, josef.p...@gmail.com wrote:
> I have two structured arrays of different types. How can I
> horizontally concatenate the two arrays? Is there a direct way, or do
> I need to start from scratch?
Check numpy.lib.recfunctions, that should get you started.
__
I have two structured arrays of different types. How can I
horizontally concatenate the two arrays? Is there a direct way, or do
I need to start from scratch?
nobs = 10
testdata = np.random.randint(3,
size=(nobs,4)).view([('a',int),('b',int),('c',int),('d',int)])
testdatacont = np.random.normal( s
Hi,
I just wanted to mention I integrated a patch from some time ago to make
numpy.core independent from other numpy modules. This is really useful
when working on involved changes at the C level. This meant moving some
stuff around, in particular the matrix class and utilities is now into
numpy.m
19 matches
Mail list logo