My name is Craig Daniels
I am a graduate student in Mathematics in Portland State University and a T.A. for this course
This is an answer to intermediate problem one from unit five
What we want to do is to create some sliders to replace some of the global
variables that have been set
so, if we click on "code" and the go to "find" -this is our "Mac" (Macintosh)
I wanna start looking for code that has "wall-penalty" so, type that in
so we go through there where we have some global variables
we can see we also set it and..
then there's some code that uses it, this is down at the bottom of the screen
and more code that uses it, so browsing the code here we come back to the global setup
so, we need to comment it out in two places, do that here
there's a semi-colon for it -comment,
and I'm gonna -kinda, paste it so that, so that it's still
there if I wanted to get to it later
take it out there and then also, we are going to set it with the slider
this is so it'll be easier to comment out
now, we remove the setup and the declaration of the global
and now we need to make a slider to replace it
so we take a slider, and let's say, here..
and then..
we're replacing "wall-penalty"
and I think we start with the value "five" because it's what
the program has used
so now we got that; now..
we'll just check and see if the code would run
because it always a great thing to do after each change
-that I..
I'll take out a few updates so it goes faster
there! it's running!
so, now we're gonna stop;
here's the "Halt"
let's go ahead and do all that together now
now we're going to do a "Find" again
with like "command" + "F"
let's do "can-reward"
alright, now we're also gonna do a number of runs for fitness and
and number of actions per environment
so..
we can actually find at this point now that
we can comment all this stuff out without having to search through again
I'm gonna clean that up a little bit
and here are the other.. two..
so these are five things now
Great! it should tell us that we got some problems
which is fine -we know that;
we're gonna go ahead and create the rest of the sliders
alright, this one is going to be for "can-reward"
and -I guess, I'll make them all five for starting..
this isn't the prettiest or the nicest place to put all these things..
alright..
now we're gonna add slider fitness, we're gonna do that next..
and finally, "number of actions per environment"
OK..
At this point..
Ok, so what happened there?
so we made a mistake then!
I think I pre-word
many of you probably have noticed that while I was working on it!
alright!
now, let's see..
we've got everything I see in our build you can see the slider, you can now..
set them to whatever you would like
so I'll set it up!
still running past her
go in generation
and it seems to be working
so, at this point you can experiment with that
and you can also
move the items in the
interface around a little bit so it looks prettier..