julia lang - How to set values to the elements of DArray? -


I'm looking for parallel computing Julia and tried this:

  A = dzeros (5); A [1] = 5   

but just got this error:

  setindex! DArray {{Float64, 1, array {Float64, 1}}    

Well, I thought Manuel said setindex! is fully implemented by DARRA What am I missing?

I was using v0.2.1 for Windows 32-bit.

I'm just an investigator, but after reading, I tried to do what works It seemed.

  $ / julia _ _ _ _ _ _ _ _ _ _ _ | A new approach to technical computing (_). (_) (_) | Documentation: http://docs.julialang.org _ _ _ | | _ _ _ _ _ _ | Type "help" to list support topics. | | | | | | / _` | | | | | _ | | | | (_ | | | Version 0.3.0-prerelease + 2703 (2014-04-22 18:57 UTC) _ / | \ __'_ | _ | _ | \ __'_ | | committed 942ae42 * (0 day old Master) | __ / | i686-redhat-linux Julia & gt; versioninfo () Julia version 0.3.0-prerelease + 2703 committed 942ae42 * (2014-04-22 18:57 UTC) platform information system: Linux (i686-redhat-linux) CPU: genuine Intel (R) CPU T2250 @ 1.73GHz WORD_SIZE: 32 BLAS: libopenblas (DYNAMIC_ARCH NO_AFFINITY) LAPACK: libopenblas LIBM: libopenlibm Julia & gt; = dzeros (5) 5-element DArray {Float64 1, the array {Float64, 1}}: 0.0 0.0 0.0 0.0 0.0 Julia & gt; localpart (a) [1] = 5 5 Julia & gt; a 5 element DArray {Float64,1, array {Float64 0.0} 0.0 0.0 0.0 0.0 Julia>   

It seems that distributed arrays are not "local" unless you "local" them.

Comments

Popular posts from this blog

Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -

multithreading - PhantomJS-Node in a for Loop -

c++ - MATLAB .m file to .mex file using Matlab Compiler -