Showing posts with label reward based training. Show all posts
Showing posts with label reward based training. Show all posts

Sunday, March 18, 2012

Rehabilitating a Food Thief: Part 2 - Changing the Behavior


Dogs steal for all sorts of reasons and our subject, Poppy, has probably the most understandable reason of them all for stealing food – fear of going hungry. 

Poppy (photo: dog::links)
In my last blog I made an attempt to analyse Poppy's situation so a strategy could be devised to deal with it. The trouble with any sort of stealing though – whether it be food or socks or your son’s new toy – is that the act itself often stimulates all sorts of reactions from the humans in the household and the whole situation turns into a self-reinforcing cycle. This in turn leads to the dog stealing just about anything it can in the hope of stimulating further reaction from her humans.

One way to help Poppy and other dogs like her to overcome this type of perpetual problem of stealing, is to shape a situation where the dog learns that better things come from leaving the food or item alone, than from taking it.

For this to work of course, it is most important that the dog is never punished or chastised for stealing, if this happens she will learn that she can’t trust her owners when food or that precious item is around and will therefore become more creative and cunning in her theft, only doing it when she is sure no one is looking. Dogs don’t understand the reasons why we go mad at them, they just know that their once happy human has all of a sudden become a grumpy, scary one and this causes further fear and confusion to our dogs.

If I want to show one of my dogs that I am not pleased with what he has done, I simply ignore him and his act. No fuss, no punishment, no shouting, no scolding, I just walk away and pay lots of positive attention the other dogs. This has a dual effect – it reinforces the dogs who are behaving appropriately and it shows the naughty dog that what he did awards him no reinforcement whatsoever. That is something for him to ponder.

The following is one approach to changing Poppy's behavior which can also be easily adapted to suit any number of situations. While the stages are worded in general terms, I have used Poppy’s situation to specify the examples.

Stage 1:  Be very clear about what behavior is wanted from the dog

What is it that we want Poppy to do? Depending on the way in which Poppy goes about her stealing – Does she counter surf to reach out-of-the-way items? Does she open the fridge to get at its contents (yes, I know dogs who do this)? Does she help herself off the table? Does she steal food out of the cats’ bowls or off other dogs? – there could be any number of possible options and each of these needs to be dealt with separately and specifically. For example, counter surfing is a problem in and of itself regardless of whether food is stolen or not. The desired behavior for a dog who counter surfs is for the dog to have four paws on the floor whenever she is in the kitchen. This not only resolves the counter-surfing issue but also inhibits the dog’s ability to get close enough to food on the counter to steal it. A training plan therefore, would focus on ways to positively reinforce the dog for having four on the floor and would ignore any deviation from that.

Too often dog owners and trainers focus on what it is they don’t want, after all isn’t that the behavior that needs to be stopped? The fact is that unless we can replace that undesirable behavior with something desirable, we set ourselves up in a no win situation and we may even inadvertently reinforce the behavior we don’t want simply by focusing our attention on it.

By describing a new behavior, one we can teach the dog to do when faced with the tempting situation that is cueing the unwanted behavior, we can set up a situation that will make it easy for the dog to be successful in the early stages and ultimately change the behavior over time.

There is also an element of management needed in many of these situations. An unsupervised dog can get up to all sorts of mischief simply because she does not understand what is expected of her when left alone, particularly if there is food left lying around.  In Poppy’s case it would be prudent to first manage as much of the situation as possible by making sure that all food and any other items she tends to steal are kept out of Poppy’s reach, as well as keeping an eye on her when she is in the vicinity of any prohibited item. On those occasions when she does manage to steal something, the best strategy would be to ignore it if at all possible. The less attention given to the act, the less likely it is that Poppy will do it secretly.

As to the desired behavior, it depends on what it is that Poppy’s foster mum or new owner might want, but here are a few with which I have had success when working with other dogs:
  • Always look to her owner whenever she sees food – whether on the table, on the floor, on the ground outside
  • Always keep her four paws in contact with the ground whenever she is in the kitchen or dining room
  • Go to her mat or basket when meal preparation or the meal itself is taking place, or when other animals in the house are being fed
Each behavior requires a different approach and, depending on the circumstances, all might be appropriate for Poppy. It is the first though, that I will focus on here. The added advantage of this behavior is that it incorporates an element of trust building and enables the dog’s owner to build a relationship with the dog that goes beyond just stopping the stealing of food.

The following example is one with which I have worked with one of my own dogs. Essentially I created a two-part behavior. I wanted the environmental cue – the sight or smell of food – to trigger a specific behavior from my dog. I set up a situation where it became easy for my dog to refer to me whenever he saw something that looked particularly tasty. I wanted this new chain of behavior to replace the ‘rush and grab’ one he previously displayed. The following behavior chain shows what I wanted to happen when the dog found himself facing any unattended tasty morsels.

Stage 2: Build a shaping plan to teach the dog to leave a prohibited item in favor of the desired behavior

Shaping plans are made by breaking a behavior down into its incremental elements. When I was studying with the Karen Pryor Academy I got into the habit of building my shaping plans in the form of shaping staircases. Since then I have continued to use the process to map out hundreds of different behaviors.
In Poppy’s case, we need a shaping plan that deals with very small increments of behavior and provides multiple opportunities for Poppy to get rewarded.  

The following is a plan I’ve put together especially for Poppy’s situation. It focuses only on the first behavior – that of shaping her to look to her owner whenever she is in the presence of food.

Stage 3: “Charge” the clicker

If Poppy has never been exposed to a clicker before it will be necessary to “charge” the clicker before commencing any training. This will be easy to do with Poppy because the very nature of her problem suggests she is particularly motivated by food.

Charging the clicker does not require the dog to do anything other than be relatively attentive to the handler so it is best to do it when there are few distractions around (like a litter of bouncing puppies in Poppy’s case). It simply involves letting the dog know that the “click” will earn her a treat every time she hears it. The process goes a little like this:
  1. Dog looks at you – click’n’treat
  2. Before the dog has finished chewing – click’n’treat again
  3. Repeat step 2 another 7 or 8 times in quick succession.
Over time the dog will learn that the “click” means “well done, what you just did was what I wanted” and will promise a treat of some sort (whether toy or food or game) to follow.

Stage 4: Conduct the foundation training sessions

Now things are ready to commence the first training session. I would pick a quiet time for Poppy, perhaps when the pups are taking a nap or are busy with other humans. I would prepare several sets of 10 treats and have them readily available but well out of Poppy’s sight. I’d then sit quietly with Poppy and wait for her to make eye contact with me. I’d click for that briefest of contacts and give her a treat. This is the first step of the staircase and teaches Poppy that making eye contact with me will earn her a treat. 

I like to measure duration for eye contact as it can be a good indicator of whether the dog understands what I am after. I would count the seconds Poppy holds my gaze and see if it increases in length at all. Most dogs find holding a human’s gaze disconcerting, so if I can get a couple of seconds for each glance at first, then I am doing very well. With this sort of game I like to keep the sessions short, no longer than 30 seconds, and I’d reward Poppy with a game or the remaining treats at the end of that time. I’d then keep repeating this first step until I was sure Poppy understood what this game was about – “If I look at her hard enough, she’ll “click” and feed me – how cool is that!”

Stage 5: Introduce food and work the plan

Once Poppy knows what the game is about I can then introduce a small amount of low value food to the game. I would start by holding it in my fist just in front of Poppy’s nose. Any attempt to nudge my hand or get at the food would be ignored. What I want Poppy to do is look away from my hand, just for a second, if I can capture that with the “click” then I can build on this with more repetitions and perhaps some duration (she looks away for a couple of seconds). If I practiced the first step of my process well enough, i.e. lots of sessions with lots of repetitions, then chances are high that when Poppy looks away from my food clenching hand, she will look at me - “Click’n’treat” – we’ll have jumped to the next step of the staircase. Little by little I’d work my way up the staircase, shifting the criteria minutely at first, and always going back a step or two if things don’t seem to be progressing.

The Secret to Shaping New Behavior

I’m a record keeper and I like to know how well I am doing with each session. Am I making progress in this session compared to the last? Is the dog’s interest high? Are my treats of a high enough caliber? Am I keeping the repetitions high? Are my sessions short? Are we having fun?

I’ve found whenever I try to shape a behavior I have to be very clear in my head as to what the terminal behavior looks like and I will reward any progress toward that behavior. 

I’ve played this game with many dogs and they all catch on really quickly – “ignoring the food in that hand, means I get something better from the other one – ahh, I get it, I’ve gotta look at her to let her know I know that”.

Beau, our youngest dog, is a master at this game. He uses the presence if any food as an opportunity to let me know that I “owe” him a treat by eye-balling me. The advantage of this for me is I can now trust him to leave food alone and all I have to do to maintain the behavior is reinforce him with a word of praise or something special out of my pocket. 

Poppy (Photo: dog::links)
In Poppy’s case, we really want her to defer to her owner when there is anything around that she might previously have tried to steal. To achieve this sort of reliability with the behavior will take lots of repetitions, in lots of sessions a day, over many days and weeks, but it is achievable and sets the scene for the next part of the behavior chain – teaching Poppy to leave the item that is tempting her, or giving her permission to take it. In my next blog, Cueing a New Behavior, I will discuss this part of the process in more detail.  



Thursday, January 5, 2012

High Quality Treats Make for Great Clicker Training

One of the most important factors that contribute to successful clicker training is the quality of the treats you use.

All dogs are motivated by food but some more than others. Sometimes the fear of a situation or an intensive distraction can override the effectiveness of foods you might be using for treats. Just as you might go off your food when you are feeling tense or stressful, so too will your dog.

I work with refuge and rescued dogs that have often been exposed to abusive or stressful situations. Many of these dogs are keen to please and will do anything for a little attention and a special treat in the early stages of working with them. But as work continues with the dog or if they have learned some bad habits in the past, they may become interested in other things that capture their attention and fail to respond favorably to the treats that once worked for them.  It is at this point that the quality of your reward really needs to match or surpass what it is you are asking of your dog.

Unfortunately animal products are not as well labeled as human ones and I found it hard to identify exactly what went into many of the commercial brands. Unless you are willing to give your treats the taste test, you have to rely on your dog's response to the treat in a variety of situations. In the early days of my clicker training I would try any product on the market that was labeled as tasty and nutritious - my miniature poodle always performed the taste test and spat out more treats than he swallowed. Some would work in safe situations but the majority I couldn't take on the road with him - he just wasn't interested. This caused me all sorts of problems when it came to identifying quality treats for which my dogs would work. In the end I was buying commercially prepared pure meat treats but to get 100% quality meat products is expensive.. During a single clicker training session, our Beauceron pup would gobble up 50 grams of treats. As he has five or six 15-20 minute daily training sessions – that equated to nearly three packs of commercial food a day. I needed a more economical solution.

A brain wave, and a particularly long hot summer, resulted in my harnessing the power of the sun to dry a Meaty Treats mix (see my Recipes blog for details) that I’d had quite a lot of success with in a paste form with both my dogs. Not a problem if you live in a tropical climate, but I live in Switzerland, how was I going to maintain this through the winter? I tried a couple of times drying it in the oven, but even the coolest temperature of my oven was too hot and the meat started cooking, making my apartment smell like an abattoir. The dogs loved it, but they were the only ones!

During my KPA residential at the Legacy Canine Centre in Sequim in November, I had the very great please of working with a 16 week old Icelandic sheepdog whose mum made him the yummiest dried egg treats. All the dogs we worked with at Legacy loved these – here was, at least, part of a solution. A discussion over lunch elicited Scotti’s recipe – Scotti’s Dried Egg Treats – as well as some valuable information about how I might solve the rest of my problem.

 Apparently there was a dehydrator on the market that was ideal for drying meats. A little internet research and I learned all about the Excalibur Dehydrator.  One of my KPA friends was coming to Geneva in December and she offered to bring one across for me if I could get it delivered to her place before she left (what a cool bunch of people the KPA attract!)

That was a month ago now and since then I’ve gone into full scale production: beef or lamb liver and kidney, lean beef strips, chicken breast, chicken livers, hearts and gizzards, beef heart or lamb heart – any meat that is fresh, fat free and nutritious goes into the machine. And my dogs love them all!

High quality dog treats are crucial for any sort of training, but they are of particular value for clicker training; a very small amount of a high quality treat will elicit a whole range of wonderful behaviors from your dog in a wide range of situations - even scary or intimidating ones. I have pots of treats all over the place so there is always something my dogs will work for easily at hand. Because the treats are well dried, they don’t smell (much) and they keep for weeks (though mine don’t usually last that long).

An added benefit that I hadn’t figured is that of variety. Using dried treats like this enables me to keep the anticipation active with both my dogs. They never quite know what treat they will be getting (and sometimes it is a mixture of them all) and so are much more willing to work than if they were getting the same old treat all the time.

I’m happy – my dogs are getting highly nutritious treats that motivate them to be willing recipients of all my behavior modification sessions, even those conducted by my husband. And my dogs are happy – they think they’ve got me trained to deliver tasty treats on demand just for performing a few simple behaviors on cue in distracting situations. Click!