From a96ab71672bc05ce46485a1f3839519df273fd7b Mon Sep 17 00:00:00 2001 From: GitHub Actions Date: Wed, 15 Nov 2023 10:06:33 +0000 Subject: [PATCH] markdown source builds Auto-generated via {sandpaper} Source : 0cfd0765c5c8a44d8bc4e556a62c04cf5551b254 Branch : main Author : github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Time : 2023-11-15 10:05:33 +0000 Message : [create-pull-request] automated change (#74) Co-authored-by: Simon Christ --- 04_Using_the_package_manager.md | 2 +- 05_Write_functions.md | 17 +++++++++++++++-- 07_Loops.md | 30 +++++++++++++++--------------- 10_Adding_tests.md | 4 ++-- md5sum.txt | 8 ++++---- 5 files changed, 37 insertions(+), 24 deletions(-) diff --git a/04_Using_the_package_manager.md b/04_Using_the_package_manager.md index 3df83bfa..8470b8c8 100644 --- a/04_Using_the_package_manager.md +++ b/04_Using_the_package_manager.md @@ -121,7 +121,7 @@ environment. ```` Status `~/projects/trebuchet/Project.toml` [f6369f11] ForwardDiff v0.10.36 - [295af30f] Revise v3.5.7 + [295af30f] Revise v3.5.9 [98b73d46] Trebuchet v0.2.2 ```` diff --git a/05_Write_functions.md b/05_Write_functions.md index 1a9906e1..f8e731bb 100644 --- a/05_Write_functions.md +++ b/05_Write_functions.md @@ -350,9 +350,9 @@ Closest candidates are: size(::AbstractArray{T, N}, !Matched::Any) where {T, N} @ Base abstractarray.jl:42 size(!Matched::Union{LinearAlgebra.QR, LinearAlgebra.QRCompactWY, LinearAlgebra.QRPivoted}) - @ LinearAlgebra /opt/hostedtoolcache/julia/1.9.3/x64/share/julia/stdlib/v1.9/LinearAlgebra/src/qr.jl:582 + @ LinearAlgebra /opt/hostedtoolcache/julia/1.9.4/x64/share/julia/stdlib/v1.9/LinearAlgebra/src/qr.jl:582 size(!Matched::Union{LinearAlgebra.QR, LinearAlgebra.QRCompactWY, LinearAlgebra.QRPivoted}, !Matched::Integer) - @ LinearAlgebra /opt/hostedtoolcache/julia/1.9.3/x64/share/julia/stdlib/v1.9/LinearAlgebra/src/qr.jl:581 + @ LinearAlgebra /opt/hostedtoolcache/julia/1.9.4/x64/share/julia/stdlib/v1.9/LinearAlgebra/src/qr.jl:581 ... ```` @@ -425,6 +425,19 @@ She can also lookup the docstring using the `@doc` macro Return a tuple with the size of the buffer. + size(s::Sampleable) + + The size (i.e. shape) of each sample. Always returns () when s is + univariate, and (length(s),) when s is multivariate. + + size(d::MultivariateDistribution) + + Return the sample size of distribution d, i.e (length(d),). + + size(d::MatrixDistribution) + + Return the size of each sample from distribution d. + size(g, i) Return the number of vertices in g if i=1 or i=2, or 1 otherwise. diff --git a/07_Loops.md b/07_Loops.md index 09530f64..b9e4f49f 100644 --- a/07_Loops.md +++ b/07_Loops.md @@ -106,8 +106,8 @@ Trebuchet( rand() * 500, rand() * pi/2 ) ````output 2-element Trebuchet: - 376.178140632858 - 1.202932191168969 + 19.92126761754809 + 1.1758129035479739 ```` will give her a Trebuchet with a weight between 0 and 500 and a release angle between 0 and pi/2 radians at random. @@ -121,9 +121,9 @@ distances = [shoot_distance(Trebuchet(rand() * 500, rand() * pi / 2), env) for _ ````output 3-element Vector{Float64}: - 116.46124636135293 - 52.7811798347779 - 104.89623248181303 + 106.68417294212176 + 116.21335516132379 + 73.730294183957 ```` This is called an _array comprehension_. @@ -138,16 +138,16 @@ distances = [(w,a) => shoot_distance(Trebuchet(w, a), env) for (w, a) in zip(wei ````output 10-element Vector{Pair{Tuple{Float64, Float64}, Float64}}: - (407.1030550189028, 0.3891512578388659) => 112.09184022880909 - (129.3962122859022, 0.47410570172882877) => 97.15862611465982 - (460.1656325336061, 0.985034729119892) => 99.11003543196146 - (110.51399719143818, 1.1558775471416098) => 61.0114196763061 - (265.81455100189766, 0.8247629754893243) => 104.58648053317526 - (96.13278884246179, 0.27533670195930326) => 77.83567463291564 - (12.485336793085056, 0.9864156252374033) => 0.6815707596179541 - (352.3464102053692, 1.2580446062583366) => 59.37739417570197 - (391.36673118879764, 1.195168563100913) => 73.94484391737066 - (477.81826452742524, 0.048738054505380206) => 69.01930432439035 + (181.72785884820692, 0.397146829944134) => 101.73108411880898 + (63.630046905466806, 0.0007390075864837765) => 38.578677436450356 + (381.07768051820875, 0.14798050038431537) => 87.06414198100867 + (282.3416703597322, 1.1918686477537617) => 69.0089195197084 + (368.30808129827875, 0.0067941316204262366) => 59.34525074762748 + (344.7882424260206, 0.3851870910679704) => 111.70986370160507 + (372.4460093501431, 0.06855206373789495) => 72.63633120284015 + (360.2628661185558, 1.4172206158209621) => 32.342739435405775 + (43.15599567794415, 0.631090875891836) => 59.136515031317124 + (483.7790756755326, 0.8497073005978015) => 110.42731071869284 ```` ### Gradient descent diff --git a/10_Adding_tests.md b/10_Adding_tests.md index c17ddc82..ba3de27a 100644 --- a/10_Adding_tests.md +++ b/10_Adding_tests.md @@ -55,7 +55,7 @@ end ```` ````output -Test.DefaultTestSet("Test arithmetic equalities", Any[], 1, false, false, true, 1.698515973154304e9, 1.698515973191453e9, false) +Test.DefaultTestSet("Test arithmetic equalities", Any[], 1, false, false, true, 1.700042192846853e9, 1.70004219287704e9, false) ```` With this Melissa can run her test using the pkg mode of the REPL: @@ -76,7 +76,7 @@ Thus it is possible to move the `Test` entry in the `Project.toml` file from test = ["Test"] ``` -Check out the [sample project file](../code/Project.toml) for a complete +Check out the [sample project file](https://github.com/carpentries-incubator/julia-novice/blob/main/code/Project.toml) for a complete example. :::::: challenge diff --git a/md5sum.txt b/md5sum.txt index 17ed696e..0099cfa0 100644 --- a/md5sum.txt +++ b/md5sum.txt @@ -6,13 +6,13 @@ "episodes/01_Introduction.md" "be6000ec05fac6b6d3a91844d6f0813c" "site/built/01_Introduction.md" "2023-10-28" "episodes/02_Getting_started.md" "495e9cfb66b976f3eda5f5c63f86ec43" "site/built/02_Getting_started.md" "2023-08-11" "episodes/03_Julia_type_system.md" "b6171687acb673693aa4426ea7c0a457" "site/built/03_Julia_type_system.md" "2023-08-29" -"episodes/04_Using_the_package_manager.md" "f9824c2377ae7903908d41eb7dad81fe" "site/built/04_Using_the_package_manager.md" "2023-10-28" -"episodes/05_Write_functions.md" "31bc3b613341fa6d11a89627b5505d6b" "site/built/05_Write_functions.md" "2023-10-28" +"episodes/04_Using_the_package_manager.md" "c23d0d43e6e19566d5b688eac98e1b2b" "site/built/04_Using_the_package_manager.md" "2023-11-15" +"episodes/05_Write_functions.md" "d0713d463a89b6d499dd5ca0038f92eb" "site/built/05_Write_functions.md" "2023-11-15" "episodes/06_Interfacing_conditions.md" "863dd936d48211fce940b6acad106396" "site/built/06_Interfacing_conditions.md" "2023-09-15" -"episodes/07_Loops.md" "78f397d3e32b5c6bf384e103b6c8dd44" "site/built/07_Loops.md" "2023-10-28" +"episodes/07_Loops.md" "b34e3f87b11e07532fc31c367e3745b2" "site/built/07_Loops.md" "2023-11-15" "episodes/08_Using_Modules.md" "da6022154b3eb62695cc439360f5f33d" "site/built/08_Using_Modules.md" "2023-09-15" "episodes/09_Creating_Packages.md" "df0405efb3ed34a352703867ec70f55f" "site/built/09_Creating_Packages.md" "2023-09-15" -"episodes/10_Adding_tests.md" "cfc02857f05283970738cda8f22d4586" "site/built/10_Adding_tests.md" "2023-10-28" +"episodes/10_Adding_tests.md" "0ce3375b8f7fcbabfe98a64c592206b9" "site/built/10_Adding_tests.md" "2023-11-15" "episodes/11_Wrapping_Up.md" "d8ff57c6e35d1501e5b9f366b725a2f4" "site/built/11_Wrapping_Up.md" "2023-09-15" "instructors/instructor-notes.md" "a59fd3b94c07c3fe3218c054a0f03277" "site/built/instructor-notes.md" "2023-08-09" "learners/discuss.md" "2758e2e5abd231d82d25c6453d8abbc6" "site/built/discuss.md" "2023-08-09"