 I was stealing this fuzzy logic machine learning tool, playing the ECG detection game. So it's working well. It's being tuned up not to make any mistakes. So I'm already laying behind. It did help not to make any assumptions about the global minimum and maximum, but just let the algorithm do its thing. So we will remove that. So just keep those to none. And then it's adjusting as it goes. So yeah, the algorithm is now so the fuzzy logic score is here. So you can compare it to your own. Oh, made one mistake. So maybe that I didn't notice when did it happen. It's probably happened in the beginning when the thresholds are not quite correct. Okay, it's happening more often now. Yes, it's not perfect. We don't want it to be perfect. You could use some more tuning. You can use more tuning. It's making some mistakes. I thought it should not make any mistakes. It's still much better than than myself. Yeah, so it's it's becoming faster every 50 points that you score. You can go play with it. I don't know where the false the three false alarms came from. That will require some investigation in the code. Okay, so I'm kind of giving up. It's gonna win anyway. The machine is gonna definitely take over tasks like this where you have to blankly look at the time series data on the screen and label it. And same goes for this is an example for ECG. Same goes about EEG that we will do something similar as well with seizure seizure, epileptic seizure detection, which is much should be much harder than this one. To make this one harder, we could introduce some noise to the waveform. And then yes, we expect the robot to make more mistakes as well. It's all normal. So I don't know where these three false alarms came from. I hope it was just in the beginning, the theories. Oops, I missed that one. In the beginning, the thresholds. Would not be set. So the minimum maximum changing as you get more data coming through. So for example, if all of a sudden you had a larger ECG complex, then it has to readjust it's threshold. And yes, while readjusting it might make some mistakes. That's the theory. It's already got like double, almost double the score of what I have. So good luck to us all. Just quickly go over the code. Yeah, with normalizing the array, it was generated at 300 DC, 300 baseline. I don't know why. To double check. And obviously it doesn't care how the speed on the screen depends on the human score. So if you go to that, it will become faster and faster. I mean, the board doesn't really care. It's making the decision immediately. And now it will become even faster as I score higher. Okay, so that's the code. So it's a fuzzy, fuzzy logic system. Yeah, we need to update this description at the bottom, which we might get a GPT to do. And I don't know if I just go. So it has all the code in here. I don't know if I made some changes to it, but it shouldn't conceptually, it's all the same. So the description at the bottom should be the same. And a couple of things in the HTML code, there is a description at the bottom of the page. We need to rewrite it. The original description was for the ECG waveform game, but this one including a robot algorithm playing the same game. So you can compare the score. Anyway, you should have all the code. Any chance you can rewrite that description at the bottom of the page updated. Yep, I turned that off, see what it says. People don't like the robot voices generating. Still calling it the waveform analysis challenge. Interactive game, waveform scroll, unique learning opportunity, whatever. Okay, this is not, are you mentioning the fuzzy logic? I don't think so. Mentioning it once. The challenge was providing a learning opportunity by comparing your scores with robot analysis. Okay, that sounds legit. Complexity is the ECG interpretation. The robot needs to get fuzzy logical rounds. Not very sophisticated, but okay. Offering high tech benchmark for your assessment. Okay, can you rewrite in a less sensational manner also include an actual separate paragraph of explanation of how the fuzzy logic algorithm is working and how that decision is being made. Maybe something on the fact that the two codes are separated, that the waveform generation is happening in JavaScript, whereas the fuzzy logic is working in Python. So the robot is not, doesn't have any extra information. Specifically doesn't have any labels of the generated waveforms. Yep, yep. Yep, yep, yep. Doesn't work. Situ with analysis, interacts with skill, blah, blah, blah. Yeah, we have the game rules. I assume that's the fuzzy logic description. In the JavaScript, we still haven't added an option to add noise to the signal. Hey, can we do it now? We would like a controller slider on the front page with just the minimal noise as default and going up to the maximum amplitude of the signal. Just the random white noise would be okay. Which parts of the code do I need to change? Or do you prefer providing prompts for me to use in a GitHub co-pilot? Yep, sometimes the yep even works. So it still has access to the early code. I still have access to the code you provided earlier. To add noise to the ECG signal in your JavaScript code and introduce a slider on the front page to control the noise level, you need to modify both the JavaScript that generates the waveforms and the HTML for the user interface. Yeah, we need obviously modified the HTML. We need some sort of slider. I don't know where we'll place it. Figure it out in a sec. Add a slider to your HTML page to control the noise level. Place this within the body of your HTML, possibly near the canvas where the ECG waveforms are displayed. There's the canvas. There is a canvas. Crazy weather. Probably electricity will go out or something. Okay, so I have a slider. Maximum one. No, it shouldn't be one. Steps of point one. And the default is this default. Should be say point one. Just to make it more interesting. Let's see where the cluster is placed. Yeah, ideally not. Turn the cluster to be horizontal. From the horizontal cluster. Assume that's correct. We'll just test it in a sec. Okay, now it's Gonski to see it. Where is it? Yeah, there's a crazy thunderstorm. It meant vertical, not horizontal. That's why I said rotating instead of just setting it a keyed up co-pilot. Just leave it as is. Just a conceptual, isn't it? This slider ranges from oh, no noise, to one, maximum noise. What is that point one? Adjust the max attribute as per the maximum amplitude of your signal. Yes, that will be like 300 or something. Let's make it one, like 100 steps of one. Let's start with five or whatever. That should be fine. Can just create a function called add noise. I don't know, in the waveform JS. What did it suggest? No surprise. Generating random noise at a certain level. Existing waveform generation logic. They can get a co-pilot to this. So that's how we make the whole function. Can you fix add noise function? Those are rubbish. Yeah, the T is... Yeah, that actually makes more sense. It's definitely better than what we have. Yeah, we're adding random noise at that noise level. Then have generate the f-full waveform with noise. It's probably the same. We really have that line. Why do we have it six times? I don't know. Okay, this is not good because this is generating a separate waveform. Instead of, okay, instead of this function, instead of this function, can we have the option to add noise to any of the existing waveforms? How do we change the code to do that? We'll ask a co-pilot as well, which is highlight the whole thing before. It's actually, well, that's similar because we probably already have that in the code. Yeah, we have a 6040. I think this means we have a 6040 ratio between a normal and abnormal. That should be okay. We've had an optional noise level parameter after generating the waveform. It adds noise to the waveform using add noise function. Okay, so add noise function is the same, is it? And we have generate a form. Why those sometimes? Please show those more clickable. In the past, stuff should be all the same or not. Let's just see which one works. Which one out of co-pilot or HHGPT should work? The noise level there is zero. Let's put it at point one, just to test to work. No, it does work. If we commit it five, let's make it 10. Yeah, some noise level works back. The fuzzy logical rhythm too. Do not perform well anymore. This noise is not quite realistic. Oh, it's really loud, I understand. Better run and hide, change the game logic. The game logic doesn't currently include the noise slider. One slider and JavaScript. We have all these get elements by ID, it's one for the canvas.