julia 1.10.10shuffle(1:3000)[1:2000]; julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) end argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds), x, 10) 0.324903 324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided there is enough0 码力 | 1692 页 | 6.34 MB | 4 月前3
Julia 1.10.9shuffle(1:3000)[1:2000]; julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) end argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds), x, 10) 0.324903 324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided there is enough0 码力 | 1692 页 | 6.34 MB | 4 月前3
Julia 1.11.4PERFORMANCE TIPS 466 julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) end argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds), x, 10) 0.324903 324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided there is enough0 码力 | 2007 页 | 6.73 MB | 4 月前3
Julia 1.11.5 DocumentationPERFORMANCE TIPS 466 julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) end argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds), x, 10) 0.324903 324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided there is enough0 码力 | 2007 页 | 6.73 MB | 4 月前3
Julia 1.11.6 Release NotesPERFORMANCE TIPS 466 julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) end argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds), x, 10) 0.324903 324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided there is enough0 码力 | 2007 页 | 6.73 MB | 4 月前3
julia 1.13.0 DEVjulia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) endCHAPTER 35. PERFORMANCE TIPS 480 argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds) inds), x, 10) 0.324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided0 码力 | 2058 页 | 7.45 MB | 4 月前3
Julia 1.12.0 RC1julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) endCHAPTER 35. PERFORMANCE TIPS 481 argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds) inds), x, 10) 0.324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided0 码力 | 2057 页 | 7.44 MB | 4 月前3
Julia 1.12.0 Beta4julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) endCHAPTER 35. PERFORMANCE TIPS 480 argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds) inds), x, 10) 0.324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided0 码力 | 2057 页 | 7.44 MB | 4 月前3
Julia 1.12.0 Beta3julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) endCHAPTER 35. PERFORMANCE TIPS 480 argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds) inds), x, 10) 0.324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided0 码力 | 2057 页 | 7.44 MB | 4 月前3
julia 1.12.0 beta1julia> function iterated_neural_network(A, x, depth) for _ in 1:depth x .= max.(0, A * x) endCHAPTER 35. PERFORMANCE TIPS 480 argmax(x) end julia> @time iterated_neural_network(view(A, inds, inds) inds), x, 10) 0.324903 seconds (12 allocations: 157.562 KiB) 1569 julia> @time iterated_neural_network(A[inds, inds], x, 10) 0.054576 seconds (13 allocations: 30.671 MiB, 13.33% gc time) 1569 Provided0 码力 | 2047 页 | 7.41 MB | 4 月前3
共 18 条
- 1
- 2













