Graphed out generations
This commit is contained in:
parent
3d0f308a2e
commit
8853f34551
@ -2,7 +2,7 @@
|
|||||||
"cells": [
|
"cells": [
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 11,
|
"execution_count": 1,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [
|
"outputs": [
|
||||||
{
|
{
|
||||||
@ -13,17 +13,17 @@
|
|||||||
"│ df[!, col_ind] = v\n",
|
"│ df[!, col_ind] = v\n",
|
||||||
"│ df\n",
|
"│ df\n",
|
||||||
"│ end` instead.\n",
|
"│ end` instead.\n",
|
||||||
"│ caller = top-level scope at Experiment.jl:25\n",
|
"│ caller = top-level scope at Experiment.jl:25 [inlined]\n",
|
||||||
"└ @ Core /home/jake/Projects/gp-experiment/Experiment.jl:25\n"
|
"└ @ Core /home/jake/project/beef-o-bradys-state-space-search/Experiment.jl:25\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"data": {
|
"data": {
|
||||||
"text/plain": [
|
"text/plain": [
|
||||||
"main (generic function with 2 methods)"
|
"main (generic function with 1 method)"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"execution_count": 11,
|
"execution_count": 1,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"output_type": "execute_result"
|
"output_type": "execute_result"
|
||||||
}
|
}
|
||||||
@ -34,7 +34,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 12,
|
"execution_count": 3,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [
|
"outputs": [
|
||||||
{
|
{
|
||||||
@ -43,7 +43,7 @@
|
|||||||
"4"
|
"4"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"execution_count": 12,
|
"execution_count": 3,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"output_type": "execute_result"
|
"output_type": "execute_result"
|
||||||
}
|
}
|
||||||
@ -58,7 +58,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 13,
|
"execution_count": 4,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [
|
"outputs": [
|
||||||
{
|
{
|
||||||
@ -67,24 +67,65 @@
|
|||||||
"text": [
|
"text": [
|
||||||
"┌ Warning: `getindex(df::DataFrame, col_ind::ColumnIndex)` is deprecated, use `df[!, col_ind]` instead.\n",
|
"┌ Warning: `getindex(df::DataFrame, col_ind::ColumnIndex)` is deprecated, use `df[!, col_ind]` instead.\n",
|
||||||
"│ caller = fitness(::DataFrames.DataFrame) at Experiment.jl:67\n",
|
"│ caller = fitness(::DataFrames.DataFrame) at Experiment.jl:67\n",
|
||||||
"└ @ Main /home/jake/Projects/gp-experiment/Experiment.jl:67\n"
|
"└ @ Main /home/jake/project/beef-o-bradys-state-space-search/Experiment.jl:67\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"data": {
|
"data": {
|
||||||
"text/plain": [
|
"text/plain": [
|
||||||
"Dict{Integer,Float64} with 11 entries:\n",
|
"Dict{Integer,Float64} with 11 entries:\n",
|
||||||
" 2 => 220.0\n",
|
" 2 => 20.0\n",
|
||||||
" 11 => 20.0\n",
|
" 11 => 20.0\n",
|
||||||
" 7 => 20.0\n",
|
" 7 => 20.0\n",
|
||||||
" 9 => 20.0\n",
|
" 9 => 20.0\n",
|
||||||
" 10 => 20.0\n",
|
" 10 => 20.0\n",
|
||||||
" 8 => 20.0\n",
|
" 8 => 20.0\n",
|
||||||
" 6 => 70.0\n",
|
" 6 => 20.0\n",
|
||||||
" 4 => 70.0\n",
|
" 4 => 20.0\n",
|
||||||
" 3 => 70.0\n",
|
" 3 => 20.0\n",
|
||||||
" 5 => 70.0\n",
|
" 5 => 20.0\n",
|
||||||
" 1 => 330.0"
|
" 1 => 50.0"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"execution_count": 4,
|
||||||
|
"metadata": {},
|
||||||
|
"output_type": "execute_result"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"source": [
|
||||||
|
"main(10)"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"execution_count": 13,
|
||||||
|
"metadata": {},
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"data": {
|
||||||
|
"text/plain": [
|
||||||
|
"OrderedCollections.OrderedDict{Integer,Float64} with 21 entries:\n",
|
||||||
|
" 1 => 150.0\n",
|
||||||
|
" 2 => 150.0\n",
|
||||||
|
" 3 => 150.0\n",
|
||||||
|
" 4 => 10.0\n",
|
||||||
|
" 5 => 10.0\n",
|
||||||
|
" 6 => 10.0\n",
|
||||||
|
" 7 => 10.0\n",
|
||||||
|
" 8 => 10.0\n",
|
||||||
|
" 9 => 10.0\n",
|
||||||
|
" 10 => 10.0\n",
|
||||||
|
" 11 => 10.0\n",
|
||||||
|
" 12 => 10.0\n",
|
||||||
|
" 13 => 10.0\n",
|
||||||
|
" 14 => 0.0\n",
|
||||||
|
" 15 => 0.0\n",
|
||||||
|
" 16 => 0.0\n",
|
||||||
|
" 17 => 0.0\n",
|
||||||
|
" 18 => 0.0\n",
|
||||||
|
" 19 => 0.0\n",
|
||||||
|
" 20 => 0.0\n",
|
||||||
|
" 21 => 0.0"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"execution_count": 13,
|
"execution_count": 13,
|
||||||
@ -93,7 +134,159 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"source": [
|
"source": [
|
||||||
"main(10)"
|
"using Plots\n",
|
||||||
|
"res = main(20)\n",
|
||||||
|
"res = sort(res)"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "markdown",
|
||||||
|
"metadata": {},
|
||||||
|
"source": [
|
||||||
|
"# Results\n",
|
||||||
|
"Shown by tweaking the parameters of popsize, mu, lambda, targetcalories, and candidatesize.\n",
|
||||||
|
"\n",
|
||||||
|
"## Gadfly\n",
|
||||||
|
"Julia plotting library based on Grammar of Graphics."
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"execution_count": 15,
|
||||||
|
"metadata": {},
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"data": {
|
||||||
|
"image/svg+xml": [
|
||||||
|
"<?xml version=\"1.0\" encoding=\"utf-8\"?>\n",
|
||||||
|
"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" width=\"600\" height=\"400\" viewBox=\"0 0 2400 1600\">\n",
|
||||||
|
"<defs>\n",
|
||||||
|
" <clipPath id=\"clip2900\">\n",
|
||||||
|
" <rect x=\"0\" y=\"0\" width=\"2400\" height=\"1600\"/>\n",
|
||||||
|
" </clipPath>\n",
|
||||||
|
"</defs>\n",
|
||||||
|
"<polygon clip-path=\"url(#clip2900)\" points=\"\n",
|
||||||
|
"0,1600 2400,1600 2400,0 0,0 \n",
|
||||||
|
" \" fill=\"#ffffff\" fill-rule=\"evenodd\" fill-opacity=\"1\"/>\n",
|
||||||
|
"<defs>\n",
|
||||||
|
" <clipPath id=\"clip2901\">\n",
|
||||||
|
" <rect x=\"480\" y=\"0\" width=\"1681\" height=\"1600\"/>\n",
|
||||||
|
" </clipPath>\n",
|
||||||
|
"</defs>\n",
|
||||||
|
"<polygon clip-path=\"url(#clip2900)\" points=\"\n",
|
||||||
|
"167.279,1487.47 2352.76,1487.47 2352.76,47.2441 167.279,47.2441 \n",
|
||||||
|
" \" fill=\"#ffffff\" fill-rule=\"evenodd\" fill-opacity=\"1\"/>\n",
|
||||||
|
"<defs>\n",
|
||||||
|
" <clipPath id=\"clip2902\">\n",
|
||||||
|
" <rect x=\"167\" y=\"47\" width=\"2186\" height=\"1441\"/>\n",
|
||||||
|
" </clipPath>\n",
|
||||||
|
"</defs>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 641.486,1487.47 641.486,47.2441 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 1156.93,1487.47 1156.93,47.2441 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 1672.37,1487.47 1672.37,47.2441 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 2187.81,1487.47 2187.81,47.2441 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,1446.71 2352.76,1446.71 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,993.811 2352.76,993.811 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,540.908 2352.76,540.908 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#000000; stroke-width:2; stroke-opacity:0.1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,88.0053 2352.76,88.0053 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,1487.47 2352.76,1487.47 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,1487.47 167.279,47.2441 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 641.486,1487.47 641.486,1465.87 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 1156.93,1487.47 1156.93,1465.87 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 1672.37,1487.47 1672.37,1465.87 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 2187.81,1487.47 2187.81,1465.87 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,1446.71 200.061,1446.71 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,993.811 200.061,993.811 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,540.908 200.061,540.908 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 167.279,88.0053 200.061,88.0053 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:middle;\" transform=\"rotate(0, 641.486, 1541.47)\" x=\"641.486\" y=\"1541.47\">5</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:middle;\" transform=\"rotate(0, 1156.93, 1541.47)\" x=\"1156.93\" y=\"1541.47\">10</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:middle;\" transform=\"rotate(0, 1672.37, 1541.47)\" x=\"1672.37\" y=\"1541.47\">15</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:middle;\" transform=\"rotate(0, 2187.81, 1541.47)\" x=\"2187.81\" y=\"1541.47\">20</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:end;\" transform=\"rotate(0, 143.279, 1464.21)\" x=\"143.279\" y=\"1464.21\">0</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:end;\" transform=\"rotate(0, 143.279, 1011.31)\" x=\"143.279\" y=\"1011.31\">50</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:end;\" transform=\"rotate(0, 143.279, 558.408)\" x=\"143.279\" y=\"558.408\">100</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:end;\" transform=\"rotate(0, 143.279, 105.505)\" x=\"143.279\" y=\"105.505\">150</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2902)\" style=\"stroke:#009af9; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 229.132,88.0053 332.221,88.0053 435.309,88.0053 538.398,1356.13 641.486,1356.13 744.575,1356.13 847.663,1356.13 950.752,1356.13 1053.84,1356.13 1156.93,1356.13 \n",
|
||||||
|
" 1260.02,1356.13 1363.11,1356.13 1466.19,1356.13 1569.28,1446.71 1672.37,1446.71 1775.46,1446.71 1878.55,1446.71 1981.64,1446.71 2084.73,1446.71 2187.81,1446.71 \n",
|
||||||
|
" 2290.9,1446.71 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polygon clip-path=\"url(#clip2900)\" points=\"\n",
|
||||||
|
"1989.93,251.724 2280.76,251.724 2280.76,130.764 1989.93,130.764 \n",
|
||||||
|
" \" fill=\"#ffffff\" fill-rule=\"evenodd\" fill-opacity=\"1\"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#000000; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 1989.93,251.724 2280.76,251.724 2280.76,130.764 1989.93,130.764 1989.93,251.724 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<polyline clip-path=\"url(#clip2900)\" style=\"stroke:#009af9; stroke-width:4; stroke-opacity:1; fill:none\" points=\"\n",
|
||||||
|
" 2013.93,191.244 2157.93,191.244 \n",
|
||||||
|
" \"/>\n",
|
||||||
|
"<g clip-path=\"url(#clip2900)\">\n",
|
||||||
|
"<text style=\"fill:#000000; fill-opacity:1; font-family:Arial,Helvetica Neue,Helvetica,sans-serif; font-size:48px; text-anchor:start;\" transform=\"rotate(0, 2181.93, 208.744)\" x=\"2181.93\" y=\"208.744\">y1</text>\n",
|
||||||
|
"</g>\n",
|
||||||
|
"</svg>\n"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"execution_count": 15,
|
||||||
|
"metadata": {},
|
||||||
|
"output_type": "execute_result"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"source": [
|
||||||
|
"plot(collect(keys(res)), collect(values(res)))\n",
|
||||||
|
"xlabel!()"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -106,15 +299,15 @@
|
|||||||
],
|
],
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"kernelspec": {
|
"kernelspec": {
|
||||||
"display_name": "Julia 1.1.1",
|
"display_name": "Julia 1.0.3",
|
||||||
"language": "julia",
|
"language": "julia",
|
||||||
"name": "julia-1.1"
|
"name": "julia-1.0"
|
||||||
},
|
},
|
||||||
"language_info": {
|
"language_info": {
|
||||||
"file_extension": ".jl",
|
"file_extension": ".jl",
|
||||||
"mimetype": "application/julia",
|
"mimetype": "application/julia",
|
||||||
"name": "julia",
|
"name": "julia",
|
||||||
"version": "1.1.1"
|
"version": "1.0.3"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
Loading…
Reference in New Issue
Block a user