Created
February 7, 2016 06:31
-
-
Save waTeim/0dd3ce0e0d3a3cd1c734 to your computer and use it in GitHub Desktop.
Some experimenting julia on a 3DR drone
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"libraries": | |
[ | |
"-lgfortran", <--- added | |
"-lopenblas", <--- added | |
"-ljulia" | |
] | |
} | |
"cflags": | |
[ | |
"-std=<(std)", "-Wno-strict-aliasing", "-march=armv7-a" <--- added | |
], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3dr_solo:~$ julia | |
WARNING: unable to determine host cpu name. | |
_ | |
_ _ _(_)_ | A fresh approach to technical computing | |
(_) | (_) (_) | Documentation: http://docs.julialang.org | |
_ _ _| |_ __ _ | Type "?help" for help. | |
| | | | | | |/ _` | | | |
| | |_| | | | (_| | | Version 0.5.0-dev+2336 (2016-01-28 14:53 UTC) | |
_/ |\__'_|_|_|\__'_| | Commit 9cda53d (9 days old master) | |
|__/ | arm-linux-gnueabihf | |
julia> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(node) child_process: options.customFds option is deprecated. Use options.stdio instead. | |
WARNING: unable to determine host cpu name. | |
Regression Tests | |
✓ eval Null return | |
✓ eval Null return (async) (57ms) | |
✓ eval Boolean return | |
✓ eval Integer return | |
✓ version | |
✓ eval max 32 bit Integer (4294967296) | |
✓ eval max JavaScript Integer (9007199254740992) | |
✓ eval primitive Float return | |
✓ eval max JavaScript Float (1.7976931348623157e+308) | |
✓ simple result return style for Eval | |
✓ tuple result return style for Eval | |
✓ exec identity Null | |
✓ exec identity Boolean | |
✓ exec identity Integer (42ms) | |
✓ exec identity Float (67ms) | |
✓ exec identity String | |
✓ simple result return style for Exec | |
✓ implicit conversion from SubString to String | |
✓ eval include | |
✓ exec include | |
✓ user defined functions via exec (86ms) | |
✓ macros via eval (739ms) | |
✓ arrays via eval (951ms) | |
✓ arrays via exec (1372ms) | |
✓ construction of Script using new (3557ms) | |
✓ construction of Script using function call like syntax | |
✓ script creation (via factory) | |
✓ script exec using return style (138ms) | |
✓ loading array type tests | |
✓ typecheck Null array elements (synchronously) | |
✓ typecheck Null array elements (asynchronously) | |
✓ typecheck Boolean array elements (synchronously) | |
✓ typecheck Boolean array elements (asynchronously) | |
✓ typecheck Integer array elements (synchronously) | |
✓ typecheck Integer array elements (asynchronously) | |
✓ typecheck Float array elements (synchronously) | |
✓ typecheck Float array elements (asynchronously) | |
✓ typecheck String array elements (synchronously) | |
✓ typecheck String array elements (asynchronously) | |
✓ typecheck [Boolean,Integer] -> [Integer] | |
✓ typecheck [Boolean,Float] -> [Float] | |
✓ typecheck [Boolean,String] -> [String] | |
✓ typecheck [Integer,Float] -> [Float] | |
✓ typecheck [Float,Integer] -> [Float] | |
✓ prevent widening String elements | |
✓ prevent widening Null elements | |
✓ 0 length array input (78ms) | |
✓ 0 length typed array output (133ms) | |
✓ 0 length array of Any | |
✓ 0 length array to 0 length array | |
✓ simple Integer array input (596ms) | |
✓ simple Float array input (650ms) | |
✓ simple String array input (999ms) | |
✓ array of null (56ms) | |
✓ array of elementwise conversion from SubString to String (251ms) | |
✓ native Int8Array to Array{Int8,1} (686ms) | |
✓ native Uint8Array to Array{Uint8,1} (579ms) | |
✓ native Int16Array to Array{Int16,1} (1127ms) | |
✓ native Uint16Array to Array{Uint16,1} (637ms) | |
✓ native Int32Array to Array{Int32,1} (46ms) | |
1) native Uint32Array to Array{Uint32,1} | |
✓ native Float32Array to Array{Float32,1} (633ms) | |
✓ native Float64Array to Array{Float64,1} | |
✓ buffer to Array{Uint8,1} and back as Buffer (233ms) | |
2) buffer to Array{Uint8,1} and back as reshaped Array | |
✓ multidimensional Array (44ms) | |
3) buffer to Multidimensional Array | |
✓ simplistic Regex (120ms) | |
✓ preserve Date value of now() (598ms) | |
✓ array of Date (57ms) | |
✓ array of Regex (85ms) | |
✓ JRef from eval (496ms) | |
✓ JRef from exec (435ms) | |
✓ JRef random creation and deletion (17719ms) | |
✓ array random creation and deletion (18702ms) | |
✓ 2D Array Request with Native Arrays (671ms) | |
✓ multidimensional Array Request with Native Arrays (2194ms) | |
✓ manually creating arrays of NativeArray for linear algebra (12638ms) | |
✓ ill-defined matrix via exception | |
✓ ill-defined matrix via err in callback | |
✓ eval syntax error (147ms) | |
✓ function search (not found) | |
✓ function deep search (not found) | |
✓ function deep[1] search (found) | |
✓ function deep[3] search (found) (366ms) | |
✓ Import (synchronous) (11418ms) | |
✓ Import (asynchronous) (268ms) | |
✓ Import non existant module attempt (8863ms) | |
✓ JuliaHandle of struct type | |
✓ Eval quote | |
✓ Shared Array (164ms) | |
✓ Equate jl_value_t Alloc with Javascript Object | |
✓ libm use (64ms) | |
✓ asynchronous call followed by process.nextTick() | |
✓ throw errors to the domain context | |
✓ set active domain inside timeout | |
✓ set active domain inside callback (53ms) | |
✓ set active domain inside callback when using bind() | |
✓ preserve scope | |
✓ eval Union Array ops (67ms) | |
97 passing (2m) | |
3 failing | |
1) Regression Tests native Uint32Array to Array{Uint32,1}: | |
AssertionError: expected 3589884592 to equal 429491729550000 | |
+ expected - actual | |
+429491729550000 | |
-3589884592 | |
at Context.<anonymous> (/home/jeffw/src/node-julia/test/test.js:507:38) | |
at callFn (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:250:21) | |
at Test.Runnable.run (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:243:7) | |
at Runner.runTest (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:373:10) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:451:12 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:298:14) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:308:7 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:246:23) | |
at Immediate._onImmediate (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:275:5) | |
at processImmediate [as _immediateCallback] (timers.js:383:17) | |
2) Regression Tests buffer to Array{Uint8,1} and back as reshaped Array: | |
ReferenceError: Julia unmatched method reshape(Array,Int64,Int64) | |
at ReferenceError (native) | |
at Object.module.exports.exec (/home/jeffw/src/node-julia/lib/nj.js:37:21) | |
at Context.<anonymous> (/home/jeffw/src/node-julia/test/test.js:544:23) | |
at callFn (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:250:21) | |
at Test.Runnable.run (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:243:7) | |
at Runner.runTest (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:373:10) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:451:12 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:298:14) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:308:7 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:246:23) | |
at Immediate._onImmediate (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:275:5) | |
at processImmediate [as _immediateCallback] (timers.js:383:17) | |
3) Regression Tests buffer to Multidimensional Array: | |
ReferenceError: Julia unmatched method reshape(Array,Int64,Int64,Int64,Int64) | |
at ReferenceError (native) | |
at Object.module.exports.exec (/home/jeffw/src/node-julia/lib/nj.js:37:21) | |
at Context.<anonymous> (/home/jeffw/src/node-julia/test/test.js:576:20) | |
at callFn (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:250:21) | |
at Test.Runnable.run (/home/jeffw/src/node-julia/node_modules/mocha/lib/runnable.js:243:7) | |
at Runner.runTest (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:373:10) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:451:12 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:298:14) | |
at /home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:308:7 | |
at next (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:246:23) | |
at Immediate._onImmediate (/home/jeffw/src/node-julia/node_modules/mocha/lib/runner.js:275:5) | |
at processImmediate [as _immediateCallback] (timers.js:383:17) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Regression Tests | |
✓ eval Null return | |
✓ eval Null return (async) | |
✓ eval Boolean return | |
✓ eval Integer return | |
✓ version | |
✓ eval max 32 bit Integer (4294967296) | |
✓ eval max JavaScript Integer (9007199254740992) | |
✓ eval primitive Float return | |
✓ eval max JavaScript Float (1.7976931348623157e+308) | |
✓ simple result return style for Eval | |
✓ tuple result return style for Eval | |
✓ exec identity Null | |
✓ exec identity Boolean | |
✓ exec identity Integer | |
✓ exec identity Float | |
✓ exec identity String | |
✓ simple result return style for Exec | |
✓ implicit conversion from SubString to String | |
✓ eval include | |
✓ exec include | |
✓ user defined functions via exec | |
✓ macros via eval (57ms) | |
✓ arrays via eval (60ms) | |
✓ arrays via exec | |
✓ construction of Script using new (204ms) | |
✓ construction of Script using function call like syntax | |
✓ script creation (via factory) | |
✓ script exec using return style | |
✓ loading array type tests | |
✓ typecheck Null array elements (synchronously) | |
✓ typecheck Null array elements (asynchronously) | |
✓ typecheck Boolean array elements (synchronously) | |
✓ typecheck Boolean array elements (asynchronously) | |
✓ typecheck Integer array elements (synchronously) | |
✓ typecheck Integer array elements (asynchronously) | |
✓ typecheck Float array elements (synchronously) | |
✓ typecheck Float array elements (asynchronously) | |
✓ typecheck String array elements (synchronously) | |
✓ typecheck String array elements (asynchronously) | |
✓ typecheck [Boolean,Integer] -> [Integer] | |
✓ typecheck [Boolean,Float] -> [Float] | |
✓ typecheck [Boolean,String] -> [String] | |
✓ typecheck [Integer,Float] -> [Float] | |
✓ typecheck [Float,Integer] -> [Float] | |
✓ prevent widening String elements | |
✓ prevent widening Null elements | |
✓ 0 length array input | |
✓ 0 length typed array output | |
✓ 0 length array of Any | |
✓ 0 length array to 0 length array | |
✓ simple Integer array input | |
✓ simple Float array input | |
✓ simple String array input (80ms) | |
✓ array of null | |
✓ array of elementwise conversion from SubString to String | |
✓ native Int8Array to Array{Int8,1} | |
✓ native Uint8Array to Array{Uint8,1} | |
✓ native Int16Array to Array{Int16,1} | |
✓ native Uint16Array to Array{Uint16,1} | |
✓ native Int32Array to Array{Int32,1} | |
✓ native Uint32Array to Array{Uint32,1} | |
✓ native Float32Array to Array{Float32,1} | |
✓ native Float64Array to Array{Float64,1} | |
✓ buffer to Array{Uint8,1} and back as Buffer | |
✓ buffer to Array{Uint8,1} and back as reshaped Array (44ms) | |
✓ multidimensional Array | |
✓ buffer to Multidimensional Array | |
✓ simplistic Regex | |
✓ preserve Date value of now() | |
✓ array of Date | |
✓ array of Regex | |
✓ JRef from eval (44ms) | |
✓ JRef from exec | |
✓ JRef random creation and deletion (549ms) | |
✓ array random creation and deletion (473ms) | |
✓ 2D Array Request with Native Arrays | |
✓ multidimensional Array Request with Native Arrays (120ms) | |
✓ manually creating arrays of NativeArray for linear algebra (879ms) | |
✓ ill-defined matrix via exception | |
✓ ill-defined matrix via err in callback | |
✓ eval syntax error (318ms) | |
✓ function search (not found) | |
✓ function deep search (not found) | |
✓ function deep[1] search (found) | |
✓ function deep[3] search (found) | |
✓ Import (synchronous) (829ms) | |
✓ Import (asynchronous) | |
✓ Import non existant module attempt (543ms) | |
✓ JuliaHandle of struct type | |
✓ Eval quote | |
✓ Shared Array | |
✓ Equate jl_value_t Alloc with Javascript Object | |
✓ libm use | |
✓ asynchronous call followed by process.nextTick() | |
✓ throw errors to the domain context | |
✓ set active domain inside timeout | |
✓ set active domain inside callback | |
✓ set active domain inside callback when using bind() | |
✓ preserve scope | |
✓ eval Union Array ops | |
100 passing (5s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
julia> @time A = rand(100,100); | |
1.082110 seconds (55.08 k allocations: 1.510 MB) | |
julia> @time A = rand(100,100); | |
0.000501 seconds (7 allocations: 78.344 KB) | |
julia> @time A = rand(100,100); | |
0.000494 seconds (7 allocations: 78.344 KB) | |
julia> @time B = svd(A); | |
2.953222 seconds (118.28 k allocations: 3.843 MB) | |
julia> @time B = svd(A); | |
0.057843 seconds (27 allocations: 557.094 KB) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment