<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>vetta project</title>
	<atom:link href="http://www.vetta.org/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.vetta.org</link>
	<description></description>
	<lastBuildDate>Sun, 02 Dec 2012 11:38:20 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4.2</generator>
		<item>
		<title>Neil Armstrong</title>
		<link>http://www.vetta.org/2012/08/neil-armstrong/</link>
		<comments>http://www.vetta.org/2012/08/neil-armstrong/#comments</comments>
		<pubDate>Tue, 28 Aug 2012 14:31:24 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1083</guid>
		<description><![CDATA[&#8220;I am, and ever will be, a white-socks, pocket-protector, nerdy engineer&#8221; &#8212; Neil Armstrong, 2000 On the topic of space, I thought this video from the ISS was spectacular.  Flying over the aurora borealis is just magic.]]></description>
			<content:encoded><![CDATA[<blockquote>
<p style="text-align: left;">&#8220;I am, and ever will be, a white-socks, pocket-protector, nerdy engineer&#8221;</p>
<p style="text-align: right;"><span style="text-align: right;">&#8212; Neil Armstrong, 2000</span></p>
</blockquote>
<p>On the topic of space, I thought <a href="http://vimeo.com/45878034">this video</a> from the ISS was spectacular.  Flying over the aurora borealis is just magic.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2012/08/neil-armstrong/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Goodbye 2011, hello 2012</title>
		<link>http://www.vetta.org/2011/12/goodbye-2011-hello-2012/</link>
		<comments>http://www.vetta.org/2011/12/goodbye-2011-hello-2012/#comments</comments>
		<pubDate>Sat, 31 Dec 2011 01:49:13 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1068</guid>
		<description><![CDATA[I&#8217;ve decided to once again leave my prediction for when human level AGI will arrive unchanged.  That is, I give it a log-normal distribution with a mean of 2028 and a mode of 2025, under the assumption that nothing crazy &#8230; <a href="http://www.vetta.org/2011/12/goodbye-2011-hello-2012/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve decided to once again leave my prediction for when human level AGI will arrive unchanged.  That is, I give it a log-normal distribution with a mean of 2028 and a mode of 2025, under the assumption that nothing crazy happens like a nuclear war.  I&#8217;d also like to add to this prediction that I expect to see an impressive proto-AGI within the next 8 years.  By this I mean a system with basic vision, basic sound processing, basic movement control, and basic language abilities, with all of these things being essentially learnt rather than preprogrammed.  It will also be able to solve a range of simple problems, including novel ones.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2011/12/goodbye-2011-hello-2012/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>AIQ</title>
		<link>http://www.vetta.org/2011/11/aiq/</link>
		<comments>http://www.vetta.org/2011/11/aiq/#comments</comments>
		<pubDate>Wed, 16 Nov 2011 12:28:42 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1058</guid>
		<description><![CDATA[Some of you might remember the talk I gave at the 2010 Singularity Summit about Algorithmic IQ, or AIQ for short.  It was an attempt to convert the theoretical Universal Intelligence Measure into a working practical test of machine intelligence. &#8230; <a href="http://www.vetta.org/2011/11/aiq/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Some of you might remember <a title="AIQ Talk" href="http://vimeo.com/17553536" target="_blank">the talk I gave</a> at the 2010 Singularity Summit about Algorithmic IQ, or AIQ for short.  It was an attempt to convert the theoretical <a title="Universal Intelligence Measure" href="http://www.vetta.org/documents/UniversalIntelligence.pdf" target="_blank">Universal Intelligence Measure</a> into a working practical test of machine intelligence.  The results were preliminary, but it seemed to work&#8230;</p>
<p>It&#8217;s now over a year later so I guess some of you are wondering what happened to AIQ! I&#8217;ve been very busy working on other cool stuff, however Joel Veness and I have been tinkering with AIQ in our spare time.  We&#8217;re pleased to report that it has continued to perform well, surprising well in fact.  There was some trickiness to do with getting it to work efficiently, but that aside, it worked perfectly straight out of the box.</p>
<p>We recently wrote a paper on AIQ that was accepted to the Solomonoff Memorial Conference.  You can get the <a title="AIQ Paper" href="http://www.vetta.org/documents/AIQ.pdf" target="_blank">paper here</a>, the <a title="AIQ Talk" href="http://www.vetta.org/documents/AIQ_Talk.pdf" target="_blank">talk slides here</a>, and we have also released all the Python AIQ <a title="AIQ Source Code" href="https://github.com/mathemajician/AIQ" target="_blank">source code here</a>.  It&#8217;s designed to be easy to plug in your own agents, or other reference machines, if you fancy having a go at that too.</p>
<p>If you&#8217;re not sure you want read any of that, here&#8217;s the summary:</p>
<p>We implemented the simple BF reference machine and extended it in the obvious ways to compute RL environments.  We then sampled random BF programs to compute the environments, and tested against each of these.  This can be a bit slow, so we used variance reduction techniques to speed things up.  We then implemented a number agents.  Firstly, MC-AIXI, a model based RL agent that can learn to play simple games such as TicTacToe, Kuhn poker and PacMan, but is rather slow to learn.  Then HLQ(lambda), a tabular RL agent similar to Q learning but with an automatic learning rate.  Then Q(lambda), a standard RL agent, and Q(0), a weaker special case. Finally, Freq, a simple agent that just does the more rewarding action most of the time, occasionally trying a random action.  There was also a random agent, but that always got an AIQ of zero, as expected.  The results appear below, across various episode lengths:</p>
<p style="text-align: left;"><img class="aligncenter" title="AIQ BF5 graph" src="http://www.vetta.org/images/BF5_alt.png" alt="" width="650" height="490" />The error bars are 95% confidence intervals for the estimates of the mean.  As you can see, AIQ orders the agents exactly we would expect, including picking up the fact the MC-AIXI, while quite powerful compared to the other agents, is also rather slow to learn and thus needs longer episode lengths.  We ran additional tests where we scaled the size of the context used by MC-AIXI, and the amount of search effort used, and in both cases the AIQ score scaled sensibly.  See the talk slides for more details, or the paper itself.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2011/11/aiq/feed/</wfw:commentRss>
		<slash:comments>30</slash:comments>
		</item>
		<item>
		<title>Sutton on human level AI</title>
		<link>http://www.vetta.org/2011/05/sutton-on-human-level-ai/</link>
		<comments>http://www.vetta.org/2011/05/sutton-on-human-level-ai/#comments</comments>
		<pubDate>Mon, 09 May 2011 22:28:47 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1034</guid>
		<description><![CDATA[Prof. Rich Sutton, probably the most famous person in the field of reinforcement learning, gave a talk today at the Gatsby Unit.  I was expecting a standard introduction to reinforcement learning to begin with, but it wasn&#8217;t to be.  Instead &#8230; <a href="http://www.vetta.org/2011/05/sutton-on-human-level-ai/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Prof. Rich Sutton, probably the most famous person in the field of reinforcement learning, gave a talk today at the Gatsby Unit.  I was expecting a standard introduction to reinforcement learning to begin with, but it wasn&#8217;t to be.  Instead he kicked off with 20 minutes about the singularity.</p>
<p>Audience: <em>So when do you expect human level AI?</em></p>
<p>Rich: <em>Roughly 2030.</em></p>
<p>Whether or not you agree, views like this seem to be becoming more common in academia.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2011/05/sutton-on-human-level-ai/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>Technological themes</title>
		<link>http://www.vetta.org/2011/01/technological-themes/</link>
		<comments>http://www.vetta.org/2011/01/technological-themes/#comments</comments>
		<pubDate>Mon, 31 Jan 2011 12:12:55 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1020</guid>
		<description><![CDATA[Looking over my predictions for the teenies from a year ago, they already look pretty lame. Take 1/3 off USA&#8217;s PPP GDP and you already get China, the latest Sony portable device has a 4 core processor, Intel&#8217;s latest set &#8230; <a href="http://www.vetta.org/2011/01/technological-themes/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Looking over my predictions for the teenies from a year ago, they already look pretty lame.  Take 1/3 off USA&#8217;s PPP GDP and you already get China, the latest Sony portable device has a 4 core processor, Intel&#8217;s latest set of CPUs are once again pretty awesome, schemes to let you pay for stuff with your phone are already getting under way (via both screen bar codes and near field communication), and a graphics card review I read the other day noted that the most graphically demanding games on high resolution monitors with all the graphical bells and whistles switched on now run very well on the latest &#8220;mid range&#8221; graphics cards.</p>
<p>At the time that I made my teenies predictions I thought they seemed a bit like predicting the obvious.  But I&#8217;m now starting to wonder whether many of my predictions could have been more tightly assigned to the following 3-4 years, rather than the next decade.</p>
<p>One thing I&#8217;ve noted in the past is that it&#8217;s usually easier to predict fundamental things like FLOPS per dollar than is it to predict how these technological fundamentals will translate into applications.  That might be true, but knowing that your computer of five years hence will have X bytes of storage and perform Y computations per second is a bit abstract for most purposes.  What will be the new toys, the new applications, the new businesses?  These are the things that impact people.</p>
<p>If predicting specific applications is a bit much to ask for (and if I could I might not want to tell you!), perhaps the next best is to predict the general nature of applications during a period of time.  What you might call the &#8220;technological theme&#8221; of a period.  </p>
<p>1980 to about 1995 was the period of the PC.   Starting with hobbyists and niche applications and spreading to take over a large chunk of the office.  The IBM PC marked the point at which this went mainstream.  The defining characteristic was that the communication was typically local, if the machines were networked at all.  </p>
<p>1995 to about 2010 was the period of the internet.  First emails and basic web pages, search, then ordering online, online banking, music, video, etc.  Netscape marked the point at which this went mainstream.  The defining characteristic was that the communication was now global but the interface with the world was usually pretty traditional: keyboard, mouse, monitor.</p>
<p>So what&#8217;s the next theme?  Mobile internet might be an answer, but I think that it&#8217;s more general than that.  As great as the internet is, most of the important stuff still occurs in that other place called reality.  Maybe it&#8217;s a new house with a swimming pool, throwing a party with friends or coming down with a serious illness.  I think the next theme will be for technology to interface more effectively with the world, being mobile is only one aspect of that.  If I had to pin the start of this going mainstream on one thing, it&#8217;d say it was the iPhone as that&#8217;s when the internet started to show up in the day to day moments of people&#8217;s lives as they&#8217;re out and about doing things.  </p>
<p>Once the location, state and function of many everyday objects starts to spread onto the internet, all sorts of creative efficiencies become possible.  Need to pay for the coffee?  Just press a button on your phone.  Not sure where your car is?  Ask your phone to show you the way.  Need a cab or a pizza or&#8230; just select what you want on some menus on your phone.  Prices, special deals, time you&#8217;ll need to wait &#8212; it will all be there.  Need to keep a close eye on your health?  Get a small sensor implanted that monitors your blood insulin, oxygenation, pressure, cholesterol, heart rate and so on and wirelessly updates this information to your phone.  Should a problem arise, your phone can let medics know where you are and what the problem seems to be.</p>
<p>I don&#8217;t expect this to be a sudden change, but rather a gradual absorption of goods, services and various everyday objects into an all pervasive information network.  I think this will be a hot area until about 2025.  Yeah, it&#8217;s going to take a while, not so much for many of these things to become possible, but rather for them to become cheap enough to be economic.</p>
<p>What&#8217;s my pick for the theme that comes after that?  Well, once you have so much of the economy automated and hooked up together with vast amount of information about anything and everything swirling around, the key leverage point becomes how well you can intelligently process all this in order to control and coordinate things.  Thus my pick for the theme from 2025 to 2040 is machine intelligence.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2011/01/technological-themes/feed/</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>Goodbye 2010</title>
		<link>http://www.vetta.org/2010/12/goodbye-2010/</link>
		<comments>http://www.vetta.org/2010/12/goodbye-2010/#comments</comments>
		<pubDate>Fri, 10 Dec 2010 18:04:39 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=1002</guid>
		<description><![CDATA[Well, well, another year is drawing to a close. That means it&#8217;s once again time to review what has happened and where things are going. It&#8217;s been a very eventful year for me, both personally and on the work front. &#8230; <a href="http://www.vetta.org/2010/12/goodbye-2010/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Well, well, another year is drawing to a close.  That means it&#8217;s once again time to review what has happened and where things are going.</p>
<p>It&#8217;s been a very eventful year for me, both personally and on the work front.  I keep my personal life off this blog, and as for work&#8230; um, significant things are happening but I&#8217;m not ready to talk about them yet  <img src='http://www.vetta.org/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />   Thus, I&#8217;ll just stick to my general predictions this time around.</p>
<p>First of all, my set of <a href="http://www.vetta.org/2009/12/the-teenies/">predictions for the teenies</a>.  We&#8217;re only 1 year in so it&#8217;s not surprising that I&#8217;m still pretty comfortable with the predictions I&#8217;ve made.  The only tweak I&#8217;ll make is that over the last year I&#8217;ve become slightly more confident that we&#8217;ll have a decent understanding of how cortex works before the end of the decade.  That&#8217;s my only update.</p>
<p>My longest running prediction, since 1999, has been the time until roughly human level AGI.   It&#8217;s been consistent since then, though <a href="http://www.vetta.org/2009/12/tick-tock-tick-tock-bing/">last year</a> I decided to clarify things a bit and put down an actual distribution and some parameters.  Basically, I gave it a log-normal distribution with a mean of 2028, and a mode of 2025.  Over the last year computer power has <a href="http://www.top500.org/lists/2010/11/performance_development">increased as expected</a>, and so it looks like we&#8217;re still on target to have supercomputers with 10^18 FLOPS around 2018.  In terms of neuroscience and machine learning, I think things are progressing well, maybe a little faster than I&#8217;d expected.  I was toying with the idea of moving the prediction very slightly closer, but decided to play it safe and keep the prediction unmoved at 2028.  With many people thinking I&#8217;m too optimistic, showing restraint is perhaps wise <img src='http://www.vetta.org/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />   I can always move my prediction nearer in a year or two.</p>
<p>One thing I screwed up last year was the 90% credibility region.  Going by a log-normal CDF  for my predicted mean and mode that David McFadzean did (see bottom of <a href="http://www.churchofvirus.org/bbs/index.php?board=5&#038;action=display&#038;threadid=42884&#038;start=0">this page</a>) the upper end should be a bit higher at 2045, i.e. at a CDF of 0.95.  It seems that I got the lower end right, however, as the CDF is about 0.05 at 2018.  With 5% at each end, that gives the 90% interval.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2010/12/goodbye-2010/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Summit 2010</title>
		<link>http://www.vetta.org/2010/08/summit-201/</link>
		<comments>http://www.vetta.org/2010/08/summit-201/#comments</comments>
		<pubDate>Mon, 23 Aug 2010 11:03:13 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=996</guid>
		<description><![CDATA[Another great Singularity Summit. I liked the focus on neuroscience this time. I think it will be a major driving force behind AGI over the next 20 years. The talk by Demis Hassabis is the one to look for in &#8230; <a href="http://www.vetta.org/2010/08/summit-201/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Another great Singularity Summit.  I liked the focus on neuroscience this time.  I think it will be a major driving force behind AGI over the next 20 years.  The talk by Demis Hassabis is the one to look for in this area, once they become available online.  My own talk was well received &#8212; I had applause during the talk as I put up results, something that I&#8217;ve certainly never experienced before.  Due to a manic schedule of meetings, deadlines and last minute results, I unfortunately didn&#8217;t get to spend much time socialising this year.  Hopefully things will be a bit more sane next time around and I&#8217;ll be able to catch up with everybody properly.  Looking forward to it already.</p>
<p>I don&#8217;t know if anybody has thought of a theme for next year&#8217;s conference yet, but I&#8217;d like to make a suggestion: ethics and AGI safety.  The conference has been around for a few years now and had attracted some fairly big names and serious academics.  How about a return to the core mission of SIAI?  As I think AGI is approaching, we seriously need much deeper and broader thinking on these topics.  One other suggestion: while big names draw the crowds, in my opinion they often give the least interesting talks.  How about a couple of the most popular and accessible LessWrong posts get selected and their authors present them as Summit talks?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2010/08/summit-201/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>Short film by Alex Roman</title>
		<link>http://www.vetta.org/2010/01/short-film-by-alex-roman/</link>
		<comments>http://www.vetta.org/2010/01/short-film-by-alex-roman/#comments</comments>
		<pubDate>Sat, 09 Jan 2010 16:34:26 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=894</guid>
		<description><![CDATA[This short film, The Third &#38; The Seventh, by Alex Roman, is a great example of cutting edge computer graphics.  The airy elegant style reminds me a bit of Kubrick.  I&#8217;m not sure what impressed me the most: the wonderful &#8230; <a href="http://www.vetta.org/2010/01/short-film-by-alex-roman/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://vimeo.com/7809605"><img class="aligncenter" src="http://www.vetta.org/VettaPics/third_and_seventh.jpg" alt="" width="500" height="282" /></a></p>
<p>This short film, <em>The Third &amp; The Seventh,</em> by Alex Roman, is a great example of cutting edge computer graphics.  The airy elegant style reminds me a bit of Kubrick.  I&#8217;m not sure what impressed me the most: the wonderful cinematography, the fact that it&#8217;s entirely computer generated, or that one guy did it alone in his spare time &#8212; including putting the sound track together.  Be sure to watch it full screen and in high definition.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2010/01/short-film-by-alex-roman/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>The Teenies</title>
		<link>http://www.vetta.org/2009/12/the-teenies/</link>
		<comments>http://www.vetta.org/2009/12/the-teenies/#comments</comments>
		<pubDate>Mon, 28 Dec 2009 22:01:58 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=873</guid>
		<description><![CDATA[I&#8217;ve decided to christen the next decade the teenies.  Firstly, I&#8217;ve still heard no other suggestions; secondly, it&#8217;s phonetically consistent with the noughties and the twenties; and thirdly, the name is so downright awfully bad it&#8217;s almost quite good.  So the &#8230; <a href="http://www.vetta.org/2009/12/the-teenies/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve decided to christen the next decade the <em>teenies</em>.  Firstly, I&#8217;ve still heard no other suggestions; secondly, it&#8217;s phonetically consistent with the <em>noughties</em> and the <em>twenties</em>; and thirdly, the name is so downright awfully bad it&#8217;s almost quite good.  So the teenies it is.</p>
<p>I&#8217;ve been scratching my head about these predictions for the last few days.  By and large, I feel like I&#8217;m just predicting the obvious &#8212; which is a bit of a let down.  However, when I look at the noughties, while the specific details were not predictable, the general trends were pretty obvious already in 2000.  So perhaps predicting the seemingly obvious is not such a bad idea.  And what seems obvious to me often is anything but obvious to others, indeed many will flatly disagree with my predictions.  So, here goes.  Hopefully these precitions are specific enough that I&#8217;ll be able to perform a decent analysis come 2020 to see how well I fared.</p>
<p>First up, things generally will become more energy efficient and we will see more solar power.  But overall not much will change in energy &#8212; we&#8217;ll keep on using oil and coal and pumping out lots of CO2.</p>
<p>Chinese GDP on a PPP basis will be roughly comparible to that of the US and the EU (i.e. within 25%).  India will be about half their size.  The UK and France won&#8217;t be in the top 10 countries anymore, though they will still like to think that they are.  China will become increasingly associated with luxury designer goods.</p>
<p>Computers will become about 50x faster, though I&#8217;m a bit nervous about this prediction.  Later in the decade we will have major trouble with silicon chip technology.  We might also see computer power overshoot general consumer demand which would spell serious trouble for the big chip manufactures.  Everything goes very multi-core, even your cell phone.  The graphics card market collapses due to them overshooting consumer demand* and possibly being subsumed by new CPUs.</p>
<p>All things internet and mobile will continue to grow.  Smart &#8220;phones&#8221; will become fully funcational computers.  You&#8217;ll be able to connect your smart phone to a large monitor, keyboard, mouse, projector etc., just like you&#8217;d do with a PC today.  It will even become your wallet as you&#8217;ll be able to use it to pay for things at the supermarket.  The expanding internet will swallow up most of TV and radio.  High definition video conferencing will become common, making distance collaboration significantly more natural.  High definition matters as it will allow people to have a wider field of view and to more clearly see facial expressions.</p>
<p>Machine learning will grow in importance due to ever increasing quantities of data, computer power, and better algorithms.  It mostly won&#8217;t be publically seen, however, much like how it&#8217;s heavily used in Google and a few financial and pharmaceutical companies at the moment.</p>
<p>Significant progress will be made in understanding the brain.  We will have a rough high level sketch of how the brain works, and some of its processes we will understand quite well.  We probably still won&#8217;t understand cortical function very well, that will take longer.</p>
<p>More groups will start AGI projects, particularly from 2015 onwards.  These groups will become increasingly mainstream, serious and well funded.  This will be driven by faster computers, better machine learning algorithms and a better understanding of the brain&#8217;s architecture.  Some of these groups will produce small AGIs that will learn to do some interesting things, but they will be nowhere near human level intelligence.  They will, however, be preparing the way for this.  Concern at the dangers of artificial intelligence will become less fringe but it won&#8217;t go mainstream.</p>
<p>In short, I&#8217;m predicting a bigger brighter expanded version of the last few years &#8212; nothing particularly radical.  I think the real significance of the teenies will be to lay the foundations for more important things to come.</p>
<p>* UPDATE 15/1/2010: I&#8217;ve thought a bit about the main criticism of my predictions above, namely that the graphics chip business will collapse.  As a result I&#8217;ve decided to soften my prediction.  I&#8217;m now thinking that 10 more years probably won&#8217;t be enough for it to collapse due to overshooting demand.  Going to 3D creates 2x the computational demand, going to higher resolution can create 5x demand, and better quality and more sophisticated graphics techniques can drive another 10x, maybe a bit more.  Overall this approximately 100x might be enough to drive demand through until the end of the teenies.  If a collapse does come, I think it will more likely be due to somebody like Intel getting aggressive and building cutting edge GPUs into their CPU chips thus making GPUs redundant.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/12/the-teenies/feed/</wfw:commentRss>
		<slash:comments>24</slash:comments>
		</item>
		<item>
		<title>The Noughties</title>
		<link>http://www.vetta.org/2009/12/the-noughties/</link>
		<comments>http://www.vetta.org/2009/12/the-noughties/#comments</comments>
		<pubDate>Sat, 19 Dec 2009 13:04:47 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=847</guid>
		<description><![CDATA[The start of the Noughties for me was Y2K. It was a non-event, thanks, I might add, to people like me making ourselves mentally unwell fixing endless date issues in crappy database code. Next was the massive dot com crash &#8230; <a href="http://www.vetta.org/2009/12/the-noughties/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>The start of the Noughties for me was <em>Y2K</em>.  It was a non-event, thanks, I might add, to people like me making ourselves mentally unwell fixing endless date issues in crappy database code.  Next was the massive <em>dot com crash</em> &#8212; our wonderful future of super internet everything was an illusion&#8230; except, well, the biggest technological development of the decade <em>was in fact</em> the growth of the internet and all its related technologies.  The problem existed in the mind of the market, not in the soundness or long term significance of the underlying technology.</p>
<p>It&#8217;s hard to believe that almost everybody was on dial-up internet in 2000, <em>broadband</em> existed, but it was slow and not many had it.  The rise of <em>blogging</em> was interesting.  To start with many more traditional media sources were freaking out about the idea that some 15 year old from his bedroom could get as much exposure as their latest newspaper article.  Now blogging is just another part of the information ecosystem.  <em>Wikipedia</em>: the encyclopedia&#8217;s went through the classic Ghandi stages of ignore, ridicule, attack and then lose.  The <em>iPod</em> completely changed the music business, espeically combined with <em>file sharing</em>.  Nobody I knew had <em>DVD</em>&#8216;s before 2000, this was the decade they became big.  Same for <em>flatscreen</em> monitors and TVs.  I got a <em>digital camera</em> in 2000 when they were just coming out and still cost a fortune.  During the Noughties they revolutionised photography.  <em>Wifi</em>, nobody I knew had it in 2000, now it&#8217;s almost everywhere.  Same for <em>internet to the phone</em>.  Or <em>text messages</em>, that&#8217;s been quite a change.  I remember when <em>online banking</em> was seen as strange and a bit risky, now it&#8217;s how many people do most of their banking.  <em>Google</em> existed, but they really only became huge during this decade.  <em>Youtube</em>, another big change in how many people used the internet.  Same for <em>Facebook</em>.  I still remember how people would react to my enthusiasm for <em>open source software</em>, basically it was seen as a hippy movement that wasn&#8217;t something that most serious business people would entertain.  That certainly has changed.  The <em>iPhone</em> revolutionised the smart phone industry.</p>
<p>In a nutshell, I&#8217;d say that the Noughties were all about a <em>massive proliferation of digital communication</em>.  In a way the dot coms had roughly the right idea, but it took another decade for the vision to mature.</p>
<p>Outside of technology, <em>9/11</em>, <em>Bush</em> and <em>Iraq</em> feature strongly in my mind.  I think the <em>rise of robotic weapons</em> is something that is currently under appreciated.  The <em>rise of China</em> and the way in which <em>global warming</em> went from fringe to mainstream were also significant.  For me seeing a black man elected president of the US was one of the most surprising, and thrilling, things to happen in the last ten years.  If you&#8217;d asked me in 2000 about the probability of that happening, I&#8217;d have put it at something like 1%.  Was I grossly mis-calibrated, or was <em>Obama</em> really a rare event?  I&#8217;m still not sure.  Then finally we have the <em>financial crisis</em> and the continuing repercussions from that now.  I can only presume that the next decade is likely to bring a similar amount of change.  It should be an interesting time to be alive&#8230;</p>
<p><em>First question</em>, what will we call the next decade?  The &#8220;teens&#8221;?  That seems kind of lame to me!  <em>Second question</em>, what do you think are likely to be the changes of the coming decade?  Are we in for some big surprises, or just a continuation of current trends?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/12/the-noughties/feed/</wfw:commentRss>
		<slash:comments>34</slash:comments>
		</item>
		<item>
		<title>Ray Solomonoff</title>
		<link>http://www.vetta.org/2009/12/ray-solomonoff/</link>
		<comments>http://www.vetta.org/2009/12/ray-solomonoff/#comments</comments>
		<pubDate>Mon, 14 Dec 2009 12:14:19 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Singularity]]></category>
		<category><![CDATA[Solomonoff]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=835</guid>
		<description><![CDATA[A little over a week ago I felt rather honoured to be reviewing a new submission by a living legend of artificial intelligence, Ray Solomonoff. Sadly the great man passed away just two days later, at the age of 83. &#8230; <a href="http://www.vetta.org/2009/12/ray-solomonoff/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>A little over a week ago I felt rather honoured to be reviewing a new submission by a living legend of artificial intelligence, Ray Solomonoff.  Sadly the great man passed away just two days later, at the age of 83.  That he was still writing papers until the end of his life is a great testament to the passion he had for research.</p>
<p>I&#8217;ve been thinking about what I might write about his work.  Rather than quoting something pertaining to complexity, prior probability or induction I&#8217;ve decided to quote a relatively unknown paper that shows something of his futurist interests.  The paper is called &#8220;The time scale of artificial intelligence: Reflections on social effects&#8221; and was published in 1985.</p>
<blockquote><p>
The last 100 years have seen the introduction of special and general relatively, automobiles, airplanes, quantum mechanics, large rockets and space travel, fission power, fusion bombs, lasers, and large digital computers. Any one of these might take a person years to appreciate and understand. Suppose that they had all been presented to man kind in a single year! This is the magnitude of &#8220;future shock&#8221; that we can expect from our AI expanded scientific community.  In the past, introduction of a new technology into the culture has usually been rather slow, so we had time to develop some understanding of its effect on us, to adjust the technology and culture for an optimum &#8220;coming together&#8221;. Even with a slow introduction, our use of a new technology has sometimes been very poor.</p>
<p>&#8230;We should be able to get our intelligent machines to explain each new technology in a way that is intelligible to man. If this can&#8217;t be done, and the new technology is essentially un-understandable to man, then man would be foolish indeed to use it in any way!</p>
<p>However, understanding does not always assure success in dealing with very complex problems. Mankind will continue to have to make decisions under conditions of uncertainty. In the past he has usually chosen his courses of action relatively blindly &#8212; controlled more by his own perceived wants and needs than by considerations of the likelihoods of alternative possible futures and their effects  upon him.
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/12/ray-solomonoff/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Tick, tock, tick, tock&#8230; BING</title>
		<link>http://www.vetta.org/2009/12/tick-tock-tick-tock-bing/</link>
		<comments>http://www.vetta.org/2009/12/tick-tock-tick-tock-bing/#comments</comments>
		<pubDate>Mon, 07 Dec 2009 20:24:14 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Singularity]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=821</guid>
		<description><![CDATA[Am I the only one who, upon hearing the year 2010, imagines some date far off in the future? I think I felt the same way in the weeks before 2000, so I&#8217;m sure it will pass. Anyway, another year &#8230; <a href="http://www.vetta.org/2009/12/tick-tock-tick-tock-bing/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Am I the only one who, upon hearing the year 2010, imagines some date far off in the future?  I think I felt the same way in the weeks before 2000, so I&#8217;m sure it will pass.  Anyway, another year has gone, indeed another decade, and it&#8217;s time for my annual review of predictions.  You can find my <a href="http://www.vetta.org/2009/02/tick-tock-tick-tock">last annual post here</a>. </p>
<p>It&#8217;s been an interesting year in which I&#8217;ve been exposed to far more neuroscience than ever before.  What I&#8217;ve learnt, plus other news I&#8217;ve absorbed during the year, has helped to clarify my thinking on the future of AI.  First, let&#8217;s begin with computer power.  I recently gave a talk at the Gatsby Unit on the singularity in which I used the following graph showing the estimated LINPACK scores of the fastest computers over the last 50 years.</p>
<p><img src="http://www.vetta.org/VettaPics/supercomputers-3.png" alt="" /><br />
<span id="more-821"></span></p>
<p>The first two points beyond 2010 are for some supercomputers that are already partly constructed.  In the past performance estimates for these kinds of machines near to their delivery have been reasonably accurate so I&#8217;ve put these on the graph.  Rather more speculative is the 2019 data point for the first ExaFLOPS machine.  IBM is in discussions about how to put this machine together based on the technology used in the 20 PetaFLOPS machine due in a year and a bit.  Based on articles on supercomputer sites like top 500, it appears to be a fairly mainstream opinion that this target should be achievable.  Nevertheless, 9 years is a while away so I&#8217;ve marked it in grey.</p>
<p>First observation: just like the people who told me in 1990 that exponential growth in supercomputer power couldn&#8217;t continue for another decade, the people who told me this in 2000 were again completely wrong.  Ha ha, told you so!  So let me make another prediction: for the next decade this pattern will once again roughly hold, taking us to about 10^18 FLOPS by 2020.</p>
<p>Second observation: I&#8217;ve always been a bit sceptical of Kurzweil&#8217;s claim that computer power growth was double exponential, but I&#8217;m now thinking that there is some evidence for this having spent some time putting together data for this graph and attempting to compensate for changes in measurement etc. in the data.  That said, I think it&#8217;s unlikely to remain double exponential much longer.</p>
<p>Third observation: it looks like we&#8217;re heading towards 10^20 FLOPS before 2030, even if things slow down a bit from 2020 onwards.  That&#8217;s just plain nuts.  Let me try to explain just how nuts: 10^20 is about the number of neurons in <em>all human brains combined</em>.  It is also about the estimated number of grains of sand on <em>all the beaches in the world</em>.  That&#8217;s a truly insane number of calculations in 1 second.</p>
<p>Desktop performance is also continuing this trend.  I recently saw that a PC with just two high end graphics cards is around 10^13 FLOPS of SGEMM performance.  I also read a paper recently showing that less powerful versions of these cards lead to around 100x performance increases over CPU computation when learning large deep belief networks.</p>
<p>By the way, in case you think the brain is doing weird quantum voodoo: I had a chat to a quantum physicist here at UCL about the recent claims that there is some evidence for this.  He&#8217;d gone through the papers making these claims with some interest as they touch on topics close to his area of research.  His conclusion was that it&#8217;s a lot of bull as they make assumptions (not backed up with new evidence) in their analysis that essentially everybody in the field believes to be false, among other problems.</p>
<p>Conclusion: computer power is unlikely to be the issue anymore in terms of AGI being possible.  The main question is whether we can find the right algorithms.  Of course, with more computer power we have a more powerful tool with which to hunt for the right algorithms and it also allows any algorithms we find to be less efficient.  Thus growth in computer power will continue to be an important factor.</p>
<p>Having dealt with computation, now we get to the algorithm side of things.  One of the big things influencing me this year has been learning about how much we understand about how the brain works, in particular, how much we know that should be of interest to AGI designers.  I won&#8217;t get into it all here, but suffice to say that just a brief outline of all this information would be a 20 page journal paper (there is currently a suggestion that I write such a paper next year with some Gatsby Unit neuroscientists, but for the time being I&#8217;ve got too many other things to attend to).  At a high level what we are seeing in the brain is a fairly sensible looking AGI design.  You&#8217;ve got hierarchical temporal abstraction formed for perception and action combined with more precise timing motor control, with an underlying system for reinforcement learning.  The reinforcement learning system is essentially a type of temporal difference learning though unfortunately at the moment there is evidence in favour of actor-critic, Q-learning and also Sarsa type mechanisms &#8212; this picture should clear up in the next year or so.  The system contains a long list of features that you might expect to see in a sophisticated reinforcement learner such as pseudo rewards for informative queues, inverse reward computations, uncertainty and environmental change modelling, dual model based and model free modes of operation, things to monitor context, it even seems to have mechanisms that reward the development of conceptual knowledge.  When I ask leading experts in the field whether we will understand reinforcement learning in the human brain within ten years, the answer I get back is &#8220;yes, in fact we already have a pretty good idea how it works and our knowledge is developing rapidly.&#8221;</p>
<p>The really tough nut to crack will be how the cortical system works.  There is a lot of effort going into this, but based on what I&#8217;ve seen, it&#8217;s hard to say just how much real progress is being made.  From the experimental neuroscience side of things we will soon have much more detailed wiring information, though this information by itself is not all that enlightening.  What would be more useful is to be able to observe the cortex in action and at the moment our ability to do this is limited.  Moreover, even if we could, we would still most likely have a major challenge ahead of us to try to come up with a useful conceptual understanding of what is going on.  Thus I suspect that for the next 5 years, and probably longer, neuroscientists working on understanding cortex aren&#8217;t going to be of much use to AGI efforts.  My guess is that sometime in the next 10 years developments in deep belief networks, temporal graphical models, liquid computation models, slow feature analysis etc. will produce sufficiently powerful hierarchical temporal generative models to essentially fill the role of cortex within an AGI.  I hope to spend most of next year looking at this so in my next yearly update I should have a clearer picture of how things are progressing in this area.</p>
<p>Right, so my prediction for the last 10 years has been for roughly human level AGI in the year 2025 (though I also predict that sceptics will deny that it&#8217;s happened when it does!)  This year I&#8217;ve tried to come up with something a bit more precise.  In doing so what I&#8217;ve found is that while my mode is about 2025, my expected value is actually a bit higher at 2028.  This is not because I&#8217;ve become more pessimistic during the year, rather it&#8217;s because this time I&#8217;ve tried to quantify my beliefs more systematically and found that the probability I assign between 2030 and 2040 drags the expectation up.  Perhaps more useful is my 90% credibility region, which from my current belief distribution comes out at 2018 to 2036.  If you&#8217;d like to see this graphically, David McFadzean put together <a href="http://www.churchofvirus.org/bbs/index.php?board=5&#038;action=display&#038;threadid=42884&#038;start=0">a graph of my prediction</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/12/tick-tock-tick-tock-bing/feed/</wfw:commentRss>
		<slash:comments>33</slash:comments>
		</item>
		<item>
		<title>1973 Lighthill debate</title>
		<link>http://www.vetta.org/2009/11/1973-lighthill-debate/</link>
		<comments>http://www.vetta.org/2009/11/1973-lighthill-debate/#comments</comments>
		<pubDate>Mon, 09 Nov 2009 18:09:20 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Research Review]]></category>
		<category><![CDATA[AI]]></category>
		<category><![CDATA[intelligence]]></category>
		<category><![CDATA[Lighthill]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=772</guid>
		<description><![CDATA[Some of you might know about the Lighthill report from 1973 which was deeply critical of progress in AI. This report was the main factor behind cutting the funding of AI research in the UK, and seems to have contributed &#8230; <a href="http://www.vetta.org/2009/11/1973-lighthill-debate/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Some of you might know about the Lighthill report from 1973 which was deeply critical of progress in AI.  This report was the main factor behind cutting the funding of AI research in the UK, and seems to have contributed to the more global cuts around this time known as the &#8220;AI winter&#8221;.  Via <a href="http://www.gatsby.ucl.ac.uk/~ywteh">Yee Whye Teh</a> I recently came across a BBC debate between James Lighthill and three supporters of AI research: Richard Gregory, John McCarthy and Donald Michie.  You can download the televised debate <a href="http://www.aiai.ed.ac.uk/events/lighthill1973/1973-BBC-Lighthill-Controversy.mov">from here</a>, though be warned that it&#8217;s 160MB.  </p>
<p>Now, 36 years later, it&#8217;s interesting to think about how the speakers&#8217; various views and predictions have played out.  Overall, the analysis by Lighthill felt the most coherent to me, and I&#8217;d say that what has since happened largely backs him up, though it can be argued that he helped to cause this outcome.  I agree that he slowed AI down a lot, but 36 years is a rather long time and in the types of problems that he was focusing on there hasn&#8217;t been much progress.  In response the other debaters mostly just pointed to small advances that had occurred and indicated that they felt that more advances were on the way.  Lighthill then denied that these advances showed any real progress towards intelligence.</p>
<p>This feels a lot like today: sceptics say that AI has made no progress, optimists point to lots of advances, and sceptics then say that these advances are not what they consider to be real intelligence.  I think this points to perhaps the most fundamental problem in the field: if you can&#8217;t define intelligence, how do you judge whether progress is being made?  It&#8217;s as true today as it was then, and it&#8217;s why I think that trying to <a href="http://www.vetta.org/documents/UniversalIntelligence.pdf">define intelligence</a> is so important.  I like the fact that they keep on saying that an intelligent machine should be able to perform well in a &#8220;wide range of situations&#8221;, because, of course, this is very much the view of intelligence that I have taken.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/11/1973-lighthill-debate/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
<enclosure url="http://www.aiai.ed.ac.uk/events/lighthill1973/1973-BBC-Lighthill-Controversy.mov" length="169265179" type="video/quicktime" />
		</item>
		<item>
		<title>Monte Carlo AIXI</title>
		<link>http://www.vetta.org/2009/09/monte-carlo-aixi/</link>
		<comments>http://www.vetta.org/2009/09/monte-carlo-aixi/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 20:55:34 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Research Review]]></category>
		<category><![CDATA[AGI]]></category>
		<category><![CDATA[AIXI]]></category>
		<category><![CDATA[Monte Carlo]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=635</guid>
		<description><![CDATA[While I was visiting Marcus Hutter at ANU a month or so ago, I got talking to one of his students, Joel Veness, who&#8217;s working on making computable approximations to AIXI. Joel has a background in writing Go algorithms so &#8230; <a href="http://www.vetta.org/2009/09/monte-carlo-aixi/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>While I was visiting Marcus Hutter at ANU a month or so ago, I got talking to one of his students, Joel Veness, who&#8217;s working on making computable approximations to AIXI.  Joel has a background in writing Go algorithms so is perhaps perfect for the job.  I saw recently that the <a href="http://arxiv.org/abs/0909.0801">Monte Carlo AIXI</a> paper describing this work is now available online if you want to check it out.</p>
<p>The basic idea goes as follows.  In full AIXI you have an extended Solomonoff predictor to model the environment, and an expecti-max tree to compute the optimal action.  In order to scale AIXI down and still have something of roughly the same form, you need to find a tractable way to replace both of these two items.  Here&#8217;s what they did: in the place of extended Solomonoff induction a version of context tree weighting (CTW) is used. CTW has to be extended for this application similar to the way Hutter had to extend Solomonoff induction to active environments for AIXI. In the place of the expecti-max tree search a Monte Carlo tree search is used, similar to that used in Go playing programs: initial selection within the tree, tree expansion, a so called play-out policy, followed by a backup stage to propagate the new information back into the model. You have to be a bit careful here because as the agent imagines different future observations and actions it has to update its hypothetical beliefs to reflect these in order for its analysis and decision making to be consistent. Then, once this possible future has been evaluated, the effect of this on the agent&#8217;s model of the world has to be unwound so that the agent doesn&#8217;t, in effect, start confusing its fantasies with its present reality.<br />
<span id="more-635"></span></p>
<p>The algorithm is both embarrassingly-parallel and any-time, which is very nice. In less technical language: it would be fairly easy to get it to run efficiently on a massively parallel supercomputer, and it also has the property that it can be forced to decide what action to take at any moment always returning the best action it had been able to compute so far.  Thus, if you want a smarter agent, just give it more time and/or CPUs.  Already they have shown that MC-AIXI can learn to solve a bunch of basic POMDP problems, including playing a somewhat reasonable game of Pac-man.  It would be interesting to see what it was capable of on a supercomputer with ten thousand times the resources of their desktop PC.</p>
<p>A key question for future research is to make better sequence predictors, in particular to be able to identify more complex types of patterns in the agent&#8217;s history. I guess all sorts of machine learning techniques could come into play hereâ€¦ and possibly combine to produce quite a powerful RL agent?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/09/monte-carlo-aixi/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Tokyo: A Cython BLAS wrapper for fast matrix math</title>
		<link>http://www.vetta.org/2009/09/tokyo-a-cython-blas-wrapper-for-fast-matrix-math/</link>
		<comments>http://www.vetta.org/2009/09/tokyo-a-cython-blas-wrapper-for-fast-matrix-math/#comments</comments>
		<pubDate>Tue, 15 Sep 2009 01:15:04 +0000</pubDate>
		<dc:creator>Shane</dc:creator>
				<category><![CDATA[Programing]]></category>
		<category><![CDATA[BLAS]]></category>
		<category><![CDATA[Cython]]></category>
		<category><![CDATA[LAPACK]]></category>
		<category><![CDATA[Mathematics]]></category>
		<category><![CDATA[Matrix]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Scipy]]></category>

		<guid isPermaLink="false">http://www.vetta.org/?p=594</guid>
		<description><![CDATA[Prototyping mathematical code in Python with the Scipy/Numpy libraries and then switching to Cython for speed often works well, but there are limitations. The main problem that has been bugging me recently is the speed of matrix function calls. What &#8230; <a href="http://www.vetta.org/2009/09/tokyo-a-cython-blas-wrapper-for-fast-matrix-math/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Prototyping mathematical code in Python with the Scipy/Numpy libraries and then switching to Cython for speed often works well, but there are limitations.  The main problem that has been bugging me recently is the speed of matrix function calls.  What happens is that your Cython code needs to compute, say the outer product of two vectors, and so makes a call to Numpy.  At this point everything switches to very slow interpreted Python code which does a few checks etc. before calling into the underlying fast BLAS library that does the actual work.  For large matrices the cost of this wrapping code wasn&#8217;t a big deal, but for small matrices it can be a huge performance hit.</p>
<p>To solve this problem I&#8217;ve created a Cython wrapper for many of the more common BLAS functions.  It&#8217;s called Tokyo: I often name code after cities and both Tokyo and BLAS/LAPACK were big, fast and very foreign to start with!  At the moment Tokyo only wraps the BLAS routines for vectors and general matrices with single and double precision.  If you want to add other things such as banded matrices, complex numbers or LAPACK calls: just look at what I&#8217;ve already done and add the functions you need.  I&#8217;ve also added a few extra functions that I find useful when doing matrix calculations.  The idea is that Tokyo will eventually encompass all of BLAS and LAPACK.<br />
<span id="more-594"></span></p>
<p>The speedup you can expect varies a lot depending on the size of the vectors and matrices involved and the operation being computed.  An outer product on length 4 vectors can be over 150 times faster, while a 20&#215;20 matrix multiplication is about the same speed.  After installing Tokyo, execute the single and double precision speed tests to see how much faster the Tokyo routines are compared to using Numpy on your machine.  For my own reinforcement learning research I&#8217;ve managed to get between 5 and 20 times speedups with various algorithms.</p>
<p>Here&#8217;s a simple example of a vector outer product, first in pure Python with Numpy:</p>
<p><code>import numpy as np</p>
<p>x = np.array( [1.0, 2.0, 3.0, 4.0] )<br />
y = np.array( [7.0, 8.0, 9.0, 0.0] )</p>
<p>print np.outer( x, y )<br />
</code><br />
And now a fast version in Cython using Tokyo:</p>
<p><code>import numpy as np<br />
cimport numpy as np<br />
import tokyo<br />
cimport tokyo</p>
<p>cdef np.ndarray x = np.array( [ 1.0, 2.0, 3.0, 4.0 ] )<br />
cdef np.ndarray y = np.array( [ 7.0, 8.0, 9.0, 0.0 ] )</p>
<p>print tokyo.dger( x, y )<br />
</code><br />
You see I use the BLAS names for functions, here &#8220;dger&#8221; is short for &#8220;double precision general rank-1&#8243;.  BLAS naming seems confusing to start with but after a little study it&#8217;s actually quite simple.  As per usual in Cython, giving x and y a cdef type isn&#8217;t necessary, but it allows Cython to produce faster C code.</p>
<p>As I suspect that quite a few other people have run into this matrix speed problem I figure it&#8217;s worth sharing the code.  Finally, thanks to Dag Sverre Seljebotn&#8217;s Scipy 2009 tutorial which got me started on writing this.</p>
<p>Get Tokyo here:  <a href="http://www.vetta.org/software/tokyo_v0.3.tgz">www.vetta.org/software/tokyo_v0.3.tgz</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.vetta.org/2009/09/tokyo-a-cython-blas-wrapper-for-fast-matrix-math/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

<!-- Dynamic page generated in 0.224 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2013-05-20 06:11:07 -->
