All right, I've got this pipe here Lined up right where I want it. It's the top of that. No the bottom edge of that pipe It's four feet feet up from the deck here and the same back there and four feet because I have imperial noodle unit measuring device at the moment That was messy but Got all those trimmed off so Now all four of these posts should be the same height The height that I want the roof to be right. That's about where those go. All those goes out here And I'm just remembering All right grinder all clean fiberglass so messy All right, I've got a rivet in place No turning back now this piece and that one I riveted into the thing That's just sitting there right now. I think the next thing I want to put is one of those Across here is there'll be one right here. I'll sit on top of this and go to that one over there Because these are Are in more than those ones those ones are wide enough that I can rivet this right to it But these ones there's gonna be a gap But if I'm gonna start attaching these I need to get You know finish getting the ends of all these the same This one looks good this one I obviously haven't trimmed yet One riveted in here all locked in place and then I did one down there and I measured it against this one to make sure everything was the right width and That one is just resting on top of these pillars right now Which isn't gonna be sufficient. I'm gonna have to have something from here Maybe diagonally down or something to reinforce it so people can actually stand on it I mean it might be alright the way it is but Regardless, it's in the right position and I think I might want to get all these in place Maybe Thing is I Don't want these to start sagging too much. No, I want to put them. I don't know Okay, if I put all these in place, it's gonna put a bunch of weight on this and it might make it start sagging a bunch Yeah, I guess I should just mark where they all go and Then think about what I want to do to you know make supports down to the boat I'm thinking another one of these pipes Running along the the roof of this part with a bit of zigzaggy or something and Then back here. I don't know. I'll be able to do a thing here but then I don't know. Maybe I might have to put an extra. Well, I Have a pretty good idea what I want to do here. So let me do that first And this sheet metal is gonna come right up to the end of here But I left a little space between here and this piece So the sheet metal will overhang a little bit just in case I want to attach something here to block rain It'll be able to go tuck up under the sheet metal Be better for waterproofing 36 32 Yeah 33 36 and 33. I don't know that I'd call these the most spectacular connections I've ever made however Totally good enough. Those are plenty strong. Oh, what do you guys think of that? Pretty good. Hey, yeah Not sure what I'll do back there yet, but oh man. Those are looking great And I feel like I need to slow down for a second. I just need to take a breath and Chill out for a minute. I've been I've been just going full speed for the last week And it's great. I'm making tons of progress. This is excellent, but I think I need to like take a breath Eat some food And like just just chill out for I don't know 10 or 15 minutes and then I can put all these these things up. Yeah You know when you get in that mode where you're just going and going and going and it's almost like you're sort of in a panic But not really a panic because it's very directed and you you're making all kinds of progress But like sometimes you just got to like slow down and say, okay. I just got it. It's got to chill out for a minute So yeah, I got chill out for a minute and make some food Oh, there's also another thing I was meaning to mention on one of these videos So I split my channel into two Two channels right Jamie builds and Jamie talks. So this is Jamie builds because I'm building stuff But then there's Jamie talks and from now on I'm doing all the Sunday lives on Jamie talks Because they're talking videos However to do them I need to get a thousand subscribers on that channel So if anyone wants to you know still watch those Go subscribe to Jamie talks. It's the there's a link down here to it But don't don't go over there If you don't want to hear me talking because I don't I don't need that Only if you want to hear me talking, you know But I did just start the channel so it doesn't have a thousand subscribers yet Although it's gone up a lot in the last week. Anyway, okay I'm gonna I'm gonna actually eat lunch today and try to try to relax a little bit And then in the afternoon get back to work. Oh Food coma, oh Nope, oh, let's power up a little bit Okay, that's a good level. Let's get some stuff Awesome, oh Let's get a shot to the milk. Oh look at all those. Oh man. That looks so nice. Oh, so good Is that gonna be awesome or what?


Thanks. Okay, let's start. My name is Florian Fuchs and this talk is about Maiman 3 and Django. I don't know if you have noticed that Maiman is, you know, only, you know, minutes or seconds, just a few moments before a new version change to version 3. So this talk is specifically about Maiman 3. Some quick words about me. I live and work as a freelance web developer in Berlin. I do a lot of work with Python and Django, but also quite a bit of work with front-end technologies. I also do some open source work. I'm on the Maiman 3 dev team, which I joined a couple of years ago. And as he said, I mostly work on things that have to do with the web UI for the list management and the rest of the API. Okay. So, what is this talk about? Well, Maiman 3 has junior web UIs for list management and archiving. List management meaning creating lists, subscribing people to them, archiving meaning making messages that get sent through the system, searchable and browsable. And we decided to use Django for both of them. So I'd like to show you how you can use and integrate those Django apps that we have built and how you can use Maiman 3's internal APIs to write your own Maiman-related applications in Django. So quick warning, this Maiman 3 is still in beta state, but as I said, we're not far away from a full release. Okay. Quick overview over the architecture of Maiman 3 from the view of a web developer. Well, I have to tell, when I joined the Maiman team a couple of years ago, to start working on a web interface for version 3, the development of version 3 was already well underway, so most of the code was there. And when I started, I had absolutely no idea what Maiman did internally. And the good thing was I didn't have to know that because in Maiman 3 there are some very clearly defined APIs that you can use as a web developer to write any kind of interfaces you like. So let's see what the actual components are. There's some mod-stone component that we call the Maiman core. It's the actual Maiman-Python package that gets imported when you start Maiman. And well, it retrieves emails from list members or people sending emails to mailing lists and it distributes them to the list members. Of course, it does a lot of other things internally and it's a really extensive piece of software. But right now, we don't need to know too much about what it does. Okay. For list management, Maiman 3 has a REST API that you can use. It's JSON-based and it's local. It's a local API, so it's language agnostic and it's not intended to be used over a public network, but it speaks HTTP, which is pretty nice. We also have some Python bindings. There's a library called Maiman Client, which I will tell you something more later. And it turns all these HTTP calls to the REST API into nice Python objects that you can operate on. So this REST API can be used to manage lists, meaning creating lists, subscribing, unsubscribing, moderating messages, changing preferences, and so on. The other internal API that is provided by the Maiman Core is the IRCyber interface. And this is a Python API. It's based on Zope interface. I don't know if you're familiar with Zope interface or interfaces in general. And it's, well, it sounds worse than it is. Pretty easy to use. It's a Python API that gives you access to every list post that leaves Maiman. So if someone sends a message to a mailing list and the message gets through so it's not moderated, it's the person is legitimate sender to that emailist, this API will give you access to a copy of that email that gets sent out to all the list members. We have two Django applications that can be installed that use Maiman 3. One is called Posterious. This is the app we use for list management. The funny name has, well, it's a mixture of the fact that many people use jazz music references for their, when they name their Django apps, it also has to do with email and dead bass guitar players. And what's worth noting about Posterious is that it has been created in large parts by students who have been participated in the Google Summer of Code, which is a really nice program that Maiman has been participating in as a sub-org of the Python Software Foundation. And there have been a number of students during the last years who have implemented features for Posterious, which is so kudos to all the students. And actually one of those students has given a Django account talk at DjangoCon Europe about Formsets because she used Formsets, Django Formsets in her Posterious project. So if you don't know about Formsets, you should totally check it out. The other Django application that's there to use with Maiman is called Hyperkitty. And this is the new mailing list archiver. It has been created by a couple of people at Fedora who've done amazing work, looks really nice, has a really nice UI, has some built-in statistics, so you can see which email lists get the most attention, the threads are displayed very nicely, and also you can post to mailing this directly from the archiver interface, which is great because some people just don't like to use the email clients all the time, so that's nice. So let me show you some really random screens of the two interfaces. This is the Posterious list annex page. Well, I created some dummy lists today. A page to edit your subscription preferences, whether you like to have, to get daily delivery as a digest or immediate delivery, stuff like that. So these are very random screens. This is the archive index for Hyperkitty. As you can see, you have nice little graphs that show you the activity index of those lists. This is an overview of all the threads of a certain list. By the way, these screens are taken from a demo that the Fedora people have set up to test their Hyperkitty development, so if you want to check it out further, you have to Google Fedora and Hyperkitty and demo. So how can you install and integrate those applications? Well, there's one installer to get them all. It's the Mailman Bundler. It lives on Launchpad. You can download this project and if you install it, it will download Mailman, Posterious, and Hyperkitty with all their dependencies and will install it on your system. And it will make it pretty easy to hook it up to your local mail server and to your web server. This package also provides a separate Django project for which holds Posterious and Hyperkitty with all the settings they need. So you might say, well, I already have a Django site that I'm running on my server and I don't want to put up another Django project, so can I just please just integrate Posterious and Hyperkitty? Of course you can. Both live on PIP, Mailman 2, of course, and you can just install them plus some settings that you have to add to your existing settings file. Depending on whether you want to install both of them or only one of them, you can check out these two example projects to check out the necessary settings that you have to add. So other than that, they're behaving just like pretty much every other reusable Django apps that you can just put into your installed app setting and you're good to go. So one of the more interesting parts is how you can write your own Mailman apps, how can you actually use those APIs that I was talking about for list management and archiving. So say you have your existing Django site and now you have installed Mailman and it's running pretty smoothly and you have used Posterious maybe to set up your lists or you could use Hyperkitty, but on your site you want to have maybe a single view which you can edit yourself which holds a subscription form for a certain list. How would you be able to do that? Well, maybe remember I was talking about Mailman Client, the Python Bindings library that does all the HTTP calls for you. First thing you have to do of course is install it. You can find it on the cheese shop as well. And then the next thing you do is you import the Client class from the Mailman Client package. By the way, this is not a typo. The project is called Mailman.Client but the package is called Mailman Client because it doesn't sit in the Mailman namespace. So you create an instance of that Client class by providing it with a local REST API URL and a username and a password. These are the default values and you can change them in your global Mailman config file if you want to. You should do, of course. So the first thing you do when you start with the clean slate is create a domain. Mailman can operate a number of domains just like many machines serve different domains for websites. Mailman can serve different domains as well. So you add your own domain, I call it mydomain.org, and it will return a domain object that you can operate on further. This domain object, for example, has a createList method that you can use to create two lists. Well, by the way, maybe you've noticed I've put some small comments below each of these statements to indicate the URLs that are actually called when you execute those statements. So once you've created your lists, those lists show up in the client's list property. So you can see what's there. If you want to operate on a single list, you can get the list object from the client's getList method. And you can use that list object to subscribe and unsubscribe people from that list. You can also provide it with an optional username, which Mailman might or might not use when sending out messages. And once you have subscribed someone, this person, this member will show up in the list object's member's property. So this is just a very simple example, but the principle is Mailman client gives you objects with methods that might return other objects that you can operate on. And this is just the most basic use case to create lists and subscribe people to it. You can also moderate messages, change list preferences, and so on. So the documentation sits in a REST file, an RST file in the Mailman client package. I don't think it's on Python hosted or read the docs. I have to change that. So how would you use that in a Django view? Well, there are obviously many ways to do it. I chose one example that fit on a single page. It's a very simple class-based view. It has a get method and a post method. And it has a separate property method that returns the client instance. So we don't repeat ourselves. Well, if we take a look at the get method, the first thing that happens, the list object is retrieved through REST from the client, from Mailman client, from Mailman client, and then there's an imaginary subscription form, which probably holds just an email address depending on what your needs are. And so the list description and the form are provided to the request context. So if someone actually posts, submits this subscription form, the form is instantiated with the request post data, which should be uppercase, not lowcase. And if the form is valid, the person who submitted the form is subscribed as a list member, and then you just usually redirect to whatever your target page is. So as I said, this is just a very basic example. You should also use a simple view function, or if you have several Mailman views, you might maybe put the client instantiation method, which sits in the client property here in a utility function. So yeah, this is just one example. Okay, now what we have done is we have, say, you have installed Mailman and the web UIs, and now you have created your own page with your own Mailman functionality. And you say, well, I'm still not happy. I have one list, which is a little bit different than all my other mailing lists that I'm hosting. And it's a private list. It shouldn't go into a public archiver or any usual traditional archiver as well. And say it's a support list and the list members are the support staff of your organization. And you want to get a copy of each message that gets sent to this list and processes in a different way. You want to store it into your Django database to display it in Django admin or whatever. So in order to do that, you would be able to use the iarchiver interface. So this is a very simple example how to use the iarchiver interface. This is, as I said, the Python interface. Basically what you have to do is create a class that implements three methods and has one name property. The first method is the list URL method, which should return a URL where your list summary page can be found. It's just something that Mailman puts into the email header. It has another method that you must implement, which is the permalink method. It doesn't have to return anything. If you want to, you can return a separate URL for each method that you can calculate. But you can also return none, but you still have to implement that method. And the really interesting stuff sits in the archive message method. There you have access to Mailman's internal mailing list object, that this message is sent to, and a message object, which is cast to a string, but also has get methods to access the message headers. The way for the Mailman core to know that you have correctly implemented your archive class is it uses Zope interface. You've probably noticed the implemented decorator on top of the class. Well, it basically says, Mailman, okay, this is a class that implements the iarchiver interface. And before you run it, you can check if everything's there that's needed. So that's the one thing you have to do when creating an iarchiver class with a custom archive. The second thing you have to do is, of course, you have to tell Mailman about it. So there's your central Mailman config file. All you have to do is add a section which starts with the iarchiver and a dot, and then the name of your iarchiver. It has a class property, and this is the Python path to your iarchiver implementation. And then, of course, we have to enable it. And if you want to, you can add some configuration for your custom archive. So if you have some extra configuration that this archive class might use, you can put it there. So again, how would you use that in a Django context? You might think, well, that sounds good. I can just import my models. And this example is an imaginary MyListPostModel. And if you would import it at the top of the file, it would raise an improperly configured error. Because when Mailman imports this module in this class, you're outside of your usual Django environment. So there's no whiskey app instance, and the settings are unknown. So what you have to do is you have to set up your Django environment by setting the Django settings module environment variable. And of course, you shouldn't probably hard code it. But otherwise, it wouldn't have fit onto the page if I wouldn't have put it like that. And then after you've done that, you can import your Django model and save whatever information you might want to read from the message file. And the message property that is handed to the archive message method. It has a string representation, which is the complete message source. And you can use pythons, build an email passage to iterate over each line. So you get the raw email body and the subject and the date. So whatever you information you want to read from that, you probably want to use the email package for that. Okay. So as with many open source projects, you're welcome to contribute. We are a small group of people that are very enthusiastic, but also have, like also with many other open source projects, there's a lot of time that we'd like to work on it. Also, since we are just, you know, short before the new major release of Maman version 3, it would be nice to have more bug reports. So if you got interested, subscribe to Maman developers at python.org, which ironically runs on Maman 2. We also have an IRC channel on Free Note.net. You can check out a wiki. A lot of the documentation is there. And if you have specific questions for me on my IRC handlers for an effort, I also hang out on Maman, on the Maman channel. So thank you very much.


Hello and welcome to the session. Let us discuss the following question. It says constructed triangle A, B, C in which B, C is 7 cm, triangle A is 60 degrees and altitude through A is 3.7 cm. How many such triangles are possible? So let's now move on to the solution. We'll do the construction and we'll write the steps of constructions. Step is to draw a line segment B, C which has length 7 cm. So this is the line segment B, C and it has length 7 cm. Now the second step is draw equal to 60 degrees. This is the angle C, B, X which is of 60 degrees. Now the third step is draw YBX equal to 90 degrees. So we have drawn the angle YBX which is of 90 degrees. Now the fourth step is draw the perpendicular bisector B, C such that it's BY the point of bisection on B, C. This is the perpendicular bisector of the line segment B, C and it intersects BY at O and D is the point of bisection on B, C. Now the next step is with O as center draw a circle. So we have drawn a circle with center O and OBS radius. Now the next step is from D, mark a point P at a distance 3.7 cm. D we have marked a point P on MN so that this distance is 3.7 cm since we want to have altitude to be 3.7 cm. So we have taken this point such that it is 3.7 cm. Now the next step is draw AA dash through P such that AA dash is parallel to BC where D dash point of intersection with the circle. We have drawn a line segment through P is join AB, AC, A dash B, A dash C. So we have joined AB, AC, A dash B and A dash C. So the required triangles are ABC and A dash BC. ABC, A dash BC are the required triangles. Thus such triangles are possible. So this completes the question and the session. Bye for now. Take care. Have a good day.


This study investigates the effectiveness of a 3D printed degradable polymeric implant with cellular structure for the treatment of segmental bone defects. The implant was coated with hydroxyapatite and inserted into a sheep tibia. After one week, it was found that the implant had been completely filled with newly formed bone tissue. By the third week, the bone tissue had grown from both the proximal and distal fragments of the defect. These results suggest that the implant may be effective for the treatment of segmental bone defects.


City apartments are rough. My first two places were both basements because that's what you can afford these days if you're looking to live alone. Third place, no lie, had a window facing a brick wall only three feet away. I was never looking for a spectacular view. I just wanted a decent window. Until last month, when I got one, I moved in December 1st to this super small but super decent apartment, only a few minute walk from the subway. The main living space extended from the kitchen and a flimsy sliding door separated that from a small bedroom space and the east wall of that bedroom space, a floor to ceiling window.  I'll make a note here that I've never been much of a horror movie person just never caught my interest. So when I couldn't find any bug reports on the building, it just seemed like a lucky break.  I started with the Wi-Fi and living space so I could work to some tunes, then unbox some stuff from the kitchen. As I was sliding some plates into my cupboard, a knock came at my door. Shit, maybe my music was too loud. Standing on the other side of the door was a small woman wearing a hijab. I smiled apologetically. Sorry, is the music too loud? No, no, it's fine. The walls here are good. She assured me. I wanted to say hello. Welcome you to the building. Oh, I replied. I hadn't expected such a warm reception, I thought. I'd never been greeted by a neighbor in any of my previous places. Well, thank you so much. I'm Lewis. She shook my hand. I'm Kibla. Nice to meet you. She peered into my apartment. This looks good. Do you need curtains? I can give you some. I have extra. Thanks, but I'll get around to it. I'm excited to get some December sunlight coming through. I said with a laugh. She didn't laugh. It is no problem. They are lovely curtains, and you need your privacy. She said. I chuckled, feeling some tension in the air. I'll make sure to get some curtains up soon. In the meantime, I'll hide all this. I gestured to my lackluster physique under wraps. Again, no reaction from my neighbor. A moment later, she forced a small laugh, then nodded. If you need anything, I'm down the hall, 1710. She nodded once more before turning away and retreating down the hall. I waved as I watched her go. Nice lady. A little odd though, which brings us to my first night. Dark hit hard and fast, but there were a couple of yellowed street lights bathing the street in parking lot outside the closed coffee shop and the man that was yelling. It started just as I was laying down on my bed, a senseless hollering strings of profanity mixed with accusations at no one. But I'm not new to the city.  So above all else, I knew to be patient. Maybe this was why the place costs so little. It would have to be pretty extreme for that much of a price decrease. This set me on edge. After about an hour of the noise ebbing and flowing, I brought myself up and out of bed into the window. I looked out over the cold street and watched the snow get caught up in gusts and brought to the man. He walked in jerky circles, flailing his limbs from time to time. I touched the cold glass. At that moment, he spun around and faced me as if he could hear that barest touch. He froze, no more noise, no more circles. He just stared back up at me. He couldn't have been staring at me. I was standing in a dark room, alone, 17 stories up. But from everything I could tell, he was standing in that parking lot, leaning at the slightest angle, head cocked right up at me. This wasn't good. I took a step backwards, still watching him. The moment I moved, he broke into a dead sprint. He was running directly at me. My heart leapt. But I was inside. There were many locked doors between myself and him. It was fine. That didn't stop me from running to my apartment door and triple checking it was indeed still locked and then watching my apartment door from my kitchen table, then watching the street from my window to see if I could see him again, then the kitchen, then the window. It wasn't a great night. The next morning as I opened the door, it pushed against something. I full panicked for a moment, but immediately realized it was a bundled up window curtain with a note. The note read, For the nights they aren't people. They are cold, signed Kibla. This was unsettling for sure, but also on a different level, incredibly insulting. Was she talking about the community housing folk? They were sick, not not people. I let my indignant side overpower my anxiousness over all this and tossed the curtain inside and continued on my way. I got a doughnut and some bad brew at the coffee shop, found out that they operate from nine to five, which is an ideal for late night cravings, and headed off to work. Night two was much quieter. I didn't hear a sound above the passing night traffic as I laid down to sleep. This felt much more comforting. And then it wasn't. It was too damn quiet. There were other people in this building. There was the community housing just across the street. Why was it so quiet? I stood up again and wandered to the window. Nothing out of note there. No folks wandering the street. Only difference from the night before was one streetlight had started flickering. Maybe I was just getting in my head over all this. Then I saw the group on the balcony. Five people stood on a balcony of the community housing building, about five stories higher than myself. I couldn't entirely tell if they were speaking or anything from this far. But one thing was for sure. Each stood facing out, facing me, staring at me.  I stomped through my house, hoping the sound of my own movement would help me establish some sort of connection to reason. I was imagining things. I was getting worked up over nothing. But if the curtain would help me feel better, easy as that, let's get it up. I got back to my room just in time to see them jump. In unison, each of the five people on the balcony easily climbed over the rail and stepped off, still staring directly at me through my window. I dropped the curtain in terror and shouted a meaningless stop. I scrambled to find my phone and dialed 911 while I made a mad dash out of my apartment and into the elevator. Police and ambulance were on the way. As the elevator rang at ground floor, I ran out of my building and into the cold.  The biting night stung at my skin all over, seeing as I'd left wearing only my PJs and slippers. I ran across the quiet road and passed the shop to the building, dreading what I was going to see. They stood there. That's all. There were the five figures I'd seen only moments ago, plummeting from over 20 stories, stiffly but casually looking at me with blank eyes. Nothing seemed to be wrong with them physically. I saw no signs of injury. But behind those eyes, I couldn't tell what I was seeing. I walked closer to the building, scanning the area to see if I was wrong. If it was a different group of people, but only came back to them as sirens began blaring. They walked back inside. My mind was a mess. I felt like I was going crazy as the police talked with me.  The sirens retreated back into the city. I slammed my fist against Kibla's door the next day. It opened only a few inches, revealing a chain lock in her eyes.  I asked. You didn't put up the curtain. She said, as if this was some normal irritation.  I demanded. They can see well in the dark. They've noticed you. They won't hurt you, but they'll want to be close. She said as calmly as always. What do those people want? They aren't people and they want to be warm. I sputtered, wordless. How do you respond to that? Put the curtain up. It might not stop it anymore, but it'll give you peace of mind. Was all she said before closing her door again. So I did. I put up the curtain and started looking for another apartment. I didn't know what was going on, but I could stay here the two necessary months and head out without messing up my finances too bad.  But there was no way I was getting to sleep. The past two days were running through my head on an endless loop. What was happening in that building with those people? They were people, right? A quiet noise caught my attention. Barely a noise, really, like the sound of a mouse squeaking in the wall. It would be nice to have normal issues like mice. The same sound, but slightly louder. I curled up in my bed. I didn't want to deal with anything tonight, but I also knew no sleep was coming if I didn't deal with whatever was causing this sound. I slumped out of bed and listened closely, tilting my head towards the wall. Silence. Maybe I should just attempt to sleep through it. A singular clicking noise, like hail falling against glass. There was a chance I was just hearing something coming from outside, and I was fine. Or far from fine. I remembered my neighbor's words. They won't hurt you. I shuffled towards the window. They want to be warm. I pulled the curtain aside. Darkness. No streetlight. No snow. Nothing. Just the same darkness as my room. I furrowed my brow, absolutely lost. I hit the switch on my lamp. Naked bodies stuck to the glass from the outside. Awfully contorted and piled bodies, all trying to touch as much of their flesh as possible to the glass dividing us. Their skin folded and flattened in still life before me with patches of hair and scars and disease. The various faces clouded the window with their heavy breath. Tongues and teeth pressed hard, almost like a suckerfish plastered and frozen in ecstasy. No, not suckerfish. More like maws.  I huddled into a fetal position, rolled away from the site before me, and I can only describe it as I lost my mind. I don't remember much until dawn came and I saw light piercing through my unmarred window. I left that day. I went to a friend's place and I stayed on their couch. My friends and a couple cousins I have here in the city had to get my belongings. They all think that I just had some sort of random psychological meltdown. It took me this long to get to the point where I'm even considering leaving this house and going back to work. I'm going to live with friends for a while, and if I do someday get a place again, I am fine with basements.


a bite stick That's not that bad. I thought I smelled like garlic. This is actually like that You guys know what net bait? Oh, yeah What's going on guys? Welcome to another video. Thank you guys so much for the support first of all Hope you guys are killing it here in 2018 working hard, you know grinding every single day, you know how I preach that so much today I'm gonna be doing something a little different kind of going back to you know the original Stuff that I use to film you guys know I used to film a lot of vlogs a lot of Documenting videos where I just go throughout the day and film what I'm doing and today I've already got a lot done But I do have a few things that I have to do today So I was like, you know what? I'm a blog because I haven't logged in quite a long time and you guys seem to love them So if you guys want to see more bull if you guys want to see more vlogs Be sure to smash that like button and comment below and let me know first thing I do need to do right now is actually go grab some gas I'm about to run out So I'm gonna grab some gas and I have to go running grab a few rods and reels I am wanting to take some pictures for some content, but I might go fishing as well just depending on what all happens I tried to film some Cannot get any bites this cold front recently has just messed the fish up these fish are all Jacked up recently and it sucks just before like a few weeks ago the fish were fighting really well You know we were catching some big fish some giant fish and now it's just completely dead Oh gas stuff. Oh my god. You guys just missed the funniest thing ever. It's probably like very loud I like clapped my hand. I like gas stuff and it's like dude is just there was he talking about my phone I'm using my phone to vlog.  I actually got I got what did I get? I got a concept Z concept a on a defy and a chrome and then I also have my inception on a defy as well So we got the rods I'm actually gonna be meeting Alan, which is someone who's new on the fishing team and We're gonna be going fishing where you go hit up a pond right now.  Why are you beeping at me? I'm also gonna take some pictures as well content for Instagram I'm gonna document the whole thing got the GoPro with me and hopefully we'll catch some fish Like I said, it's just been crazy, but we're gonna we're gonna be having us alright guys Just got to the pond right over here never been here before we're gonna try to catch some fish I was trying to find my way over here. It's like taking me in the neighborhood and stuff I've never been over here, so I'm excited. See if we can catch some fish Let's go ahead and give it a try Hey, what's up brother? How you been? Good. Good. That's good. Where are you from? Really? Oh dang do the sick That's cool. What did uh, how's your classes? How big was the fish that you caught here? Yeah You can cast it if you want this thing be this thing's crazy It casts it far. You're left-handed aren't you? You still try to cast it It's crazy, ain't it? He just barely whipped it So guys just got done fishing this pond right here nothing nothing again nothing again Alan did say I don't know why I just put my keys in the back See Alan did say that there's some people here before and they caught you know fish a few fish before we got here So if there is a few people, you know walking around I talked to three more people and they haven't caught any But it just seems like a busy area. I've never been here. It's a cool pond It's different, but you know just didn't get any bites. All right guys. You just got home fishing was crappy I don't get it why it's been so bad lately. It's just been absolutely horrible.  It's just like a light switch and shuts off So I have a few boxes that I want to open right now and show you guys what's inside Now I want to show you something that's gonna be coming soon to the videos because I think it's really important It's gonna be really cool. It's gonna make the quality very nice. All right guys Here's the box. I'm gonna open first just get this in the mail I'm sure you guys what it is It's a lucky tackle box packaging and everything. It's a red lucky tackle box. I'm actually here. Let's let's see What's inside of it? I'm gonna go ahead and show you guys inside this box No need to make another separate video over this show you guys now This is first look guys. I haven't even I haven't even seen what's inside yet So as always a Little booklet stickers whole deal What is that? It's like a crop frog That is weird. I've never seen anything like that Literally like a prop frog It's like a whopper plopper, but the tail of the It's not even a frog. It's called a prop fish. That is weird I'm definitely gonna take that out.   I'm about to open this up I've seen nothing like it. I don't know what that is right there. I've never seen a bait It's kind of like I'm assuming it's kind of like a net rig. That is interesting This box is It's filled with some crazy stuff that I haven't seen before. That's pretty cool something different, you know fish really finicky fish really been nice Got some swim baits my bash crusher yet some old must-have hooks some tiger bomb and And lastly you got a Bite stick That's not that bad. I thought I smelled like garlic. This is actually like that You guys know what net bait? Oh Yeah, that's not actually smells kind of good.  That's what that smells like That's kind of like the net bait net bait. Uh, that's everything in there I want to show you guys one more thing before we close out this video Alrighty guys As you guys can tell you guys probably know what this is. This is actually the first if you guys know anything about DJI They make drones. They make gimbals. They make all sorts of stuff. If you guys know the iPhone gimbal that have It's actually made by them This is actually the first drone they ever made so this is the Phantom one and I've had it for years Me and my mom actually got it for my dad for Christmas He does not use it so I brought it down with me down to Savannah We're gonna be learning how to fly it hopefully here soon and he quips some cool drone footage in the video As you can tell I got a brand new GoPro 4 right in there If you guys wonder why I use the GoPro 4's just because I have a lot of batteries And I don't have too many problems with the 4's. I think 4's are really great You know people are always like why use new 5 6 or whatever there is and I'm like the 4's work Perfectly fine and get them repair. I'm fairly cheap now that all the new ones came out There's a lot of batteries. I've got another lipo battery for this. I've got two batteries I believe I have one more at the house, but I do need to go good. Go get that then the old remote Extra extra wings, but um Yeah, I definitely want to add this into the videos I think it's gonna add a lot of high quality stuff into drone shots. It's absolutely amazing. They look just Outstanding, you know really drone shots make a video in my opinion ten times better It's just so interesting, you know, you need a lot of cool b-roll. It's just really cool So we're gonna equip that I have another video. I want to make very very soon. That's gonna be high quality I want to make that just if I can grab the time to make that video and plan the storyline and plan the whole video out And just execute and make it sick So yeah guys, I want to show you guys this I just wanted to document a little bit of today and show you guys what I did throughout the day If you guys are wondering I went and got my fishing poles because I was going to take some photos And take some cool photos of those for Instagrams for some different content So I actually went and did that while I was fishing with Alan And I kind of did that throughout the day That was my main plan and then we were gonna go fishing as well. It just did not turn out We only see there for a little bit anyway, so we only had a few hours. So that's what we did Saw a lot of people fishing already around the pond. So that's probably why We honestly didn't catch any because there's people lapping the pond You know upon it's not like it's a lake, you know people are gonna be fishing that it's gonna be harder for this fishery Plain and shut up on but overall guys if you guys enjoyed these vlogs be sure to smash the like button be sure to comment below and Also, be sure to subscribe and hit that little bell. It means so much guys Thank you guys so much for the support every get everything you guys do for me You like in the videos on Instagram supporting me everything. Thank you guys so much But anyways, I'll catch you guys in the next episode Please like this video, please comment below your goals for 2018 I want every single one of you to comment at least one goal and I want you guys to go Execute and achieve that goal. Don't be normal. We're gonna change the world guys. Thank you guys so much for the support I'll catch you guys in the next


Welcome to Singapore Sequel's past after meetup, December, the last one for the year. Okay, I am Nagraj Venkatesan coming up with another session today on R and Sequel server. This session probably is the first one out of my comfort level, okay, meaning all along I have been a database administrator dealing with Sequel servers, installations. This is the first session where I am stepping out of my comfort level trying something different, more on trying to learn something different and also talk about something different outside Sequel after many, many years I am learning something outside Sequel after a long time and why me a database administrator has to read about R, if you are wondering. Sequel server 2016 as you all know, most of you know has integrated R and Sequel server where you have the ability to run R scripts within Sequel server. As I explore R, to be honest, I am kicking myself why I did not do this earlier. It is such a fascinating language and combining with Sequel server it becomes a terrific combo. I really mean it, it is a wonderful combination to have the most popular statistical programming language with the most popular data platform solution. It becomes a terrific combo. So what we are going to see in the next 45 minutes to an hour is okay, how R actually integrates with Sequel server, point number one and how many of your database administrators out here like me, just one, meaning do I have a room full of data scientist out here then that scares me a lot. Then you will be bored to death because I am going to talk some fundamentals of R and Sequel server. So R looking at from a database administrator's angle that is the theme of the session. Hopefully at the end of the session I will motivate more database administrators to learn R which I think is the future, the way things are going to move on. Rest or all, I understand few database administrators then rest, developers, how many of you know R in this room? R experts, any data scientist? Okay, rest. Developers? Okay, enthusiasts like me, I fall into some category. The thing is I do not know what category you belong to, that's okay, fine. Very good. Let's get started. So before getting into R, what is data science? This I just copy pasted from Wikipedia. Concentrate on the red words over there. Extract knowledge from data using statistics, machine learning, etc. In short, data science is about these three words. Extract knowledge from data. Okay, just to lighten things up. So can somebody just tell me what is the difference between knowledge and data? What you gain inside? Good. What you gain inside, right? So in some sense, yes. What actually we are doing in data science is we have large volume of data. It is just data till you analyze it and you get some useful information which you can apply. If not, it is just data, right? So where R fits into this picture is it is the programming language which you use to do that analysis. For example, let's say I have a huge data of last 100 years of rainfall and weather information in Singapore in one huge CSV file or in one database. It is just data. If I use algorithms to predict what the rainfall is going to be for the next month, then it is useful to me, right? This job of analyzing it and doing the prediction R helps you a lot in that, okay? Let's get a little bit more detailed into the process of data science, okay? First, you have a business problem. Mostly it comes from the CEO or the topmost management. Let's take up the same weather example again where let's imagine the MET department or the meteorological department. They come up to them and say, okay, I want to know next year how much of rainfall are we expecting to get in Singapore so that I can plan my reservoir capacity and so on, okay? So when we have this question, immediately this particular question will pass to the data scientist. Data scientist or any data scientist in this room? Good. Are these expensive, very smart people? You know, mostly a PhD degree have very deep understanding of statistics and mathematics and so on. More often than not, bearing a few exceptions, mostly they don't deal with IT. They are more of those very geeky mathematicians of sorts who apply those algorithms and try to do some analysis. This goes into the hands of a data scientist. Then what happens is he actually tries to make it into a data science problem. Just the thing that we were seeing right now. What he, okay, the boss is asking to predict next year's rainfall. So what are the things I need? Can I make it into a data science problem? Certainly yes. If I have the data, I can start doing my analysis. What kind of data I need? I would need probably last 10 or 15 years of weather information. What was the temperature? What was the rainfall? What was the humidity? What was the pressure? How was the pollution? Was there haze? How much trees were there? How many buildings were built? All these kind of information. Lots and lots of data related to weather and rainfall. So he will immediately, what the next thing he will do is he will immediately ask the IT department, okay, I need this data. Can you give it, whatever format he is comfortable in a CSV or something? Can you share this data to me in a CSV? Once the DBA, more specifically the DBA or the developers, they actually pass the data to him, he will start using the R or one of the statistical algorithms to analyze the data. What I mean by analysis is he will start looking at the data to see okay, okay, these are the most likely parameters which are influencing the rainfall or whatever the thing that I would like to predict. What are the factors that are most likely to influence? He tries to understand the data. In case if you are a developer, probably you can think of, you have a problem from your boss, you start coding. Initially when you start to understand the problem with whatever approaches you can take. That's what happens in the exploratory analysis or analyzing the data. Then comes the most important part of defining a model. Okay, what is a model? A model is the important phase where the data scientist actually defines the algorithm, the algorithm that he would like to use to this problem. He defines one particular algorithm. Okay, he knows that most likely these 30 columns are most likely going to influence my result. He picks up some algorithm which he believes most likely is going to give him a solution. For example, he'll put the three-year-older data into that algorithm as a test data. When we talk about three-year-older data, we already have how much of rainfall, we have the result already. So you feed the data to test it and evaluate how it is going to predict last year's rainfall. You see, okay, last year this was the rainfall. My algorithm is saying this. So what is the difference?  So this process he defines and let's say it comes up, depending upon the problem, let's say if it is giving satisfactory results, then he goes ahead with that particular model. Okay, and then it is rolled out. Again, developer DBA and also the other application teams are also involved. Finally, it's rolled out to production. This model is, once it's rolled out in some of the systems, what happens is as the data is growing, it is also fed into this analysis system so that it becomes a continuous learning process of sorts, meaning yesterday's rainfall is also fed into the system so that it can be used to predict tomorrow's or next month's rainfall, something like that. So do we have an understanding of what data science people do? Okay, one important thing is I have marked who are the people involved in this. If you notice, it's data scientists, DBAs and divs. Let's say if the DBA and developer and guy starts learning R, starts understanding R, do you imagine how powerful that person can get? Because he can cut across the entire process, meaning right from the start to the end, he has an understanding of what can be done and probably he can, over the period of time, he can participate in the end-to-end process. Why I personally feel, this is my opinion, DBAs should start learning R is, the way this IT and overall data platform scene is moving is it is all the tasks that are done in the same way or repetitive tasks like installation, configuring a backup, these kind of configuring monitoring. Most of these tasks, repetitive tasks are getting automated. What you would have over a period of time is more of analysis, data analytics, those kind of things. So it's not that these traditional ones are not needed. That one alone five years down the line may not be enough for you to sustain in the market. So it's extremely important to widen your skills. So picking up languages like R is, in my opinion, every DBA should start looking at it for a few reasons. Let me also explain as we go through this session even more. What are the common applications just to imagine? Imagine a cancer laboratory where healthcare is one sector where data science places massive rule. A cancer laboratory where you have a patient's data coming in. You want to know whether that person has cancer or not. You have all the kinds of information, what kind of symptoms he has and so on. You have, when you have R and other algorithms which actually look into these symptoms, symptoms in very, very layman terms, you can think of them as columns for database people. Let me explain in database terms. You can think of these as columns and then you actually want to find out column A, B, C, D values are like this for last 10,000 rows. For the next row, if these are the values, what will column E be? That's what are one of the things that we are trying to do. So imagine some case where like a cancer or whether a person is likely going to have a heart attack. Let's say you have the data of his age, his weight, his blood pressure, cholesterol, all these information and you have the data of people who have heart attacks. Then you can use these algorithms actually to predict there is a 70% chance of you having a heart attack if you go at this rate for the next two years. In healthcare system, usually what they say is the algorithms need to be a lot more accurate. When you are saying a person does not have cancer, make sure you get it right. Next fraudulent transactions or stock prices, how they are going to progress, it is getting, you can apply it very well over there and customer behavior like in retail markets, whether the person is going to buy the product or not, what is his past, previous choices, what is his nature, the way he spends. In my opinion, any industry you name, there is scope for you to apply these concepts. Even some of the simplest one can be a spam filter. The email comes in, you want to figure out whether it is a spam or not. It is again a bunch of parameters and you want to say yes or no. So far do we understand what the data science is all about, okay. What is R? I have already explained a few times. It is a open source language. One of the things is it's a open source. There are a lot, as I say, 2.5 million users has been around since the 70s, a very old language. What Microsoft R is all about is they adapted the open source R to be specific, a particular version 3.3.2. Microsoft R is also open source. Meaning you can add on your packages to it. They have adapted a particular version and they have made some really good enhancements. One of the pain points or let's probably, let me ask the gentleman over there who actually works with R. So what are the pain points you would commonly face if you are using a traditional R? I just want to know from some, sorry. Slow, okay, good. One of the few major pain points in the traditional R is the computation, meaning I keep speaking about algorithms, right? The algorithms for it to run, it runs on the R client, just like our management studio. It runs on the client tool. What happens when it runs on the client tool? You are limited to whatever resources you have on your client. And more importantly, R does its compute all in memory. So if your client machine has limited amount of memory, I have seen many developers complain that they are unable to compute simply because of lack of resources on that particular client machine. The first and foremost thing about Microsoft R is you can leverage on the server resources, meaning the compute or doing the calculation and working out the algorithm, it runs on the server, just like we run queries, meaning you take advantage of the massive resources of a huge database server. Next, again, you are defeating the memory limits which are traditionally there with the R client. If we are using SQL server as the data source, and the data base, we are obviously putting our R service and the SQL server on the same database server, then fetching the data from R server to the database, there is no network traffic involved. It's a direct straight transfer, which is again a massive, massive gain when you actually use traditional R. And then parallelism. When you are using the traditional R, when it runs from the client, it is single threaded, whereas when you actually put it on the server, again, like SQL server, it has the ability to make use of parallel processes to do the compute. Another one of the pain points that was explained by a few developer friends of mine who actually use R was porting over the application into production, meaning I use R. It is not that easy to deploy the solution. More often than not, you have to convert the R code traditionally into some other programming language to actually make it into a running code on production. Some people say doing that can take months. This, again, can be avoided if now you have the ability to place your R code within SQL server stored procedures, which means it is a much, much easier task to place your code inside stored procs instead of trying to develop another layer to deploy it to production. Yeah, sure, shoot. Of course. You said that Microsoft took the certain version of R and then they made it as a open source. How does it evolve? Are there some people? With patches, actually, it does get upgraded. Beyond that, even if you want to add your own packages, obviously, you can also plug it in. For example, R, let's say that there is a package that exists that runs in R and you want to make it like converted to Microsoft R. I won't be covering how a package can be deployed. Your custom-made package can be deployed, but it's not so much of a task to do that. You can always port over a particular package and push it in. Previously, there was a company called Revolution Analytics, which they had developed something called Scale R. Their packages have been adopted. Microsoft actually took over that company. Their packages have been adopted and further it has been improved. What effectively happens is on the database server, you install, once you install R services, you get two services. One is the R service, which is called the Launchpad, and then you have your usual age-old SQL service as well.  Even on that client, you can actually set the compute to server, meaning you can actually set, run all my R commands inside the server, not on my client. You can set that. Once you set it and you run some commands, then what happens is the request receives by R service, then data is fetched from the DB, and then the result is thrown back to the end user. This screen looks familiar. This is the installation screen. What's different in a typical SQL installation? What you see, too small, is it? Oh, yeah. First, let me show this screenshot. Yeah, so you see R services in database, which means once you check this component, this actually gives you the ability to call R commands from your SQL stored procedures. One of the things, even if you don't like, okay, I don't want to learn R as in, as a database administrator, at least you should know how, moving forward probably three years down the line, you may be asked to deploy R code onto your DB server. So at least you should know how to add the R code or how to install R on database server. Nothing fascinating on setting up R or something. It's pretty simple. So you need to enable R in services. That's one. You have this other one called R server standalone, which is not the focus of this session, which is mainly for if you decide to run just R alone, not database service, just Microsoft R service alone, not the database service. And when you pick the services, you get this SQL server launch pad, which is actually responsible for the communications between the database server and the R. So you can think of it as typically the R service, which is behind the scene going to do the job. And another screen is also regarding the license, GNU license. So you need to accept that because it is based on open source components. You have to accept the GNU license to use this component. And one more point is installation. By default, it goes to download the packages from the internet. So if you are on a server, which does not have internet where you need to install R, you have to download it offline and then store it in a certain location and then use that to install. So there is enough material for you to look up how to do an offline installation. Okay, the focus of this session, again, is to show how you can actually start calling R commands from SQL server stored procedure. Me being a DBA after I learned these concepts, just a little bit of it, I have enough ideas to actually implement this on my day-to-day job, whatever database. I maintain about 120 database servers. So I am fascinated so much by this language that I would like to apply it as a database administrator. I have enough use cases where I feel I can do a better job using R in my office itself. Couple of scenarios I will show it today as a demo. Probably my intention behind this session is, hopefully I will motivate some of you to think in that lines to use it innovatively on whatever projects you are working on. So I mean, how it works. Let's say you have a stored proc. You want to run an R command on also a SQL query. So immediately the call, you need to call using something called SP underscore execute external script, which is the script similar to our XP command shell you can think of it. That is the script that is used to run R commands. And then the call goes into the R service for the launchpad.exe, which actually spawns processes. It actually spawns something called satellite processes internally to run the R results and return to the DB server. Each SQL account, which is actually running the satellite processes, for each SQL account it runs, you have a different Windows user account which actually runs the satellite processes so that you have a good layer of security when you are actually calling some Windows process.  Account B will get a different account. It's not the same account which runs all the satellite processes. Okay, so let's... You just need to use... I have already enabled it on my machine. You just need to enable... Just like XP command shell, you need to enable external script execution. And then for non-Sysadmin accounts, you need to grant the permissions separately. Again, similar to what you do for XP command shell. This is just a very, very simple, basic Hello World call. Hello World. Programmers will know if you start a program, first thing you do is try to print Hello World. So this is something like that. So what it actually says is languages are and this input data set is the input query. Output data set is what the output we are planning to print and the result set out here is the result that we are going to give out. Just a simple Hello World. So we will be looking at slightly lot more complex. I would not call it complex from data scientist view, but for someone new, slightly lot more complex R scripts in the subsequent slides. So before we move in there, any questions so far? Yes, please. Okay, shall we get into little bit of R? First algorithm I would like to take up is probably the simplest, one of the most simplest algorithms that you would actually use in R, which is they call it logistic regression. What logistic regression actually does is, let's say we have certain bunch of columns and we want to predict a value of another column, but it allows you to predict only zero or one. Usually you use it in the cases of pass or fail. One of the classic examples in the R site, if you number of people who survived the Titanic, whether the guys who traveled took the Titanic ship, how many people survived. You can use logical regression to find out, okay, first class people survived, second class people didn't survive, first class male survived and so on. Again you can probably use it for credit card fraudulent transactions because over there we are just predicting whether it's a fraudulent transaction or a genuine transaction. Let's say you have the data of where the transaction is coming from, how many frequent transactions, what is the transaction amount, usual transaction value, what is this account limit, all these kind of information you have and then the new transaction that comes in, you just want to figure out whether it is going to be a fraudulent transaction or not, yes or no. Those kind of things can be applied using this algorithm. Okay, now let's get into a little bit of a familiar territory of a typical DBA table. Now how this algorithm can be used in DBA's day-to-day life is what next thing you would like to see. How do you guys monitor your DBA server? Like do you track some, how do you track your workload of your DBA server? One of the common methods is people have these tables where you actually track at a certain frequency the queries that are run against your DBA server along with how much of CPU it took, how much of memory it took, what was the weight type, how long it weighed, was there any blocking, where it came from, all these kind of information. In case of a performance problem, what does a DBA would like to figure out? Who, whether the query is expensive or not, expensive or not, right? Let's see whether we can apply R to this particular, excuse me, I didn't select something. Okay, let's say I have this table, this particular table I have simplified it so that for a demo of this range, we just have a few selective columns where I have CPU time, duration in minutes, how much logical reads and what was the query. By past experience I have marked the query myself. This is the training table where by my past experience I have marked these queries actually caused a problem to my server. I have marked it on the column called expensive query. If the value is 1, it means it's expensive. If the value is 0, it's not expensive, right? So over here I'm going to, I know the data fairly well, so I straight away get into the model development phase of the data science process. I just get crash into that phase. So I'm going to build up a model. I'm going to use logical regression. I'm going to build this model using this data, this is the training data, and see how it is going to be helpful if we were to use for finding whether the query is really expensive or not. So this is the way you actually create, pass some serious queries into the R scripts, use it along with R. First you define the query as a string, and then this is revolution scale R's function, Rx Logit, which is the logical regression, logistic regression function. Over here you specify which parameter is the one that you are going to, which column is the one that you are going to predict. Over here I specify the factors that are going to influence, because we are DBS, we know obviously CPU, memory, all these kinds of things are the ones that are going to influence whether my query is expensive or not, right? So I pass these parameters. Data scientists don't laugh. This is a very, very simple model that I am showing for people. And yeah, me being a beginner in R, I know only simple models. And what I am doing out here is, I am going to store it inside a table. I build this model, I am storing it inside the table, so that I can use this particular value to do my predictions. So basically this query and this algorithm gets inside the table. The data type needs to be var binary, that's it. Okay, so I have created the model. Now let's go and actually do some prediction. Let's say I want to track what are the queries that were expensive in these three days, between 2015, July 16th to 19th. And just I would like to leave out backup queries or sleeping queries so that I actually care for the serious workload. Again, we define the query and then we pick the model that we built just now. Unserializing is actually opening up. You can ignore. The most important point is the Rx predict where we actually say this is the input, this is the score, predict var names actually says what is the probability that column is going to have 1 or 0. It gives me a probability saying that whether the query is going to be expensive or not. Over here I pass the input query and I try to get the output on this particular variable. Let's go ahead and run this. Okay, it says it's done. By the way, I'm running on a very, very small laptop with 8GB RAM and not supposed to be meant for these kind of calculations. So it takes a while.  I have stored the result in this temporary table so that it's easier for us to query and see what it has returned. The important point is I asked it to return the thing called score. This is the output of the algorithm and over here you can actually define score and these are the input columns. I'm also pulling the input columns so that we can actually compare our results. Okay, now let's run this quickly. I have multiplied the last column by 100 so that it appears like a percentage. It is expressed in percentage. So whatever that's close to 100 is actually a expensive query. Let's go ahead and observe the ones that are more than 90, meaning the algorithm actually tells me I'm 90% sure or 90% or more sure that this particular query is indeed expensive. Let's see whether as a database administrator by looking at the query we can actually have an idea whether it's an expensive query or not. So these are the queries it says it is actually expensive. Look at the reads out here which is significant or look at, especially look at the ones that are 100% which act, if you notice the reads are significantly high the CPU time is high the time taken is about one minute and two minutes and so on. So as you can see how much of time did it take for me to come up with something with certain amount of intelligence instead of me randomly looking at columns and trying to pick something instead it hardly took me probably about 10 minutes to build up this thing. Little bit of effort to learn what these words are, what the weird errors are. We have a friend who understands R fairly well it makes it little easier but not so hard. When I showed this to my development friends they equally loved the idea because usually they have it as text files their data is as text files. Let's say if they want to change something it is painful over here okay I don't like this model go ahead and delete that row and put another algorithm in club it in. I want to change my training data set modify my query it's in 10 minutes I can do changes. Imagine about using a CSV and doing those things it makes it a lot more painful to build something like that. Any comments like it can be basically I'm interested in learning I have I try to talk to two or three people regarding this what they were also telling me is yes it is hard to meddle with CSVs than to play around with these columns it's much much easier to do those kind of things. This is one part of the story other part of the story if you are a regular to this meetup I myself would have given sessions on all the other fascinating things on SQL Server 2016. So what it means is my query can take advantage out of SQL 2016's powers my R also takes advantage out of Microsoft R's powers together it becomes a superb combo of sorts. Imagine reading CSV files imagine loading billions of rows as CSVs and then trying to do the processing instead you have a cluster index or you have a cluster column store which is actually going to fetch the data for you from the database which makes it several times faster not just one or two times in my opinion it is going to make the process faster by 30 to 40 times and when you have it as these tables in these formats you can make it into a continuous growing one it is so much more easy your real time data flowing into your training model you predict and you pass it back on to the training and so on doing these manipulations becomes lot more easier if you are if you know how to query and if you are able to do. At the same time I have also like to say that building up simple models are fairly easy but to build real serious models you need to know you need to have a very good understanding of R and R it is not something like in my opinion it is not something whatever I have heard from other data scientists whom I have met it is not something that you can just go ahead and pick up in six months I am a data scientist no way there are people who work on that have their PhD degrees they work so much spend so much of time on statistics and all these things to get that skill probably you start exploring this you have a mix of both worlds very competitive probably you spend about a year or so on R there are interesting courses on Coursera have you guys heard of Coursera.com yeah so you can probably take up one or two courses on that start learning a bit of statistics and algorithm not to compete with the data scientist but if you have if you invest certain amount of your time then it can be a very very terrific skill for you or at least know a few algorithms which you can actually use in your office to make do things in a lot more efficient way any comments or questions yes please any how many from the R user group out here anyone you are the only one I have asked you many comments yes yes yes for a base point it is more important that you actually understand then this is only a tool in some sense okay in a way it is important to understand what the algorithm is actually doing because yes this is just a tool but which algorithm you want to know yes just like C++ or which algorithm you want to apply is something you need to have certain yeah there is no to say just using this absolutely yeah for example you are talking about developing the model yes how in the first place do you verify a model is a valid model yes absolutely you have I mean here it is garbage how yes absolutely that is the point I was actually previously driving through as well these are what I am showing is you have to go back to the first or the second slide where I was actually explaining the data science process evaluate what you have actually done you take the data you evaluate over and over again whether the algorithm and your overall system is able to predict and ROC curve you need to check the evaluation process when you define the model okay I mentioned that at the bottom of the slide where you have to test train using an ROC curve to find out how much more yes absolutely there is no denying of the fact that there is lots and lots of iteration and there is lot of time spent in this these two areas where you actually evaluate the model so much more times to figure out whether it is working or not but as I said you should start getting yourself exposed into this there is no point saying that okay it is too complex for me to learn and I will never ever take the dive as I said if you start getting the understanding then you have an ability to participate on the entire life process of the data science yes of course as I stated this particular session in the expectation of this particular session it is more from the angle it is obviously you cannot wrap the entire data science process into one single slide I am giving a 12,000 feet overview of the entire thing that some the target audience is not data science expert as someone it is more for people to get started with the concept been running up from SQL server and from Studio Studio for example from Studio Studio Vish Fundamentally there is nothing much where as long as you can set the context even on Vishal Studio you can actually set the context to run from on the db on the server okay so that is not so much of a difference as far as developing a model or playing around to see the data you can there is not much of a difference but doing it from the management studio you actually get the power to actually put the entire code into a single stored proc and deploy it a lot more easily that's about it yes we are helping a few our algorithm now and our analysts so they are running from visual studio or from RStudio so it's their own reference and to get the data for their testing when they are developing they use this ROR dbc library so they create this connection inside R script and we found also that you can send only one input data set as a parameter to this external script and it means that we have to use this connection inside R script and does it mean that when we run external script from procedure as you showed now if we use that connection to single server will it use the advantage of this input data set as far as okay to repeat you can actually so will it optimize it as long as you set the compute context there is something called Rx compute where you actually set that thing has to be executed on the server on the R line as long as you set that it doesn't matter what you are doing the compute runs it will be run there yes absolutely one more question go something like this resource allocation you just give me one yes which one should I give priority because you are running both db instances on R services let's go for the next demo called linear regression this particular algorithm is actually what it does similar to the last one over here this one also predicts based on certain columns over here beyond zero one you can actually predict the value that you want to you want to figure out another use of this algorithm is you can also see whether how much of a relationship between these columns and the column I plan to predict whether does it have a very strong relationship does it influence so much or not so typical use case is the advertisements or advertisement campaign to the sales after advertisement do you think the sales has improved does it have any relationship to the way sales is progressing and so on what we can do over here again more from a dba angle of sorts we have server and database growth we have this is my growth this is the server so I want to predict how much my growth of my database will be after a certain period let's see how we can do that I have this table called tb growth which actually has the size and server name date of growth and so on it tells me 312 gb this is the growth and etc now we are going to again build up likes last one we are going to build a particular model and train it and then again as usual try to come up with some estimate over here I am passing one month of data January 2016's data I am passing it and every day the size is recorded per and let's see how we can predict just to quickly go through rx lin mod is the function that I am using again similar to the last time around size server name database name dt so these are the columns I think which actually influence which are actually I need to take into account I actually have to perform a similar task in my day to day office where I have to do capacity planning meaning I have to submit I think most of the database administrators will have to submit instruction for next year etc where I do a very very naive simple approach I take a extremely simple approach of just taking last 6 month average and then just projecting it out you will be surprised there are many monitoring typical monitoring tools which actually takes last 3 month average and project 30 day 60 day 90 day projection instead applying something which is sophisticated like this gives you lot more realistic numbers instead of doing a blind projection of using just a 30 day average or a 60 day average over here I go ahead and I said which month I want to evaluate 2016 February okay again we will I pick a date that's there already so that we can we get to compare the syntax is pretty similar again I am using the same function to predict you can this particular function is used for multiple algorithms for prediction over here it gives me what is the predicted size because these are old months we can actually compare what the existing size and the predicted size it is slightly of the mark around about around about 10 to 20% 20% of the mark but still something certainly better than whatever I am currently doing with 3 month average or 6 month average which is just a blind guess of sorts whereas this one takes into account how the numbers actually vary and then it tries to apply yes of course earlier I was actually explaining how it actually influences yes little bit of effort needed to understand how you use it but as I said for a database administrator you can actually think of many use cases where you can actually apply performance monitoring, capacity planning you can use to analyze query regressions what queries started performing poorly you can start in SQL Server 2016 you have the query store which actually gives you reports on query regressions even if you have an older version of SQL Server you can port over if you have the data of how much data what the query performance is into a SQL Server 2016 instance and use these algorithms to quickly actually try to figure out which queries actually regress error log, audit log abnormalities you can even use this to analyze abnormal entries V database administrators when you have massive volume of error log to analyze it becomes lot more harder to do that manually you can use that as well another interesting use case somebody actually in this year's past conference one Joe Sack actually explained one of the interesting use cases was when a DBA goes on a holiday what is the chances of you having a problem on the DBA server interesting right so actually if you are creative you can actually do wonders with this you start getting yourself exposed then you actually start doing many many things you can analyze query store data, performance data do capacity planning, error log analysis you can do lots and lots of wonderful things with this GUI mode meaning meaning as of now you have to cut and paste your R commands right into into the stored proc so there is no grasp but you can obviously look at graphs and histograms on the previous session where the other gentleman actually was giving you an introduction to R you can run the R commands alone to get some graphs or histograms using R commands on the R console or on your on the R client when you are plugging it into SQL server this is the way you do okay as you asked actually how do you how do you actually control the resources one of the key things to R again is a memory hungry technology so one of the key things is how do you size your memory for R so launchpad.exe over there you have the config file under the installation folder you can actually set the minimum percentage by default it's just set to 20% of the physical memory available on the server you need to carefully size it again meaning allocate enough for your SQL server allocate enough for you can set the adjust this cap so that you have enough for both the things to be running one of the another interesting enhancements with resource governor is you can actually cap use something called external pool on resource governor with which you can actually cap the memory that's allocated outside in the SQL server instance you can use that to control which user account actually takes how much of memory for R outside SQL server as well launchpad controls it at R service level even at a user level you can use RG suited for large servers again because you want to do heavy duty processing you want to process large volume of data you want to use column store and all these concepts on the database level so bigger RAM faster machines carefully size your memory as I said during the initial slides where once you install it you get a group called R user group grant your permissions wisely do not over grant provide any additional permissions that are not needed for R execution number of distinct user sessions is for R is limited to 20 by default you can configure that but unless you really need it meaning when I mean distinct session number of distinct SQL accounts which can execute parallely R sessions is limited to 20 you can you can actually configure that set launchpad service store similar to agent launchpad service is dependent on sql server when sql server is stopped launchpad can also stop so you would like to set it to automatic references any questions yeah this space on the revolution analytics before questions I actually want to narrate a little story one of my key references for this particular presentation was this e-book released by microsoft free e-book released by microsoft microsoft data science the author was Wang Hong talk when I last august I attended sql server geeks conference where one of my microsoft friends actually introduced me to is this gentleman called Wang Hong talk he is a very big expert in data science then he came up to me and spoke two lines do you use data science no I don't have much of exposure do you use this no I just maintain service now when I read this book oh my god I was talking to someone so fascinating he is the guy who has written this book and I have been reading this book for last two months out of that I understand 30% of what he has written out of that I am presenting 10% it's like you meet Tom Cruise you haven't seen a single english film you are an actor on Hollywood then you go and watch a big movie oh he is this great data scientist whom I met why I didn't read this book earlier so that I could have asked some interesting questions to him so that was the feeling I was going through I was just kicking myself I meet this gentleman who has written this he holds a PhD from NUS so but I didn't have an interesting conversation even though I met him at that time of the day so start learning start exploring just 9900 pages even less than that no just 70-80 pages probably that's about it 70-80 pages you cut off the foreword all those things it will be just still I would probably vote for R simply because still analysis services has a lot of processing you have to build your cubes design and then write this one is a lot more no nothing each one has its own certain pros and cons meaning analysis services is targeted for a different kind of workload where this one is more on prediction and what you want to do that is more on classification and so on any more questions folks sorry if you are super bored by this presentation which was more on basics I hope you understand the focus of this yeah of course we have just recently seen a case of real life statistics got wrong of course absolutely you just keep going wrong but statistics are in demand you want to study everything you want to predict it's just like astrology you know that it's going to fail but still you take your flick your paper to see what's the zodiac sign like it's not going to be true all the time so at least know to learn how to use this actually anything else folks yeah you can if your workload is more on non-sequel workload probably you just have to do some text-based processing you don't have much to do you can just install or as a standalone as well if you have a SQL enterprise license then you are allowed to actually install or separately and you can have your SQL server separately yeah standard edition basic analytics is allowed meaning there are certain limitations in terms of parallelism but still the fundamental packages you can still use it on standard edition as well yes of course yes shoot does it only work with R? then there are like different versions of R right so we have the R that is from CRAN this is specifically for Microsoft R what we are talking about is strictly Microsoft R or the version that has been developed based on R 3.3.2 so you can import your package into this one certainly but this is based on you have to import it R from CRAN basically there are some fundamental differences basically as I said one of the two basic you have certain packages which are inbuilt you can port your package into this that's one even the way you use the functions over here you would see Rx Rx predict, Rx linmod and so on there you would just see something like RLM and just a prediction this is more of the revolution analytics version of sorts if that's all thanks a lot people so if any further questions probably I will take it up offline thanks