<?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/"
	
	xmlns:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	>

<channel>
	<title>Accelerators Archives &mdash; Tim Dettmers</title>
	<atom:link href="https://timdettmers.com/tag/accelerators/feed/" rel="self" type="application/rss+xml" />
	<link>https://timdettmers.com/tag/accelerators/</link>
	<description>Making deep learning accessible.</description>
	<lastBuildDate>Sun, 20 Sep 2020 21:40:19 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.0.11</generator>

<image>
	<url>https://i0.wp.com/timdettmers.com/wp-content/uploads/2025/12/cropped-profile_2026_400x400.png?fit=32%2C32&#038;ssl=1</url>
	<title>Accelerators Archives &mdash; Tim Dettmers</title>
	<link>https://timdettmers.com/tag/accelerators/</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">106749684</site>	<item>
		<title>TPUs vs GPUs for Transformers (BERT)</title>
		<link>https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/</link>
					<comments>https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/#comments</comments>
		
		<dc:creator><![CDATA[Tim Dettmers]]></dc:creator>
		<pubDate>Wed, 17 Oct 2018 18:13:03 +0000</pubDate>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Accelerators]]></category>
		<category><![CDATA[GPU]]></category>
		<category><![CDATA[Matrix Multiplication]]></category>
		<guid isPermaLink="false">http://timdettmers.com/?p=686</guid>

					<description><![CDATA[<p>On the computational side, there have been confusions about how TPUs and GPUs relate to BERT. BERT base was trained with 4 TPU pods (16 TPU chips) in 4 days and BERT large with 16 TPUs (64 TPU chips) in 4 days. Does this mean only Google can train a BERT model? Does this mean [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/">TPUs vs GPUs for Transformers (BERT)</a> appeared first on <a rel="nofollow" href="https://timdettmers.com">Tim Dettmers</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>On the computational side, there have been confusions about how TPUs and GPUs relate to <a href="https://arxiv.org/abs/1810.04805">BERT</a>. BERT base was trained with 4 TPU pods (16 TPU chips) in 4 days and BERT large with 16 TPUs (64 TPU chips) in 4 days. Does this mean only Google can train a BERT model? Does this mean that GPUs are dead? There are two fundamental things to understand here: (1) A TPU is a matrix multiplication engine — it does matrix multiplication and matrix operations, but not much else. It is fast at computing matrix multiplication, but one has to understand that (2) the slowest thing in matrix multiplication is to get the elements from the main memory and load it into the processing unit. In other words, the most expensive part in matrix multiplication is memory loads. Note the computational load for BERT should be about 90% for matrix multiplication. From these facts, we can do a small technical analysis on this topic.</p>
<p><span id="more-686"></span></p>
<h2>Bandwidth Model for TPUs and GPUs</h2>
<h3>Transformers for TPUs</h3>
<p>A common operation in BERT is matrix multiplication A*B=C where A is 256&#215;1024 and B is 1024&#215;1024 in dimension. A TPU computes such a matrix multiplication by splitting the matrix into many smaller 128&#215;128 matrix multiplications. This means we need to load 16 128&#215;128 matrix tiles from matrix A — and due to the nature of matrix multiplication — we need to load 64 tiles from B for every tile in A. This is a total of 16*64=1024 128&#215;128 loads. At 16-bit that is a total of 32 MB of data.</p>
<p><a href="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg"><img data-attachment-id="698" data-permalink="https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/cloud-tpu-feature/" data-orig-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?fit=1123%2C620&amp;ssl=1" data-orig-size="1123,620" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="Cloud-TPU-Feature" data-image-description="" data-image-caption="" data-medium-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?fit=300%2C166&amp;ssl=1" data-large-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?fit=1024%2C565&amp;ssl=1" class="aligncenter wp-image-698" title="TPU vs GPU" src="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature-1024x565.jpg?resize=745%2C411" alt="TPU vs GPU" width="745" height="411" srcset="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?resize=1024%2C565&amp;ssl=1 1024w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?resize=300%2C166&amp;ssl=1 300w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?resize=768%2C424&amp;ssl=1 768w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/Cloud-TPU-Feature.jpg?w=1123&amp;ssl=1 1123w" sizes="(max-width: 745px) 100vw, 745px" data-recalc-dims="1" /></a></p>
<p>Now we make a simplification: We assume that there is no latency if we do two memory loads after each other, which is actually not too unreasonable since often you can hide memory access latency under thread parallelism. In simple words, this means: While we wait for one 128&#215;128 matrix copy to complete, we already do the next one. In doing it this way, we only wait for the first memory copy and we do not wait for other copies. This is a <a href="https://www.quora.com/Why-are-GPUs-well-suited-to-deep-learning">core reason why GPUs are fast</a> and why we use many threads in GPUs thus 0 latency for overlapping memory transfers is not too far off from the real world. Using this simplification, we can now plainly use the memory bandwidth to compute the time needed to load the memory for the matrix multiplication. If we look at the bandwidth of the TPU we find that we have 600 GB/s, so we need 5.2e-05 seconds to transfer the 32 MB of data.</p>
<h3>Transformers on GPUs</h3>
<p>For a GPU we have the same process, but we use smaller tiles with more processors. Similarly to the TPU, we use two loads in parallel to hide memory latency. For GPUs, however, we would have a tile size of 96&#215;96 for 16-bit data. If we take a V100 Tesla GPU, then we can run 160 of these in parallel at full bandwidth with low memory latency. What this means compared to a TPU: Instead of 2 matrix units which can hold 128&#215;128 matrices, the GPU has 160 units (80 SMs, 160 thread blocks, each thread block has two 96&#215;96 matrices) which hold two 96&#215;96 matrices. Again this ensures that we can hide the memory latency through parallelism.</p>
<p><a href="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg"><img data-attachment-id="697" data-permalink="https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/attachment/010/" data-orig-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?fit=1024%2C576&amp;ssl=1" data-orig-size="1024,576" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="010" data-image-description="" data-image-caption="" data-medium-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?fit=300%2C169&amp;ssl=1" data-large-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?fit=1024%2C576&amp;ssl=1" class="aligncenter wp-image-697" title="TPU vs GPU" src="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010-1024x576.jpg?resize=818%2C460" alt="TPU vs GPU" width="818" height="460" srcset="https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?w=1024&amp;ssl=1 1024w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?resize=300%2C169&amp;ssl=1 300w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2018/10/010.jpg?resize=768%2C432&amp;ssl=1 768w" sizes="(max-width: 818px) 100vw, 818px" data-recalc-dims="1" /></a></p>
<p>If we repeat the calculation from the top we receive the following: For matrix A with 256&#215;1024 we have 33 96&#215;96 tiles; for B with 1024&#215;1024 we have 121 96&#215;96 tiles. In total, we need to do 33*121=3993 loads of size 96&#215;96 for a total of 70 MB. A V100 runs at 900 GB/s and so the memory loads will take 7.6e-05 seconds. Thus our model predicts that a GPU is 32% slower than a TPU for this specific scenario. Note that matrix tiles stay the same for an RTX 2080 Ti GPU, but the memory bandwidth decreases to 616 GB/s. Which means an RTX 2080 Ti is 54% slower than a TPU.</p>
<p>Note that both TPU and GPUs with Tensor Cores compute the respective matrix multiplication tile in one cycle. Thus the computation is about equally fast — the difference is only in how the memory is loaded.</p>
<h3>BERT Training Time Estimate for GPUs</h3>
<p>Using this data, a GPU cluster of V100s/RTX 2080 Tis with good networking (Infiniband +56GBits/s) and good parallelization algorithms (for example using Microsoft&#8217;s CNTK) we can expect to train BERT large on 64 GPUs (the equivalent to 16 TPUs) or BERT base on 16 GPUs in 5 1/3 days or 8 1/2 days. On an 8 GPU machine for V100/RTX 2080 Tis with any software and any parallelization algorithm (PyTorch, TensorFlow) one can expect to train BERT large in 21 days or 34 days and BERT base in 10 2/3 or 17 days. For a standard 4 GPU desktop with RTX 2080 Ti (much cheaper than other options), one can expect to replicate BERT large in 68 days and BERT base in 34 days.</p>
<h2>Limitations of the Bandwidth Model</h2>
<p>Note that all models are wrong, but some are useful. I would expect that this bandwidth model is in about 30% of the correct runtime values for TPU vs GPU.</p>
<p>The biggest limitation is that these calculations&nbsp;are for specific matrices sizes. Computational differences can be amplified&nbsp;for certain sizes. For example, if your batch-size is 128, there is a slight speedup for GPUs compared to TPUs. If you go below a batch size of 128 you can expect GPUs to be significantly faster; increasing the matrix B further makes TPUs better and better compared to GPUs. Decreasing the size of matrix B will make the performance of GPUs better. Note that the BERT paper optimized matrix A and B sizes for the TPU — one would not choose these dimensions if you train with a GPU. So this comparison might favor TPUs slightly.</p>
<p>Further direct limitations include fused operations. The TPU can calculate additional element-wise operations such as a non-linear activation function or a bias on the fly within a matrix multiplication. This means that the TPU does not need to load from slow global memory as often as a GPU. The GPU also supports these operations but NVIDIA has not implemented them and thus GPU users will not be able to benefit from this. Thus one can expect a slowdown of about 1.6% (loading and storing a 256&#215;1024 matrix) for each element-wise operation for a GPU. For example, if you apply a non-linear function and a bias, then the TPU would be about 3.2% faster compared to GPUs in this scenario.</p>
<h2>The Importance of 32-bit vs 16-bit vs 8-bit</h2>
<p>If we repeat the same calculations from above for 32-bit values (64x64x tiles) we find that TPUs would be 5.3x faster. So the datatype size has a much larger effect than switching from TPU to GPU and vice versa.</p>
<p>TPUs do not support 8-bit training, but Turing GPUs do. So we can also have a look at how 8-bit matrix multiplication would impact performance.&nbsp;<a href="https://arxiv.org/abs/1511.04561">I published research on 8-bit models</a> and it is not too difficult to train them with 8-bit alone. In fact, the <a href="https://arxiv.org/search/cs?searchtype=author&amp;query=Courbariaux%2C+M">literature</a> on <a href="https://arxiv.org/abs/1602.02830">low-bit</a> computing is <a href="https://dawn.cs.stanford.edu/2018/03/09/low-precision/">quite rich</a>. With 32-bit accumulation as supported by Turing GPUs 8-bit training should be even easier.&nbsp; If we can make 8-bit computing work for general models this would entail huge speedups for transformers. If we repeat the above calculations for 8-bit for GPUs (128&#215;128 tile) we find that GPUs are 3.0x faster than TPUs. 8-bit computation on an affordable standard machine with 4 RTX 2080 Ti would take about 11 days for BERT base and 22 days for BERT large. All of this makes 16-bit computational ability for a GPU and important criterion <a href="https://timdettmers.com/2020/09/07/which-gpu-for-deep-learning/">if you are looking for a GPU</a> to work with transformers.</p>
<h2>Conclusion</h2>
<p>TPUs are about 32% to 54% faster for training BERT-like models. One can expect to replicate BERT base on an 8 GPU machine within about 10 to 17 days. On a standard, affordable GPU machine with 4 GPUs one can expect to train BERT base for about 34 days using 16-bit or about 11 days using 8-bit.</p>
<p>The post <a rel="nofollow" href="https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/">TPUs vs GPUs for Transformers (BERT)</a> appeared first on <a rel="nofollow" href="https://timdettmers.com">Tim Dettmers</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://timdettmers.com/2018/10/17/tpus-vs-gpus-for-transformers-bert/feed/</wfw:commentRss>
			<slash:comments>26</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">686</post-id>	</item>
		<item>
		<title>Deep Learning Hardware Limbo</title>
		<link>https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/</link>
					<comments>https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/#comments</comments>
		
		<dc:creator><![CDATA[Tim Dettmers]]></dc:creator>
		<pubDate>Thu, 21 Dec 2017 11:10:23 +0000</pubDate>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Accelerators]]></category>
		<category><![CDATA[AMD]]></category>
		<category><![CDATA[GPU]]></category>
		<category><![CDATA[Intel]]></category>
		<guid isPermaLink="false">http://timdettmers.com/?p=627</guid>

					<description><![CDATA[<p>With the release of the Titan V, we now entered deep learning hardware limbo. It is unclear if NVIDIA will be able to keep its spot as the main deep learning hardware vendor in 2018 and both AMD and Intel Nervana will have a shot at overtaking NVIDIA. So for consumers, I cannot recommend buying any hardware right now. The most prudent choice is to wait until the hardware limbo passes. This might take as little as 3 months or as long as 9 months. So why did we enter deep learning hardware limbo just now?</p>
<p>The post <a rel="nofollow" href="https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/">Deep Learning Hardware Limbo</a> appeared first on <a rel="nofollow" href="https://timdettmers.com">Tim Dettmers</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>With the release of the Titan V, we now entered deep learning hardware limbo. It is unclear if NVIDIA will be able to keep its spot as the main deep learning hardware vendor in 2018 and both AMD and Intel Nervana will have a shot at overtaking NVIDIA. So for consumers, I cannot recommend buying any hardware right now. The most prudent choice is to wait until the hardware limbo passes. This might take as little as 3 months or as long as 9 months. So why did we enter deep learning hardware limbo just now?</p>
<p><span id="more-627"></span></p>
<p>NVIDIA has decided that it needs to cash-in on its monopoly position before the competition emerges. It needs the cash in order to defend itself in the next 1-2 years. This is reflected by the choice to price the Titan V at $3000. With TensorCores the Titan V has a new shiny deep learning feature, but at the same time, its cost/performance ratio is abysmal. This makes the Titan V very unattractive. But because there is no alternative, people will need to eat what there are served – at least for now.</p>
<p>The competition is strong. We have AMD whose hardware is now already better than NVIDIA’s and plans to get itself together to produce some deep learning software which is actually usable. With this step, the cost/performance ratio will easily outmatch NVIDIA cards and AMD will become the new standard. NVIDIA’s cash advantage will help fight AMD off so that we might see very cheap NVIDIA cards in the future. Note that this will only happen if AMD is able to push forward with good software — if AMD falters, NVIDIA cards will remain expensive and AMD will have lost its opportunity to grab the throne.</p>
<p>There is also a new contender in town: The Neural Network Processor (NNP) form Intel Nervana. With several unique features, it packs quite a punch. These new features make me drool — they are exactly what I want as a CUDA developer. The NNP solves most problems I face when I want to write CUDA kernels which are optimized for deep learning. This chip is the first true deep learning chip.</p>
<p>In general, for a 1-chip vs 1-chip ranking, we will see Nervana &gt; AMD &gt; NVIDIA, just because NVIDIA has to service gaming/deep learning/high-performance computing at once, while AMD only needs to service gaming/deep learning, whereas Nervana can just concentrate on deep learning – a huge advantage. The more concentrated a designed architecture, the less junk is on the chip for deep learning.</p>
<p>However, the winner is not determined by pure performance, and not even by pure cost/performance. It is determined by cost/performance + community + deep learning frameworks.</p>
<p>Let&#8217;s have a closer look at the individual positions of Nervana, AMD, and NVIDIA to see where they stand.</p>
<h2>Nervana’s Neural Network Processors</h2>
<blockquote class="twitter-tweet" data-lang="en">
<p dir="ltr" lang="en">Why <a href="https://twitter.com/NaveenGRao?ref_src=twsrc%5Etfw">@NaveenGRao</a> is excited about <a href="https://twitter.com/hashtag/Intel?src=hash&amp;ref_src=twsrc%5Etfw">#Intel</a> Nervana NNP: <a href="https://t.co/DAqgOYFtoR">https://t.co/DAqgOYFtoR</a> <a href="https://twitter.com/hashtag/AI?src=hash&amp;ref_src=twsrc%5Etfw">#AI</a> <a href="https://t.co/dbLMdnp63t">pic.twitter.com/dbLMdnp63t</a></p>
<p>— Intel AI (@IntelAI) <a href="https://twitter.com/IntelAI/status/925476243788697600?ref_src=twsrc%5Etfw">October 31, 2017</a></p></blockquote>
<p><script async="" src="https://platform.twitter.com/widgets.js" charset="utf-8"></script></p>
<p>Nervana’s design is very special mainly due to its large programmable caches (similar to CUDA shared memory) which are 10 times bigger per chip compared to GPUs and 50 times bigger per compute unit compared to GPUs. With this one will be able to design in-cache algorithms and models. This will speed up inference by at least an order of magnitude and one will be able to easily train on terabytes of data with small in-cache deep learning models, say, a multi-layer LSTM with 200 units. This will make this chip very attractive for startups and larger companies. Due to a special datatype, Flexpoint, one is able to store more data in caches/RAM and compute faster yielding even more benefits. All of this could mean speedup of about 10x compared to current NVIDIA GPUs for everybody. But this is only so if the main obstacles can be overcome: Community and software.</p>
<p>For the normal users and researchers, it will all depend on the community. Without community, we will not see in-cache algorithms. Without community, we will not see good software frameworks and it will be difficult to work with the chip. Everybody wants to use solid deep learning frameworks and it is questionable if Neon, Nervana’s deep learning framework, is up for the task. Software comes before hardware. If Nervana only ships pretty chips and does not push the software and community aspect effectively it will lose out to AMD and NVIDIA.</p>
<p>The community and software question is tightly bound to the price. If the price is too high, and students are not able to afford the NNP then no community can manifest itself around it. You do not get robust communities by just catering for industry. Although industry yields the main income for hardware companies, students are the main driver for the community. So if the price is right and students can afford it, then the community and the software will follow. Anything above $3000 will not work out. Anything above $2000 is critical and one would require special discounts for students to create a robust community. An NNP priced at $2000 will be manageable and find some adoption. Anything below $1500 will make Nervana the market leader for at least 2-3 years. An NNP at $1000 would make it extremely tough for NVIDIA and AMD to compete — software would not even be a question here, it follows automatically.</p>
<p>I personally will switch to NNPs if they are priced below $2500. They are just so much superior to GPUs for deep learning and I will be able to do things which are just impossible with NVIDIA hardware. If they are over $2500 then it also reaches my pain point for good hardware. I save up a lot of money to buy hardware — good hardware is just important to me — but I have to live from something.</p>
<p>For usual consumers not only the price will be important, but also how the community is handled. If we do not see Intel immediately pumping resources into the community to start up a solid software machinery then the NNP is likely to stagnate and die off. Unfortunately, Intel has a good history of mismanaging communities — it would be a shame if this happens because I really would like to see Nervana succeed.</p>
<p>In summary, we will see Nervana’s NNP will emerge as a clear winner if it will be priced below $2000 and if we see strong community and software development within the first few months after its release. With a higher price and less community support, the NNP will be strong, but might not be able to surpass other solutions in terms of cost/performance and convenience. If the software and community efforts fail or if the NNP is priced at $4000 it will likely fail. A price above $2000 will require significant discounts for students for the NNP to be viable.</p>
<h2>AMD: Cheap and Powerful – If You Can Use It</h2>
<p>&nbsp;</p>
<figure id="attachment_630" aria-describedby="caption-attachment-630" style="width: 500px" class="wp-caption aligncenter"><a href="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg"><img data-attachment-id="630" data-permalink="https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/amd_fiji_gpu_package_with_gpu_hbm_memory_and_interposer/" data-orig-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?fit=3872%2C2592&amp;ssl=1" data-orig-size="3872,2592" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;5&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;NIKON 1 V1&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;1434546595&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;22.7&quot;,&quot;iso&quot;:&quot;400&quot;,&quot;shutter_speed&quot;:&quot;0.066666666666667&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;1&quot;}" data-image-title="AMD_Fiji_GPU_package_with_GPU,_HBM_memory_and_interposer" data-image-description="" data-image-caption="" data-medium-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?fit=300%2C201&amp;ssl=1" data-large-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?fit=1024%2C685&amp;ssl=1" class="wp-image-630" src="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer-300x201.jpg?resize=500%2C335" alt="" width="500" height="335" srcset="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?resize=300%2C201&amp;ssl=1 300w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?resize=768%2C514&amp;ssl=1 768w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?resize=1024%2C685&amp;ssl=1 1024w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?w=2000&amp;ssl=1 2000w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/AMD_Fiji_GPU_package_with_GPU_HBM_memory_and_interposer.jpg?w=3000&amp;ssl=1 3000w" sizes="(max-width: 500px) 100vw, 500px" data-recalc-dims="1" /></a><figcaption id="caption-attachment-630" class="wp-caption-text">Source: <a href="https://commons.wikimedia.org/wiki/File:AMD_Fiji_GPU_package_with_GPU,_HBM_memory_and_interposer.jpg">Wikipedia</a></figcaption></figure>
<p>AMDs cards are incredible. The Vega Frontier Edition series clearly outmatches NVIDIA counterparts, and, from <a href="https://www.xcelerit.com/computing-benchmarks/insights/benchmarks-deep-learning-nvidia-p100-vs-v100-gpu/">unbiased benchmarks</a>&nbsp;of Volta vs Pascal, it seems that the Vega Frontier will be on-a-par or better compared to a Titan V if it is liquid cooled. Note that the Vega is based on an old architecture while the Titan V is brand new. The new AMD architecture, which will be released in 2018Q3 will increase performance further still.</p>
<p>AMD hopes to advance deep learning hardware by just switching from 32-bit floats to 16-bit floats. This is a very simple and powerful strategy. The chips will not be useful for high-performance computing, but they will be solid for gamers and the deep learning community while development costs will be low because 16-bit float computation is straightforward.</p>
<p>They will not be able to compete in terms of performance with Nervana’s NNP, but the cost/performance might outmatch everything on the market. You can get a liquid cooled Vega Frontier for $700 which might be just a little worse than a $3000 Titan V.</p>
<p>The problem is software. Even if you have this powerful AMD GPU, you will hardly be able to use it – no major framework supports AMD GPUs well enough.</p>
<p>AMD is in limbo itself – in software limbo. It seems they want to abandon OpenCL for <a href="https://github.com/ROCm-Developer-Tools/HIP">HIP</a> but currently they officially still push and support the OpenCL path. If they push through with HIP, and if they put some good deep learning software on the market (not only libraries for convolution and matrix multiplication but full deep learning frameworks, say, HIP support for PyTorch) in the next 9 months then their release of their new GPU in 2018Q3 has the potential to demolish all competitors.</p>
<p>So in summary, if AMD gets its shit together in terms of software, it might become the dominating deep learning hardware solution.</p>
<h2>NVIDIA: The Titan</h2>
<p><a href="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg"><img data-attachment-id="632" data-permalink="https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/titan_v/" data-orig-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?fit=1920%2C1080&amp;ssl=1" data-orig-size="1920,1080" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="Titan_V" data-image-description="" data-image-caption="" data-medium-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?fit=300%2C169&amp;ssl=1" data-large-file="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?fit=1024%2C576&amp;ssl=1" class="aligncenter wp-image-632" src="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V-1024x576.jpg?resize=500%2C281" alt="" width="500" height="281" srcset="https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?resize=1024%2C576&amp;ssl=1 1024w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?resize=300%2C169&amp;ssl=1 300w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?resize=768%2C432&amp;ssl=1 768w, https://i0.wp.com/timdettmers.com/wp-content/uploads/2017/12/Titan_V.jpg?w=1920&amp;ssl=1 1920w" sizes="(max-width: 500px) 100vw, 500px" data-recalc-dims="1" /></a></p>
<p>NVIDIA’s position is solid. They have the best software, the best tools, their hardware is good and the community is large, strong and well integrated.</p>
<p>NVIDIA’s main issue is that they have to serve multiple communities: High-performance computing people, deep learning people, and gamers, and this is a huge strain on their hardware. It is expensive to design chips which are custom made for these communities and NVIDIA’s strategy was currently to design a one-size-fits-all architecture. This worked until it didn’t. The Titan V is just mediocre all-around.</p>
<p>With the emerging competitors, NVIDIA has two choices. (1) Push the price on their cards down until they starve the competition to death, or (2) they can develop specialized deep learning hardware on their own. NVIDIA has the resources to pursue the first strategy, and it also has the expertise for the second strategy. A new design, however, will take some time and NVIDIA might lose the throne to another company in the meantime. So we might see both strategies played out a once: Starving competitors so that NVIDIA can compete until their own deep learning chip hits the market.</p>
<p>In summary, NVIDIAs throne is threatened, but it has the resources and the expertise to fight against emerging players. We will probably see cheaper NVIDIA cards in the future and chips which are more specialized for deep learning. If NVIDIA does not lower its prices it might (temporarily) pass the throne to another player.</p>
<h2>Conclusion</h2>
<p>Deep learning hardware limbo means that it makes no sense to invest in deep learning hardware right now, but it also means we will have cheaper NVIDIA cards, usable AMD cards, and ultra-fast Nervana cards quite soon. It is an exciting time and we consumers will profit from this immensely. But for now, we have to be patient. We have to wait. I will keep you updated as the situation changes.</p>
<p>The post <a rel="nofollow" href="https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/">Deep Learning Hardware Limbo</a> appeared first on <a rel="nofollow" href="https://timdettmers.com">Tim Dettmers</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://timdettmers.com/2017/12/21/deep-learning-hardware-limbo/feed/</wfw:commentRss>
			<slash:comments>91</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">627</post-id>	</item>
	</channel>
</rss>
