I wanted really to share some experience, insights and possibilities and just to say that from the beginning of the practice which has produced the kind of buildings that Kent has been talking about been advocating a green architecture since 1967. At that time it was truly radical, it wasn't mainstream, it wasn't even called green architecture. So a few words about sustainability. For me it's really about working with nature, it's about change and innovation, questioning, challenging. It's a belief in technology but technology in a benign way as a means to social ends and that link between all these issues, memory and history is a key factor. This is a very recent image, really very direct self-explanatory. We have to change the way in which we consume, create waste and move into converting waste to energy in such a way that is a total cycle. If that's a recent image then if I go back in time to the earliest projects in the late 60s, early 1970s and it's perhaps a reminder that sometimes the unbuilt projects are the most significant. In this which was for a shipping company, the creator, the headquarters in a forest outside of Oslo in Norway and touching the ground lightly with a series of pavilions. All the recent mantras of recycling, here we're talking about recycling water, converting human waste into fertilizer, ventilating naturally with cool air from the forest floor, encouraging sunlight, solar collectors. Another unbuilt project at that time for the same shipping company which operated cruise ships which returned with produce from the Canary Islands. This was a regional plan and one tiny glimpse of that project in many ways says it all. It's about solar collecting, there are batteries underneath the kitchen, it's converting the human waste into fertilizer for agriculture, it's solar stills for creating drinking water from sea water. So in a way all those ingredients are there in the 1970s. I was very fortunate to engage with Buckminster Fuller and collaborate with him for the last 12 years of his life and the project that we did together which was for his family and our family at that time soon to be interestingly realised as a project is a totally autonomous house. And that house, the whole house would move and a shade would move around it to protect it to harvest the energy and I've never really made the connection between that and perhaps a more familiar built project in Berlin, the Reichstag. But in a way all those elements are there, here it's a beacon on the skyline of democracy at work and here you can see the reflector which brings natural light deep into the chamber, reducing the dependency on electricity and that mirror like cone also extracts the air as part of a ventilation system. And just like the autonomous house, the solar shield moves around according to the sun. In social terms the public is on top of the politicians who are answerable to them, one above the other and it has this energy manifesto which demonstrates that it's possible for a public building to be zero carbon, zero waste in this instance driven by literally vegetable oil. So that belief in working with nature buildings which can use air at ambient temperature, reduce energy and create a healthier environment, the very first example of that was a centre for the arts in East Anglia, the Sainsbury centre. Our first breathing building, no reliance on refrigeration and a very, very literally cool climate. And pioneering interestingly here in Germany with Comets Bank, the bank on the left which was the first naturally ventilated, nonetheless a controlled climate augmented but for 70% of the year literally working with the air. And that developed over the Swiss Re in London and the Hurst Tower in New York. And if I move from the urbanity of New York to Silicon Valley and perhaps look at this project in a little more detail, how does one reconcile this image of Silicon Valley with the first meeting with Steve Jobs where he describes this as the fruit bowl of America in his youth and with an awareness that one of Steve's kind of extraordinary abilities was always a meeting was a walk and ideally a walk in the country. So how could one translate that in terms of a project and this was the site and the statistics of that site and here we see the superimposition of the very familiar circle of a building. The key statistics I guess at the bottom there is that half of that site is covered in asphalt and there's very little landscaping. And in its final transformation there's virtually no tarmac and everything is about the landscape. Now the interesting thing about this image is also 30% more people on that site and what appears to be a very large building and physically it most certainly is but you have to compare this with a multiplicity of individual buildings. And you don't get the scale from this aerial view. If I was to put you into the heart of that circle then the building becomes a kind of horizon and here you see the recreation of that California landscape. If you move outside of that circle to the landscape, the other side of the ring then it becomes very much an incident in the landscape. It's not the only building. There is the Steve Jobs Theatre and the Steve Jobs Theatre is almost like a kind of flying saucer in the landscape. It's quite massive that roof. It's about 80 tons and it literally sits on a glass wall, a glass curtain. And in the joints between the glass, the services, the electricity is almost invisibly fed up. So that's a kind of celebration of space, of liberation with this structural circle of glass around it. That same use of reflective glass to kind of harmonize with nature. These eyebrows are in part of the facade providing shading, but they're also bouncing light deep into the heart of the building. And that external wall virtually disappears and here you can see the underside of that which is reflecting that landscape and bringing it in. If I talk about the fusion of the social dimension and also the technology and the quest for a healthier building, then at the top of that sheet of glass here we see the junction and you start to see the movement of air and that controls the flow of air. There are also filters in terms of dust or insects, although it's a very extraordinary, benign California climate, so working with that climate. A lot of the things over the period that I'm describing here, which is some 50 years or a little more, being driven by the very subjective idea that if you have a relationship to nature, if you have natural light, if you have a good view, if you have a changing climate which changes with the seasons, then it will be healthier. But that's always been very subjective until 2016. And here you see the testbed that enabled the Harvard School of Public Health to quantify the benefits of a normal building or a super green building. And what the people on the upper level who were doing various kinds of tests, mental tests and so on, didn't know is that the plant room below was changing the environment to simulate the conditions of these different buildings. And here in a nutshell are some of those findings, but the three kind of critical peaks, crisis response, use of information and processing that for strategy, scientifically proves something which over many decades was very subjective. If I talk about those qualities in a building, it's arguably much easier to do that in a rural area of California, much more difficult in the heart of a kind of throbbing capital city. And this is the Bloomberg headquarters. And those fins are the gills which enable the building to breathe. So they filter, they attenuate the sound so it's very quiet inside, although it's quite noisy outside. This is a cross section through the building and you can see that the movement of air is concentrated with the vertical movement of pedestrians within this building. And the way in which natural light can come above. So again, it's a very holistic way of bringing these often completing challenges together. The vortex starts at the ground floor and then it spirals up into what is called the pantry. So socially everybody has to come here before they go to their actual floor of workplace. So this is the kind of social hub and I just want to have a few words about innovation. You'll see that there is a hardwood floor there. How do you reconcile the idea of a hardwood floor with technology where you want access immediately to wiring? And how can that work in an office environment where normally you would have carpet? The answer is the ceiling and the ceiling is doing many different jobs. The floor incidentally was an invention of ours and that is the wood, the hardwood has a magnetic layer and that enables it to cling to the full access floor below. So it's total flexibility and acoustically that is possible because of the ceiling. And the ceiling has two and a half million of these little petals and 50,000 of those has a little LED and chilled and warm water can pulse through that ceiling. So it's working acoustically. It's part of the heating cooling. It's modifying those times when it's too cold outside or too hot and you want to modify that climate in a controlled and energy efficient way. And we conducted research with our own engineers and created this laboratory to test that and these little pillars are simulating and monitoring their people at a desk. So the research was really quite a key element and that's really just one glimpse of a belief in research. If you go to a bathroom in this building it will look completely normal. What you will not know is that it's using a system that was patented and which is in use in every airliner that's currently flying in the world. It's a vacuum system so it operates on a fraction of the amount of water. Water's harvested and it's totally recycled. And as Ken said so far this building has achieved the highest rating for sustainability of any building so far built. That interest in aviation and as a kind of aviator, passionate pilot interested in all things about aviation and curious about locomotives, transportation and so on. Then we had the opportunity with our first airport, London's third airport to question this model. If you transport yourself back into the 1990s, the end of the 20th century, this was a typical terminal. If you looked up it was full of services, ducks moving air, roof mounted plant, mechanical plant that would service that. And because it was dark you'd need lots of electric light generating heat. So the radical move here in a sustainable direction and a humanistic direction was literally to turn that upside down. All that heavy equipment would go below the concourse, would feed from below. So you had 24 hours, 7 days, every day of the year access to it. And you would get the benefits of natural light and the energy savings that would come from it. We developed that model, it became a model for other architects, planners, it's an established model. And most recently we started with the opportunity for a competition for international airport in Mexico City to see if we could push this idea further forward. So here in that image you'll see a curve roof and you'll see vertical glass walls. What if you could have a skin that would encompass the links to the aircraft, the windows, and by taking that approach you could create bigger spans. You could create far more interesting space. So that leaps from 36 meters to 170 meters. And that continuous skin then becomes, as I described it, the expression of the building. To explain this concept to the jury, I made with my colleagues a small film. And it was really to convey a centuries old idea before architects became involved in buildings. What were people doing at a very basic building level? Mostly around the Mediterranean, the so-called Catalan vault. And that is that if you hold a piece of rope then under compression it would describe a very beautiful, very, very efficient curve. And if you could freeze that and you turn it the other way then it becomes the perfect tensile structure. And going back in time with that knowledge and working with several universities and students using very basic materials, Earth, but with a high tech additive we created a prototype drone port which has since become a permanent pavilion in Venice. And here you can see the group of us, the students realising that. And it's a reminder perhaps that if we want to look far ahead to the future then perhaps first we should look far back and learn from history. The application of that line of thought to creating a series of experiments in the desert on the fringe of Abu Dhabi. For a research facility, a small university, the start of a larger community to explore renewable energies, Masdar. But first we wanted to learn how before an age of cheap energy, how a community living in the desert could transform a very hostile environment into a very elegant, liveable habitation. And here if you take the kind of cuts as you move from the desert, scorching heat, then as you get into the public spaces of that city that I showed in the desert, you'll see that the temperature drops as a result of orientation shade. If you go into a courtyard then by evaporative cooling the temperature comes down further. Finally you go inside the home and because of the massive insulation it's cool without any refrigeration. So if we applied those lessons as we did in Masdar then we start to create spaces which are habitable, which are benign, notwithstanding. The fact that the temperature in the center western style is totally unbearable unless you're inside an air conditioned car. And then we move across and we see the student accommodation and we see the university labs, the two principles of expression. And here is the public space at Masdar. What you don't see is below there and this is going back now nearly 10 years is we're seeing robot cars, we're seeing induction charging of those cars. And we're seeing all the servicing that makes possible at that upper level which is also elevated so it's taking advantage of the cooler desert breezes just above the floor of the desert. So again working holistically. And that really driven by some 40% of the power generated by this 10 megawatt solar array. It's not to suggest that renewables offer a future in terms of countering emissions, greenhouse gases. Energy and industry, the production of energy and industry is the major generator of those greenhouse gases. Buildings and the connections between them, the mobility between them, 20% and agriculture is significant 24%. So if we're to look at the implications of the melting polar regions and the effects that that could have given that 75% of the world cities are on the coast and 50% of the population within 100 kilometers of that. And we pull back and we see a satellite image of those cities. Then as had been noted earlier, the future, our future is the reality is its global cities. And although they consume 70% of the energy and responsible so far for 70% of the emissions, which has to be addressed, the reality is that they are also the generators of wealth. A typical city can generate as much wealth as a country. So New York generates the equivalent GDP of the whole of Canada. If you take London, it's the equivalent of the Netherlands. If you take a port city like Osaka, it's the equivalent of the GDP of Switzerland. And it's also worth noting that one in eight currently live in slums. What does that mean? It means that a significant part of the world in this image of one city, South America, South Paolo, has access to everything that those on the other side don't have. In other words, they don't have adequate shelter, they don't have clean water, modern sanitation or access to power. Access to power is arguably the key to so many things. And we're talking here of something like 14% over a billion people and this kind of glimpse of illegal connections to power and the fire hazards of that in terms of kind of shanty construction. This is really in a nutshell saying that those societies which have access to power are right up there. Essentially, it's Japan, America, Europe. And those societies further down, excuse me. Interestingly, which don't have access to power, don't have the same, and it's obvious, life expectancy, infant mortality, enlightenment, and significantly, right at the bottom, those are the war zones. The war zones are those places that don't have access to power. There is an inevitable link. And if we're talking about a population which by 2050 is estimated to move from 7.5 billion to 10 billion, and 70% of that will be urban, then you're looking at the potential for one in three to be in those slum conditions. To put that into perspective, the idea that you question the current strategy in terms of how you address slums, our proposition was really almost naively simple. And that is that the current strategy in the absence of the involvement of those professions concerned with design, the political mantra is you bulldoze them and start again, which has not worked. And the scale of this issue is so large that it's never going to work. The other idea is that the slum is a place of despair and not a place of hope. And it was quite interesting, the insights from one project in India, Dharavi, and just to put Dharavi where we started to get an insight into some of these issues with a small team. If you can imagine a site which is half the area of Central Park and has two thirds of the population of Manhattan. Manhattan is 1.6 million and this site here in Dharavi, and that's the same outline is 1 million people. And that view cone there is pointing towards some new buildings. The new buildings were in an area which had been bulldozed and new buildings as an answer. You can see ring there those new buildings in the background and the team exploring that, looking at the bulldoze site and the recreated 14 story buildings. These are the only buildings which have modern sanitation and they were completely empty, abandoned, unused. The space at the bottom was used for cricket by the children in the community. And here you can see the team ringed and they're having tea with the community leaders and they're asking the question. I mean those buildings are empty, site was bulldoze, why are they not in use? And the answer was discovered just through seeing the economy and the needs, the physical needs of that community, who essentially process something like 80% of the waste of Mumbai. And the kind of accommodation that they need is essentially layered. It could not work, they could not sustain economically their life in those new buildings. So the idea that this is a poor community most certainly is, but irrelevant if you relate it back to the agricultural community from which they fled, then it's moving into an area of affluence. And there are all kinds of side stories on this, the way in which they bring together teachers from the state system and essentially create a private form of education and you see kids immaculately dressed with ties and really quite extraordinary. And that led to the proposition that if you reduced key points, the density, you could thread an infrastructure of services and you could regenerate those communities from within. It's at this point relatively recently and this is going back about a little over a year and coming together here around this table in the foundation. And the foundation is in every sense completely separate from the practice. So I'm really wearing two hats. I'm the common denominator between the work of the foundation which generates out globally from Madrid and the headquarters of the practice which is in London. So they're separate in every sense. And this around the table is the coming together with MIT to look at some of these issues and the application longer term of technology. And along the way this was one proposition that I made to reduce the energy demands, a heart unit which was generated by the needs of a slum but like anything that would address the issues of a slum would have a spin-off into the formal city so it would improve the quality of life. So for example if you could compress, if all the elements in a house, the heating, the cooling, the refrigerator, the bathroom, the storage if those could holistically talk to each other and compress into a much smaller unit then whether that was addressing the issue in a slum or creating more affordable housing or creating in luxury housing terms less space occupied by certain elements. And in that proposition I invoked in India the technology of what was then the most affordable car at the time. And this is going back some years, it's Tata Nano. And I met Ratan Tata, one of the key family members behind this great kind of manufacturing empire in India and I shared these ideas for his opinion and he was totally supportive and I said something like what if we could try on a pilot project, how could you help? And he said well first you'd need a smaller slum so you could work more directly with a group and also you would need to find a community which had a sympathetic civic leader, a politician who really believed in it, it wasn't corrupt. And so that was, it was a very nice meeting and the foundation is meanwhile working on these issues and then it's about, it must have been about after that meeting, two years, three years and I got a phone call from Ratan Tata and he said I shared your ideas with a politician who's the chief minister of one of the poorest states in India, Odisha has a major slum project. He was totally enthusiastic, what's followed from that is the land rights to slum dwellers which enables them then to start with a bank loan and so on. So he said there's a big ceremony handing out certificates in three weeks time, can you come? And this was last year and so that led to this meeting here. On the right hand side is the newspaper of that time which is the theme of the proposition that instead of evicting and bulldozing you empower them and you regenerate from within and there's the chief minister Ratan Tata in the centre and myself. And we started with a slum community, Sahibaba in Odisha and we met with the community and the community to our surprise had prepared a presentation. In the foreground is a drone photograph of their community and in that sense the drone technology made possible the mapping. In the background is something that they prepared. In the foreground in the back of that image there's a swamp, you won't recognise it but they produced their vision map and this fascinating when we question and challenge them on this it's just a really serious piece of design. For example in the heart of it they wanted a cyclone shelter and the promise was if we had a cyclone shelter then we wouldn't have to leave our community in the event of a cyclone. We would be here in place to guard our property. And I said something like this landscaping at the bottom here around the... Oh yes, if we increase the landscaping there then that's the direction that the storms come from. So it would modify our climate and at the top is a playground. They said of course if you drained the swamp there then we would have space. So at this point I said who are the architects and these are the architects and amazing, amazing piece of design. That led on to a number of projects. These are really early days, we haven't been active on these projects now not for a year, almost a year. So we're looking at another settlement called Neuhus Sahi and that is just a few facts about the extreme weather there and the effects of that weather on the kind of structures and the way in which a more robust structure has withstood that cyclone. I should say that these, all the images I'm showing here are taken by our team. We have a team which is now resident there working with these communities and liaising with the project group in the foundation in Madrid with a backwards and forwards movement. We sent questionnaires out in advance of our visits to these different communities and interestingly the one on the left is what would you like your community have, the one on the right is what would you like your family to have and out of these various questionnaires the first thing is a roof, a roof that doesn't leak, the second are the walls. In terms of the community it's about water first and in another survey once they got past this the next stage was what's next and that's a job and education. So it's been a fascinating insight. This is the aerial view of this community on the water with the beach and if you can see again this community like the first one has a swamp at the back and that gave the clue if you drained it for the way in which you could reduce the density, manipulate, create a degree of public space and address some of the major issues in this community. Trying to condense one year into a few minutes the idea is to produce a scalable model, something that we can document, the clues were given from that first community where they were using a vision map. So visually literate and able in a very sophisticated way to understand two dimensionally major design issues and so as a pilot project which would enable others producing a manual films enable others to spread the effect of these studies and working with the different groups individually and finally that is the master plan and what happens is you can see that the swamp has become reclaimed land and there are very very clearly defined routes and each of those different groups and the women again were very very powerful in terms of design and involvement and they were responsible for the cross routes the cross routes which would deliver security and access to a far wider range of homes. Here you can see recognizably in the background the master plan and the next image is the approval of that master plan. Work on the ground has started but it is somewhat painful in a way because coming to the premise of what Kent was summarizing you realise the inadequacy in these conditions of the mega grid the big power station, the massive amount of excavation with pipes this is the start of a toilet block in that community a part of the master plan now under construction and leads to the proposition of what if what if in a community like this you could be autonomous you could plant a box, deliver power and as a reminder there's probably right now there's probably up moving up to 200 million people on this planet who are not served by any kind of heavy infrastructure they may be on a train, they may be in a cruise liner or they're in an aircraft so there's a global population on the move unconnected what lessons could we learn from space there've been very interesting initiatives derived from space the Gates Foundation has been working on this power is a key element it's not possible in the density and whether it's the density of a slum or the desirable high density of a formal city as we know it here it's not possible to have the surface area for solar cells and what about the mobility revolution right now the amount of road that was devoted to highways in the 60s and 70s is being ripped up changing to greenery whether that's the big dig in Boston in America whether it's in Seoul in Asia whether it's in Madrid in Europe what happens to those parking structures when vehicles are moving autonomously pretty continuously on call through our cell phone ownership has become something that's very perhaps marginal and is mobility three dimensional and so what are the examples which might demonstrate as Bucky would advocate the power and the importance of higher performance doing more with less and striving to have a higher quality of life not just for those who are dispossessed but for everybody alike more with less urban farming has been demonstrated already to produce which is more flavourful, delicious uses a fraction of the water and would urban farming lead to a greener, quieter, cleaner city a market embedded in the heart of a city what lessons might we gain from insights into innovation in the world of medicine many of us myself have experienced an MRI a huge piece of equipment and you move into it it waves a huge amount, it costs millions and millions occupies a lot of space is unaffordable for screening say for breast cancer the foundation is interested in innovation and really anxious to learn and we were addressed by this lady Mary Lou Jepsen extraordinary lady who has created and is about to go on the market something which is one million times more effective than that MRI that I've shown it's a fabric, it could be the dress that she's wearing another example of perhaps doing more with less and again the computer which we take for granted in the 40s it was occupying a mega room then there was enormous breakthrough it's actually mobile on four wheels a few decades later we now take for granted it's something we can put in our briefcase and if you look at all these things around the edge then some of them have become totally obsolete like the typewriter, it's an antique my kids have never seen a typewriter until I bought one for them and whether it's the camera, the torch the calculator being transformed by one hand held device so if we applied power I only recently discovered through some of the researches that we've been doing with MIT that in the 1960s and up there still are satellites which are nuclear powered miniaturised, this is something from a meeting that took place at MIT with a group and it's literally delivering power in a container if the hopeful future is fusion then fission in its new form notwithstanding all the prejudices against the power stations but it's a way of thinking it's interesting that when you talk to groups who can deliver power up to 20 megawatts in a container and you talk about the potential of maybe it's a box so it's not serving a community it's just below the surface and it's servicing a house it never ever occurs to them to question the grid because it comes as a prior assumption so a power station in everybody's mind has to be mega, it has to be the size or twice or three times the size of this building so autonomy is mentally something that is out there out in the Arctic or it's Canada it's somewhere in the wilds what if in parallel with that you were talking about and this is a serious project with MIT the idea that you can genetically modify to produce a tree which during the day harvest energy and at night it glows and it's street lighting so your street lighting is an avenue of trees what if you plant a seed to grow a building this is nature doing that and creating a bridge but what if you plant a seed in the sense that we are all grown from seeds like the trees so it leads to the manifesto which comes full circle back to Kent questioning power without grids sanitation without sewers meat without animals mobility without autos food without soil and buildings without construction the start of the conference, thank you


In this video I want to continue our discussion of linear regression to help us cement all the concepts and processes that we're going to need when we look at proper deep neural networks. So I hope you looked at some of the videos just describing the basic linear algebra, the basic video on derivatives and then the one who looked slightly deeper at gradient descent and have a good understanding of what is going on here. And remember these videos, the video series on deep learning is for people interested in healthcare solving problems with healthcare so I don't expect of you to have this deep understanding of mathematics or computer science. It is about using it to solve problems and I want you to be able to use deep neural networks to understand deep learning to solve these problems. So I've got another document here created with R Markdown in R Studio and it's published on R-Pubs. Remember that these files will be available on R-Pubs, they're available on GitHub. I'll talk about them on Twitter and on LinkedIn. So follow me on YouTube, subscribe to me at least on YouTube, follow me on Twitter, connect with me on LinkedIn, have a look at these R-Pubs pages and also GitHub. All the links will be everywhere. I want everyone to have access to this. So let's move down. We can use multi-variable linear regression. So whereas before, all we had was a single feature variable predicting a target variable, we are now going to have three feature variables predicting a target variable.  So we're going to have very poor prediction of the target value, just four columns and just random values and we can still build a model from that. So I've imported it here in R, don't worry about it, it's not what this is about. Let's just remind ourselves of where we are. We've now got these three unknowns.  They might three feature variables and there will be multiple rows of data describing these patients. If they are patients, for instance, we can see they're 10-year in actual fact and we have a target variable Y. So we need these parameters, beta sub 0, beta sub 1, sub 2 and beta sub 3, so that we can create this. I'm going to take beta sub 0 remember plus beta sub 1 times X sub 1, beta sub 2, that should say 2, X sub 2 and beta sub 3, X sub 3 and that's going to give me roughly Y. Now we say this roughly Y because what it actually gives me remember is Y hat with a little hat on top and that's going to be different from the actual Y and that's why these squiggly lines means approximately equal to. So that's still going to give me a loss function. You'll see this notation written elsewhere where there's a superscript I and the superscript I just means every sample. So that first row will be the I1, the second row would be I2, the third row would be I3. It just means the loss function here was going to be this addition of all these things multiplied by each other. So in this first one it will be beta sub 1 times 20.1, beta sub 2 times 39.3 and beta sub 3 times 1.3 add to that beta sub 0 and that's going to give me a value Y hat for that Ith row, that first row and from that I subtract the actual ground truth value which in this first instance was going to be 394 and I square that and that's my loss function. And I can add up and divide by how many there are so that I eventually get this average of all the loss and call that specifically my cost function. So that'll be a long equation. Remember previously through algebra we just condensed that to a simple one but it's still going to have beta sub 0, beta sub 1, beta sub 2, beta sub 3's in there and I have to solve for those to give me the lowest possible cost function.  This is how I imported it. I saved it in this computer variable this object called DF and I can cheat a little bit and it gives me these values. It says beta sub 0 should be there, 342.7, beta sub 1 should be there, there's beta sub 2 and there's beta sub 3 and you've seen, see I've written it here, those are the values that it should take. Note though that if I look at the multiple R squared it's only 0.016, very poor model and as I said those values were randomly just created so we expected they'll be poor so don't worry about that too much. What I want to show you is just this because that's the idea, the aim of this video lecture. We've got to get used to this little diagram that we've drawn here because I've taken this multi-variable linear regression and I have represented it in this way. If I scroll down I'm going to decrease the size just a little bit so it all should fit in the same page. There we go, almost there, bear with me, let's go, let's go, there it's better. There we go. Here I have what is called an input layer, x sub 1, x sub 2 and x sub 3 so I'm actually turning this on its side whereas if I look at, let's go back up, there's x sub 1, x sub 2 and x sub 3, they lie horizontally for the first patient, there they are, I'm turning that on its side so x sub 1, that 20.1 and then the 39.3 and the 1.3, they are now this way along and that's called my input layer so I can put those three values in there and you can see they each connected to this layer here and it's called a hidden layer, a hidden layer of nodes, see the three nodes and we see I've put a little tooltip there, it's multiply and there's my beta 1, beta 2 and beta 3 so I'm going, these are called, in deep neural networks these are called weights so I'm going to take each input value and multiply it by its weight, each input value multiplied by its weight, this input value multiplied by its weight and that gives me the values in the three nodes of the hidden layer and they each only have a single connection with the input layer, later on we're going to see it gets much more hectic than this. So I have this beta sub 1, x sub 1, beta sub 2, x sub 2, beta sub 3, x sub 3 in this layer here and then I add all of these three, remember it was this one plus this one and I add beta 0 and that gives me this y hat and there we have sort of a neural network, we have an input layer, we have a hidden layer here and we have an output layer and that is exactly how we construct deep neural networks, we're going to have many more hidden layers, one layer after another, we're going to call each of these a node but we can also see them as a little neuron, a brain cell that's connected to all sorts of other brain cells but we're just going to add on adding these layers and that's a deep neural network, here we just have this single hidden layer. Now so much so that if I plug in those, the first patient that was 20.139.3, 1.3 I multiplied by the weights that we stole from our linear model, it gives me these interim values in my hidden layer and I've got my bias node there, I add all of these and that one and I get 241.7 which is my predicted but the actual one was 394.5 so quite a bit of difference but I told you through that adjusted R squared this is going to be a bad model but anyway I think this should give you a meaningful deep understanding of what a network, a neural network is all about, we're going to have this layer of our input values, one for each row in our data, we put them there, we're going to have these hidden layers and we calculate their values by multiplying the input times this weight and we'll see later on we can add a bias right here and add a bias even into this, don't worry about that, for now we have these layers and then they pass to some output layer and that output layer can calculate a value for us or a state even depending on what our problem is. That is the basic structure of a neural network and you know now that this was forward propagation, we call this forward propagation to get to this and now through gradient descent we're going to go backwards in the opposite direction doing back propagation whereby we update these values of our weights, we update them to better values as you saw in the previous video and I hope you watched the previous video in this playlist whereby we update those, now we have new values for beta sub 0, beta sub 1, 2 and 3 and we can go forward again, get a new value, update that back and forth, back and forth. Initially these three values that we have here when we do proper deep neural, create a proper deep neural network we're just going to take stabs in the dark at these, we'll just ask the computer to generate random numbers so that we start somewhere on our gradient descent graph, we have some point where we can stand and we start to look at how we can go downhill so our cost function can be as low as possible and it will run backwards and forwards, backwards and forwards, forward propagation, back propagation, forward propagation, back propagation, updating those weights every time through this process of gradient descent until we get them as good as possible so that the cost function is at its minimum, the slope is going to get to zero that's how we know it's going to approach zero at least and that's where we know we've got the best value for these weights so I really hope this has been a good introduction for you that you have this a deep understanding of what neural networks are all about and we used a very simple thing like linear regression to do all of this for us. If you come across this video and this is the first one you find please go back, I always create my playlist so one follows the other when you look at our pubs there'll be a series of these these notebooks, these markdown files, so please do them in order so that you know which one follows the next. I am a surgeon that means I'm a clinician but I'm very interested in deep learning and I want everyone to be interested in it because it is going to be used to solve so many problems as it already has for us as human beings. Get everyone involved in deep learning, I maintain my argument that it's time for clinicians and those involved in healthcare to learn about deep learning and we should not just leave it to our colleagues in mathematics and computer science to do this, we should get on board as well. I'll speak to you again.


On today's Visual Studio Toolbox, Burke is going to show us how you can get access to your Visual Studio Code Dev environment from wherever you are. Hi, welcome to Visual Studio Toolbox. I'm your host Robert Green, and joining me today is Burke Holland. Hey, Burke. Hey, Robert. How are you? I'm good. Welcome to the show. Thank you so much for having me. I appreciate it.  That is correct. What does that mean? Well, it means that I go to conferences, and I write blog posts, and I wear shirts with oversized cassette tapes on them, very retro, but mostly I focus on JavaScript and just making the experience for JavaScript developers in Azure better. Okay, cool. Just how can we make it better? Cool. Today, you are going to show us something called Visual Studio Online. That is correct. Which was recently announced? Yes, it's quite new. Yes. So, this is very inside. I said when I saw that, oh, we should do an episode on that, and here we are doing an episode that's going to show that. Right, lucky you. Here we are. All right. So, what is it? Good question. Why is it? Let's answer that question first. So, you've got your editor, you have your machine, you get your whole development environment set up, and that takes a lot of work. People take put a lot of time, love and tenderness into their development environments, and they're very particular about their machines. You can't just run it on any machine, it needs to have enough power, it has to have enough beef in order to get the job done. Right. So, the problem then becomes that your machine is the only place where you can code, literally the only place. So, if you don't have it when you go home and you need to get back online, you may end up like, remoting into some VM somewhere via remote desktop. Exactly. You have two machines but they're never in sync. Exactly. Or you have a machine that's underpowered. So, you get to the point where you actually can't run something anymore because the machine's underpowered, that's the one that you've got. You can always spin up an Azure VM. That is true. You could spin up a VM, or you could use VS online, which is what we're going to do today. Cool. So, let's take a look at that. I'm going to pop over to the browser here. So, everything that we're going to do today is going to be done inside of the browser. There's an experience for this where you can use Visual Studio Code and have the same experience, but you can also just be in a browser. Cool. That's pretty cool. So, the first thing we need to do is create an environment. This is where you're actually selecting that VM. If you were going to make a VM. Weren't signed in, there'd be a place here to sign in with your Microsoft account that's tied to your Azure subscription, or your Azure DevOps, etc. That's correct. I have spared you the tedious details of watching you log in and type my password wrong multiple times. But if you've ever logged into Azure or logged into Azure DevOps, you've logged into Visual Studio online as the same person. That is correct. Yes. That is right. Tied at the same account. All right. Then you're going to put in the Git repository where your code is, and you can do the URL, but you can actually just do the repo name, and then like this. So, this is the repo that we're going to clone from GitHub into our new environment. In the instance type here, you can see that I'm pulling in, I've got a standard Linux box here with four cores and eight gigabytes of RAM, and I can change that. I could get more if I wanted. I can go up to 16 gigs, or I can look at some pricing information. You have to be Linux? Let's see here. Apparently, at the moment, it does. Okay. Then this suspend idle environment, what this does is after a certain amount of time, it just puts the environment to sleep, so that you're not being charged for it actually running, because you do get billed as it runs in addition to the fact that it actually exists. Okay. So, we're going to just leave it at 30 minutes here. Then one thing that we could do here is we could pull in dot files. Dot files? Right. Now, if you're not familiar with dot files, it's a very Linux-specific piece of terminology, but in a Linux Bash shell, you can customize the Bash shell, you can customize the prompt, you can put in shortcuts, you can put in what they call aliases, so you can just type a command and then something more elaborate happens. We store that in what's called a dot file, and it's literally dot something configuration file. So, usually dot ZSHRC or dot BashRC. Then what people do frequently is they'll put those in a GitHub repository so that they can then pull them down whenever they set up a new machine. So, what we have the opportunity to do here is pull in dot files to configure the Linux box that's being created in Azure. We're not going to do that though, we're just going to go ahead and create this environment here. So, this is going to create this machine, it's going to spin it up in an Azure data center here in East US, and you can see here it's creating. So, that's what's happening right now is this VM's actually being spun up for us in the cloud. Now- So, the fact that it's a Linux machine obviously says this, you can do dotnet core stuff here, you can do JavaScript stuff here, you can do anything that you can do in Linux, but you can't do Windows-only stuff, presumably. I don't know what the availability of Windows is, but I would imagine somebody from the, good question for the VS online team, but for this demo we've only got access to Linux. All right. Keep in mind that we are still in preview here. Got it. And so, for easy environment, normally you would have your environment already set up so you'd go back in, right? But we've created this, so let's just go ahead and go into the environment here. So, I'm just going to click on it. And what you're going to see is something that looks awfully familiar. That looks like Visual Studio Code. It does. It looks a lot like Visual Studio Code, doesn't it? Right there in the browser. I assume there's some shared code going on. There is. There is. So, for those who don't know, Visual Studio Code is actually built with TypeScript. And so, a lot of the code that actually runs the native platform can be used to build a web client because TypeScript is just JavaScript. Right. Right, it's a very flexible editor. So, now we've got it running inside of VS code here and let's just pull up the readme file and all of our keyboard shortcuts still work. So, I'm just going to do control shift V to get a preview of this readme file. So, now I'm previewing the readme file right from within VS code. And we can pull up a terminal. So, let's just do that. So, I'm going to pull up a bash terminal here. So, this is our full bash terminal. So, now we're actually on the Linux box with the terminal open. Right. And any commands are good, right? So, we can run an LS command, any of your Linux commands you'll find here. So, you can traverse the file system of this machine as if it was an actual machine. Cool. Now, notice here that we have a node modules folder. So, I'm just going to expand that. Now, that folder isn't in the repo. Okay, so when we cloned it, there's a package.json file and VS online is smart enough to look at that and say, oh, there's dependencies in this project. I'm just going to go ahead and install those for you. So, by the time you open the environment, they're already there. Which is just one less step that you have to do. Yeah, it's pretty neat. Now, in JavaScript, we don't have, you may know this, we don't have a compiler. Right. There's no compiler for JavaScript. And so, we don't know at design time when we're actually writing the code, whether or not there are any errors in the code. We just sort of throw it up and pray that it works. And so, we have some tools to help us do that. You know, TypeScript has a transpiler that will do that. In this case, we're just using JavaScript, but we have ESLint in here as well. And so, VS code, because we have this ESLint rc.json file over here, VS online looks at that and says, oh, you want me to what's called Lint your JavaScript, but just basically check it for errors. Right. And that's what it's doing right here. So, it's automatically running ESLint on our code and showing us that we've got some errors or some warnings here. So, we can see these. I'm going to press Control, Shift, M. That's just going to show us the different errors that we've got. And these are all warnings. This code will still work, but it's actually better not to use var anymore. We want to use let or const are the new variable types. Good to know. So, we can fix this. Let's just highlight this line. I'll just do control period and that will give me some options on how to fix this. So, notice all of the keyboard shortcuts that I would use in VS code just work inside of the browser like you would expect them to. So, I'm going to fix this no var problem and it will do that. Now, I could go and do that for the rest of them or we can just go down and say, fix them all. We'll fix all our no var problems and now we know more problems detected. Yeah, pretty neat. So, now the next thing we need to do is because we are developing, this is a little web server. It basically just says hello world, which you can see here, sets the port, sets the host, says hello world. And then it's going to run this little server so that we can serve up some content. So, the next thing we want to do is actually run this. So, let's do that. I'm going to come over here. A couple ways to do this. We could just press F5, but we can also open up the debug bar and just go ahead and launch it. And you'll see that we've launched and you can see that it's running on localhost 3000. What's even more interesting is that if I put a break point here. Running on localhost 3000 locally? It doesn't make any sense, does it? Localhost 3000 on the machine this is running on. Doesn't make any sense, does it? Bear with me. We're going to talk about that. So, I'm going to restart this. Because first I want to show you that we can actually hit break points in here. So, we've hit a break point and we can examine and see that host is localhost, which you caught, and port is 3000. So, this thing is running on localhost 3000. So, let's go ahead and continue on. So, that's where it's running. All right, so let's access localhost 3000. Because we can do that. So, let's just come over here to a browser tab. And you know what? I'm in a browser. I totally forgot I was. Did you see me just go looking for the browser? Yeah. That's crazy. So, let's open a new tab. Let's go to localhost 3000. And that's going to work, right? That's the question. That's the question on everybody's list. Oh! It's not going to work. Now, why doesn't that work? Because this code is running on a server somewhere and up in Azure. Right, and this is the problem. And how do we as developers effectively develop in an environment that's not local? We need to be able to run things on localhost. All right, so here's how we handle that. Visual Studio Online. So, let me come back over here to this tab. And we have this little remote explorer that's automatically there when you pull up VS Online. And you can see down here in our environment details, you see this section where it says forwarded ports. So, what we're going to do is we're going to forward a port. And we're going to forward port 3000 because that's the port that this app is running on. Hit enter. And it wants to know, just you can give this a nifty name. This is just how it shows up in the sidebar here. So, we'll say enter on that. And now, it's running on localhost 3000. Now, we can't access it on localhost 3000 though because, again, that's not our machine. But if we click on it over here on the side, what it does is it opens and you can see it's connecting to the forwarded port and wait for it, boom, there's our application. Because I was going, if it was running locally and the server was pushing stuff down that raises all kinds of firewall issues and blah, blah, blah, it's a much better. Correct, right. So, now basically getting to localhost 3000 on the machine this is running on without having to care what it's literally called. Correct, because you really don't care that the URL is localhost. You just wanna be able to access the Dev environment. So, let's check this out. Let's go in and make, let's make a change here. So, we'll just say hello, VS Toolbox. And then, let's go ahead and save that. And I'm gonna restart the debugger. And you can see it's awful fast. That's because we are running on a pretty beefy machine. And then, let's just stick a break point in here. Let's come back over to our localhost here. Refresh, and you'll notice that this is just gonna kind of spin and spin and spin. And that's because we have hit the break point inside of Visual Studio Online. So, what's really cool about this is- How many times does that happen to you? You set a break point and then you go to the browser just spins and spins and spins. Actually, actually multiple times. Remind yourself. Right, I can see a feature we add where the tab flashes or something to show you. That hasn't happened to me since this morning. Right, exactly. Like, why is this not responding? Oh, I set a break point. Well, a lot of times in native apps it forwards the application. Like I know in VS Code, if you break, it will bring VS Code to the front to show you that. In a browser, it's a little bit different. Yeah, so we're broken in here. We can debug, do any debugging we need to do. Step over, step out, continue on. It's basically like a local development environment. But inside of your browser. So, a couple of questions. I assume, so what version of Visual Studio Code is this? How does it relate to the one that I actually have on my machine? And can I install all of my same extensions? And can I save the environment? Yeah, that's a great question. So, let's see here. Let me go to settings here. So, the answer is, is this the same version as VS Code that's running on your desktop? No, it's not. It looks like VS Code in the browser, but it is not the same thing that's running on the desktop. But it's probably pretty darn similar. It's very similar. So, all of the settings are gonna be there. Most of the things that you would do, tweaks that you would provide in settings like themes and things like this, you can totally add in. You can add your extensions. You can add extensions, not all extensions are supported at the moment, but many extensions are. And then you can save the environment. You can, you can save the environment, goes into the .VS Code file like you normally would. So, if you were working locally and you have that .VS Code folder with the settings.json, put your settings in there, put it in GitHub, pull it into VS Online, and it will automatically pick up those settings. Awesome. And then you can check things into source control. So, right, you're working off a repo. That's correct. So, you have source control.  Correct. So, you can imagine that you have access to a computer. Maybe it's not even a very beefy computer, but it doesn't matter. And when you pull up your environment, it's already pre-configured. It already looks like your VS Code. It's as if you launched your own VS Code installation from your own machine, but from within the browser. Does it work on your phone? Haven't tried it. That would be interesting. Not supported. Cool. That's awesome. So, for other questions, I know there's good docs about it. People can go and read up more about this, particularly about pricing, et cetera. I saw that there were some pricing plans. Yes, absolutely. There's good docs on this. There was a talk and an announcement from Ignite that people can check out. So, we can go ahead and link to that. We'll link to that. Yeah, that would be a good one to check out as well. Cool. This is awesome stuff. All right. Thanks for having me. Appreciate it. Hope you enjoyed that, and we will see you next time on Visual Studio Toolbox.


The state is out of control. So I don't want to lose the big picture now. The early 1980s start, late 70s end, with a crisis in American capitalism. One strategy to deal with a crisis is to get the capitalists to increase their distributions of surplus to capital accumulation, give them more surplus in the ways that I described by reducing the value of labor power. That worked. That was enormously successful. American capitalism begins to recover, employment grows, and so forth. The crisis of capitalism, which is solved, is displaced upon the state because the state absorbs this strategy of cutting taxes, increasing defense expenditures, and other kinds of expenditures. And you get the struggle here between Republicans and Democrats over these public goods right up to the present. So the deficits rise. And one consequence of the deficit is that if the state starts to issue more and more bonds to finance this deficit, then you're not supplying it to me. And the price of bonds start to fall. Interest rates start to rise in the United States. Then the very rise in interest rates will choke off if it continues. It can contribute to a choking off of the recovery. We did this in 305 because now you have a subsumed class payment on the part of industrial capitalists which will rise, which is rising interest rates paid to the bankers for the capitalists getting access to loans to expand their businesses, to buy other companies, and so forth. And that expansion in interest can constrain the recovery. Also, in workers who are in debt to purchase their homes, to finance the college education for their kids, for their automobiles, for their household appliances, typically, as we have said, go into debt to maintain their consumption with their cut in wages, well, those individuals are facing then higher interest payments on that debt. And that too is going to constrain their expenditures in a different way, but too constrain it just like the industrial capitalist. Hence, you've got the possibility of a recession rooming because of the very rise in interest rates, because of the rise in deficit, because of the cut in taxes and the increase in expenditures by the state that helps solve the capitalist problem. It's a little bit out of control, isn't it? The solution to capitalism creates then this danger to capitalism. And hence, the Fed would have to step in if they're going to maintain low interest rates, which in turn has all of its repercussions on the US economy, including the risk of inflation. The second one, besides the state being out of control, is this crisis also gets displaced onto households across the United States. And I'm going to end on that note. What goes on inside households? Well, a variety of different laboring occurs inside households, as you all know. Food preparing, and cooking, and cleaning, and child rearing, and bookkeeping, and education of children, and repairing of goods and services, nurturing, and so forth, et cetera, as well as sleeping, and a variety of other labor processes occur. Within households, many of these labor processes and the household wealth that they produce have historically been the province of women that is changing in a variety of countries, including the US, but historically, including during this period of time. More or less, they are produced inside the household by women. So women spend time inside the household doing these labor process, but now let's make use of this course. They also engage in a class process inside the household, which is they spend time producing meals for themselves, but then they spend some extra time producing meals for their spouse or partner. They spend time cleaning the house for themselves. That's their necessary labor. But then they spend labor above and beyond that, an extra labor, a surplus labor, cleaning the house for their spouse or partner. So in other words, women are doing necessary and surplus labor within the household. And then we actually now have numbers on that. The Bureau of Labor Statistics has a household survey. And women spend 40 hours, and some people, when they do estimates, even more, 40 hours for seven days a week doing this kind of labor, which includes this necessary and surplus labor, very similar to what we did weeks ago in this course when we presented it. Increasingly, women enter the labor force. Recall, to supplement the diminished real wage of their male partner, women enter the labor force selling their labor power, which they always had done, but it was especially in times of war in the States. But now increasingly, women took not just part-time jobs, but full-time jobs outside the household to, in part, to supplement the reduced real wage of their partner. Now I keep emphasizing, in part, because I don't want to reduce this just to economics. There were also important cultural and political changes in the United States, which pushed women out of the labor force, not the least of which was the women's liberation movement in the 1960s and the long struggle of women for rights even before the turn of the last century onward. So we had political and cultural and these economic changes, women enter the labor force, but they're entering the labor force. They're now selling their labor power outside the home while many of them, according to the Bureau of Labor Statistics, continue to do necessary and surplus labor inside the household. So what we have for, I would guess, the majority, vast majority of households in the United States, we have women doing necessary labor and surplus labor inside households. They continue to do that. So they continue to hold that job inside the household, producing all kinds of household wealth to maintain themselves, their children, and their husbands. At the same time, they're doing necessary labor and surplus labor outside the household. Again, because of what capitalism has brought, as well as these other cultural and political changes that I mentioned, but at least capitalism also, in part, pushes them to sell their labor power outside the household. Well, let's assume that it takes, I don't know, let's say eight hours a day to sleep and to maintain your body. That is what I have in mind here is you need so many hours to sleep, to refresh your body. You need so many hours to wash and to eat and so forth, et cetera. Let's just, you know, not preparing the meal, but just actually sitting down and eating it. So let's assume that that's eight. So I have 24 minus eight, there's 16 hours available. If this is eight hours over here inside the household, if this is eight hours outside the household, my God, there's no hours left. That is, the free time, I'll call it R, the residual, the free time, would you be time what?  That free time, in effect, gets constrained because women have to go outside the household to sell their labor power to supplement their husband's declining real wage. And so what we have in the United States is literally an impossibility. The solution to the capitalist crisis, it not only gets displaced upon the state and a crisis emerges there, but you get a crisis across households in the United States. The families suffer severe strains because everybody in the family is working. And hence, when husband and wife come home from a full day outside the household to a place inside the household in which traditionally she was the preparer of these meals and washing for him, she doesn't literally have enough time to do all this. This is completely squeezed. She begins to cut into her sleep time to make more time available here. He wants his surplus in the form of meals and washing and so forth, et cetera. And it becomes even more important because his real wage is being cut so the household becomes an even more important place of consumer goods for him to offset the constrained consumption out of the household. Well, you got a recipe for a disaster here. As he puts pressure on her to continue to produce surplus, and as she says, look at, I mean, what do you want from me? I'm working a full-time amount here. I don't have any time for myself, okay? And you want me now to add even more hours producing this stuff. You get increased tension and if not violence within the household. So what we have is, and I'm not reducing it again, I'm arguing here the stress and strains of the household over-determined the breakup of households, the divorce rate in the United States. I'm not reducing that to obviously economics. But all I'm arguing here is that the capitalism outside the household has an impact on what goes on inside the household as well as what goes on inside the state. And so what you have across the United States is a frustration and anger and an upset emerging from capitalism itself. But no one or very few people explain to the individuals that their problems there at home, their problems at the job, their debt that they're in and so forth is connected to the class structure of the United States. So that is one of the important messages of economics 305. I hope you have enjoyed this course and I hope you continue to read and the Marxian literature. Thank you very much. This is Professor Resnick.