-
Notifications
You must be signed in to change notification settings - Fork 56
/
Copy pathindex.html
851 lines (816 loc) · 40.4 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>reveal.js</title>
<link rel="stylesheet" href="css/reveal.css">
<link rel="stylesheet" href="css/theme/black.css">
<link rel="stylesheet" href="genericons.css">
<link rel="stylesheet" href="lib/css/zenburn.css">
<!-- Printing and PDF exports -->
<script>
var link = document.createElement( 'link' );
link.rel = 'stylesheet';
link.type = 'text/css';
link.href = window.location.search.match( /print-pdf/gi ) ? 'css/print/pdf.css' : 'css/print/paper.css';
document.getElementsByTagName( 'head' )[0].appendChild( link );
</script>
<style>
.reveal section img {
border: none;
background-color: initial;
margin: 10px;
}
.reveal .normal-paragraph {
text-align: left;
margin: 0 auto 0 auto;
width: 60%;
}
.reveal .normal-paragraph p {
text-align: left;
}
.header-left {
position: absolute;
top: 2%;
left: 2%;
}
.header-right {
position: absolute;
top: 2%;
right: 2%;
}
.footer-left {
position: absolute;
bottom: 2%;
left: 2%;
}
.reveal .genericon {
font-family: "genericons";
}
.reveal .bio-card {
background: #333;
border-radius: 2px;
display: inline-block;
width: 260px;
margin: 1rem;
position: relative;
font-size: 20px;
}
.reveal .card-photo {
display: block;
width: 200px;
border-top-left-radius: 2px;
border-top-right-radius: 2px;
margin: 28px auto 0 auto;
}
.reveal .card-header {
width: 100%;
font-size: 20px;
margin-top: 10px;
text-align: center;
}
.reveal .card-info {
width: 100%;
float: left;
font-size: 20px;
margin-top: 0;
padding: 0 4px;
text-align: center;
}
.reveal .card-info a {
text-decoration: none;
color: #999;
}
.reveal .card-info em {
vertical-align: top;
}
.revral .card-info a .genericon {
vertical-align: middle;
}
.reveal .bio-social a {
text-decoration: none;
}
.reveal .bio-photo {
width: 200px;
margin: 0 40px 40px -40px;
float: left;
}
.reveal section img {
box-shadow: none;
}
</style>
</head>
<body>
<div id="common" style="z-index: 2;">
<div class="header-left">
<img alt="QuantStack" src="quantstack-white.svg" width="30%"/>
</div>
<div class="footer-left">
<div style="color: white; font-family: Source Sans Pro, Helvetica, sans-serif;">
<img alt="Twitter" src="twitter-white.svg" height="20px"/>
<img alt="GitHub" src="github-white.svg" height="20px"/>
<p style="display: inline; vertical-align: top; margin-left: 4px; font-size: 20px;">@QuantStack</p>
</div>
</div>
</div>
<div class="reveal">
<div class="slides">
<section>
<img alt="QuantStack" src="quantstack-white.svg" width="55%">
<p>Authoring Python extensions in C++</p>
</section>
<section>
<h2>What is QuantStack</h2>
<ul>
<li>A team of open-source developers</li>
<li>Core developers of Jupyter (core, widgets, kernels)</li>
<li>Original authors of the xtensor stack</li>
<li>We offer service and enterprise support for Jupyter and xtensor</li>
</ul>
</section>
<section>
<p>The team</p>
<div class="team-section-content">
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Sylvain.jpg">
<p class="card-header">Sylvain Corlay</p>
<div class="card-info">
<a href="https://github.com/SylvainCorlay" target="_blank">
<span class="genericon genericon-github"></span>
<em>@SylvainCorlay</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/SylvainCorlay" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@SylvainCorlay</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Johan.jpg">
<p class="card-header">Johan Mabille</p>
<div class="card-info">
<a href="https://github.com/JohanMabille" target="_blank">
<span class="genericon genericon-github"></span>
<em>@JohanMabille</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/JohanMabille" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@JohanMabille</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Wolf.jpg">
<p class="card-header">Wolf Vollprecht</p>
<div class="card-info" style="display: inline;">
<a href="https://github.com/wolfv" target="_blank">
<span class="genericon genericon-github"></span>
<em>@wolfv</em>
</a>
</div>
<div class="card-info" style="display: inline;">
<a href="https://twitter.com/wuoulf" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@wuoulf</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Martin.jpg">
<p class="card-header">Martin Renou</p>
<div class="card-info" style="display: inline;">
<a href="https://github.com/martinRenou" target="_blank">
<span class="genericon genericon-github"></span>
<em>@martinRenou</em>
</a>
</div>
<div class="card-info" style="display: inline;">
<a href="https://twitter.com/Renou_Martin" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@Renou_Martin</em>
</a>
</div>
</div>
<div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Patrick.jpg">
<p class="card-header">Patrick Bos</p>
<div class="card-info">
<a href="https://github.com/egpbos" target="_blank">
<span class="genericon genericon-github"></span>
<em>@egpbos</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/egpbos" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@egpbos</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="loic.jpg">
<p class="card-header">Loic Gouarin</p>
<div class="card-info">
<a href="https://github.com/gouarin" target="_blank">
<span class="genericon genericon-github"></span>
<em>@gouarin</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/lgouarin" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@lgouarin</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Maarten.jpg">
<p class="card-header">Maarten Breddels</p>
<div class="card-info">
<a href="https://github.com/maartenbreddels" target="_blank">
<span class="genericon genericon-github"></span>
<em>@maartenbreddels</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/maartenbreddels" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@maartenbreddels</em>
</a>
</div>
</div>
<div class="bio-card">
<img class="card-photo" alt="Avatar picture" src="Romain.jpg">
<p class="card-header">Romain Menegaux</p>
<div class="card-info">
<a href="https://github.com/rmenegaux" target="_blank">
<span class="genericon genericon-github"></span>
<em>@rmenegaux</em>
</a>
</div>
<div class="card-info">
<a href="https://twitter.com/RomainMenegaux" target="_blank">
<span class="genericon genericon-twitter"></span>
<em>@RomainMenegaux</em>
</a>
</div>
</div>
</div>
</div>
</section>
<section>
<section>
<h2>Pybind11</h2>
<ul>
<li>Lightweight header-only library</li>
<li>Exposes C++ types to Python and vice versa</li>
<li>Think of it as a rewrite of Boost.Python in modern C++</li>
</ul>
</section>
<section>
<h2>Pybind11 - functional programming</h2>
<ul>
<li>Functions accepting arguments by value, reference or pointer</li>
<li>Overloaded functions</li>
<li>Custom operators</li>
<li>Callbacks</li>
</ul>
</section>
<section>
<h2>Pybind11 - OO programming</h2>
<ul>
<li>Instance methods and static methods</li>
<li>Instance attributes and static attributes</li>
<li>Single and multiple inheritance</li>
<li>C++ classes can be extended in Python</li>
</ul>
</section>
<section>
<h2>Pybind11 - STL</h2>
<ul>
<li>STL data structures</li>
<li>Iterators and ranges</li>
<li>Smart pointers</li>
<li>Exceptions</li>
</ul>
</section>
<section>
<h2>LIVE DEMO PYBIND11</h2>
</section>
</section>
<section>
<img alt="xtensor" src="xtensor.svg" width="80%"/>
<p>The Lazy Tensor Algebra Expression System</p>
<div style="width: 70%; margin: auto; font-size: 28px; text-align: left;">
<p>Xtensor is a flexible expression system in which any data structure can be plugged, offering the most expressive API to the users.</p>
</div>
</section>
<section>
<section>
<h2>What is xtensor?</h2>
<div style="margin-left: auto; margin-right: auto; width: 70%; font-size: 24px;">
<ul>
<li class="fragment">
<p>A C++ template library for multi-dimensional array manipulation</p>
<img alt="xtensor" src="xtensor.svg" width="12%"/>
<ul>
<li>
<p>Followings the idioms of the C++ STL</p>
<p>(iterator pairs, clear value semantics)</p>
</li>
<li>But also an API similar to that of numpy</li>
</ul>
</li>
</ul>
</div>
</section>
<section>
<h2>What is xtensor?</h2>
<div style="margin: auto; width: 80%; font-size: 24px;">
<ul>
<li class="fragment">
<p>Python bindings to enable xtensor APIs on numpy arrays.</p>
<img alt="xtensor-python" src="xtensor-python.svg" width="20%"/>
</li>
<li class="fragment">
<p>Julia bindings to enable xtensor APIs on Julia arrays.</p>
<img alt="xtensor-julia" src="xtensor-julia.svg" width="20%"/>
</li>
<li class="fragment">
<p>R bindings to enable xtensor APIs on R arrays.</p>
<img alt="xtensor-r" src="xtensor-r.svg" width="20%"/>
</li>
<li class="fragment">
<p>Cookiecutter projects for authoring of Python, Julia, and R extensions.</p>
<img alt="xtensor-cookiecutter" src="xtensor-cookiecutter.svg" width="20%"/>
</li>
</ul>
</div>
</section>
<section>
<h2>What is xtensor?</h2>
<div style="margin-left: auto; margin-right: auto; width: 70%; font-size: 24px;">
<ul>
<li class="fragment">
<p>BLAS bindings to enable BLAS operations on xtensor expressions.</p>
<img alt="xtensor-blas" src="xtensor-blas.svg" width="20%"/>
</li>
<li class="fragment">
<p>SIMD acceleration kernels.</p>
<img alt="xsimd" src="xsimd.svg" width="20%"/>
</li>
<li class="fragment">All open-source (BSD License).</li>
</ul>
</div>
</section>
</section>
<section>
<style>
div.splitting {
background-color: rgb(20, 98, 135);
width: 50%;
height: 800%;
position: absolute;
top: -200%;
left: 0;
z-index: -1;
}
div.left-panel {
width: 45%;
display: inline-block;
margin-right: 5%;
vertical-align: top;
}
div.right-panel {
width: 45%;
display: inline-block;
}
code.panel {
background-color: initial;
}
pre.panel {
box-shadow: none;
}
</style>
<section>
<div class="splitting"></div>
<div>
<p style="text-align: center; vertical-align: top;">Ever heard of numpy ?</p>
</div>
<div>
<div class="left-panel">
<p style="text-align: center;"><b>Python 3 - numpy</b></p>
</div>
<div class="right-panel">
<p style="text-align: center;"><b>C++ 14 - xtensor</b></p>
</div>
</div>
<div class="fragment">
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.array([[3, 4], [5, 6]])
arr.reshape([3, 4])
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::xarray<double>({{3, 4}, {5, 6}})
xt::xtensor<double, 2>({{3, 4}, {5, 6}})
arr.reshape({3, 4});
</code></pre>
</div>
</div>
<div class="fragment">
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.linspace(1.0, 10.0, 100)
np.logspace(1.0, 10.0, 100)
np.arange(3, 7)
np.eye(4)
np.zeros([3, 4])
np.ones([3, 4])
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::linspace<double>(1.0, 10.0, 100)
xt::logspace<double>(1.0, 10.0, 100)
xt::arange(3, 7)
xt::eye(4)
xt::zeros<double>({3, 4})
xt::ones<double>({3, 4})
</code></pre>
</div>
</div>
</section>
<section>
<div class="splitting"></div>
<div>
<div class="left-panel">
<p style="text-align: center;"><b>Python 3 - numpy</b></p>
</div>
<div class="right-panel">
<p style="text-align: center;"><b>C++ 14 - xtensor</b></p>
</div>
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
a[:, np.newaxis]
a[:5, 1:]
a[5:1:-1, :]
np.broadcast(a, [4, 5, 7])
np.vectorize(f)
a[a > 5]
a[[0, 1], [0, 0]]
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::view(a, xt::all(), xt::newaxis())
xt::view(a, xt::range(_, 5), xt::range(1, _))
xt::view(a, xt::range(5, 1, -1), xt::all())
xt::broadcast(a, {4, 5, 7})
xt::vectorize(f)
xt::filter(a, a > 5)
xt::index_view(a, {{0, 0}, {1, 0}})
</code></pre>
</div>
</div>
<div class="fragment">
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.sum(a, axis=[0, 1])
np.sum(a)
np.prod(a, axis=1)
np.prod(a)
np.mean(a, axis=1)
np.mean(a)
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::sum(a, {0, 1})
xt::sum(a)
xt::prod(a, {1})
xt::prod(a)
xt::mean(a, {1})
xt::mean(a)
</code></pre>
</div>
</div>
</section>
<section>
<div class="splitting"></div>
<div>
<div class="left-panel">
<p style="text-align: center;"><b>Python 3 - numpy</b></p>
</div>
<div class="right-panel">
<p style="text-align: center;"><b>C++ 14 - xtensor</b></p>
</div>
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.where(a > 5, a, b)
np.where(a > 5)
np.any(a)
np.all(a)
np.logical_and(a, b)
np.logical_or(a, b)
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::where(a > 5, a, b)
xt::where(a > 5)
xt::any(a)
xt::all(a)
a && b
a || b
</code></pre>
</div>
</div>
<div class="fragment">
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.absolute(a)
np.exp(a)
np.sqrt(a)
np.cos(a)
np.cosh(a)
scipy.special.erf(a)
np.isnan(a)
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::abs(a)
xt::exp(a)
xt::sqrt(a)
xt::cos(a)
xt::cosh(a)
xt::erf(a)
xt::isnan(a)
</code></pre>
</div>
</div>
</section>
<section>
<div class="splitting"></div>
<div>
<div class="left-panel">
<p style="text-align: center;"><b>Python 3 - numpy</b></p>
</div>
<div class="right-panel">
<p style="text-align: center;"><b>C++ 14 - xtensor</b></p>
</div>
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.random.seed(0)
np.random.randn(10, 10)
np.random.randint(10, 10)
np.random.rand(3, 4)
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::random::seed(0)
xt::random::randn<double>({10, 10})
xt::random::randint<int>({10, 10}})
xt::random::rand<double>({3, 4}})
</code></pre>
</div>
</div>
<div class="fragment">
<div class="left-panel">
<pre class="panel"><code class="python panel" data-trim>
np.stack([a, b, c], axis=1)
np.concatenate([a, b, c], axis=1)
</code></pre>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xt::stack(xtuple(a, b, c), 1)
xt::concatenate(xtuple(a, b, c), 1)
</code></pre>
</div>
</div>
</section>
</section>
<section>
<section>
<div class="splitting"></div>
<p>Broadcasting</p>
<div class="fragment" style="margin-top: 5%;">
<div class="left-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xarray<int> a = {{1, 2, 3, 4},
{5, 6, 7, 8},
{9, 10, 11, 12}};
xarray<int> b = { 1, 3, 5, 7};
</code></pre>
</div>
<div class="right-panel">
<img alt="broadcasting4.svg" src="broadcasting4.svg" width="70%"/>
</div>
</div>
<div class="fragment" style="margin-top: 5%;">
<div class="left-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xarray<int> res = a + b;
</code></pre>
</div>
<div class="right-panel">
<img alt="broadcasting5.svg" src="broadcasting5.svg" width="70%"/>
</div>
</div>
</section>
<section>
<div class="splitting"></div>
<p>Broadcasting</p>
<div style="margin-top: 2%;">
<div class="left-panel">
<pre class="panel"><code class="cpp panel" data-trim>
xarray<double> a = {1., 2., 3., 4.};
</code></pre>
</div>
<div class="right-panel">
<img alt="broadcasting1.svg" src="broadcasting1.svg" width="30%"/>
</div>
</div>
<div style="margin-top: 2%;">
<div class="left-panel fragment">
<pre class="panel"><code class="cpp panel" data-trim>
auto res = xt::broadcast(a, {3, 4});
</code></pre>
</div>
<div class="right-panel fragment">
<img alt="broadcasting2.svg" src="broadcasting2.svg" width="30%"/>
</div>
</div>
<div style="margin-top:2%;">
<div class="left-panel fragment">
<pre class="panel"><code class="cpp panel" data-trim>
xarray<double> a, b, c;
// ... initialization of a, b, and c ...
auto res = broadcast(a + b * c, {3, 4});
</code></pre>
</div>
<div class="right-panel fragment">
<img alt="broadcasting3.svg" src="broadcasting3.svg" width="30%"/>
</div>
</div>
</section>
</section>
<section>
<section>
<div class="splitting"></div>
<p>Iteration</p>
<div style="margin-top: 2%;">
<div class="left-panel">
Row-major iteration over the array <code>for x in np.nditer(a)</code>
</div>
<div class="right-panel">
<pre class="panel"><code class="cpp panel" data-trim>
for(auto it=a.begin(); it!=a.end(); ++it)
</code></pre>
</div>
</div>
<div style="margin-top: 2%;">
<div class="left-panel fragment">
Iterating over <code>a</code> with a prescribed broadcasting shape
</div>
<div class="right-panel fragment">
<pre class="panel"><code class="cpp panel" data-trim>
a.begin({3, 4})
a.end({3, 4})
</code></pre>
</div>
</div>
<div style="margin-top:2%;">
<div class="left-panel fragment">
Iterating over <code>a</code> in a column-major fashion
</div>
<div class="right-panel fragment">
<pre class="panel"><code class="cpp panel" data-trim>
a.template begin<layout_type::column_major>()
a.template end<layout_type::column_major>()
</code></pre>
</div>
</div>
<div style="margin-top:2%;">
<div class="left-panel fragment">
Iterating over <code>a</code> in a column-major fashion with a prescribed broadcasting shape
</div>
<div class="right-panel fragment">
<pre class="panel"><code class="cpp panel" data-trim>
a.template begin<layout_type::column_major>({3, 4})
a.template end<layout_type::column_major>({3, 4})
</code></pre>
</div>
</div>
</section>
</section>
<section>
<h3>How do I try it without installing anything?</h3>
<p>http://quantstack.net/xtensor</pre>
<div>
<img alt="QuantStack website" src="website.png" width="55%"/>
</div>
</section>
<section>
<h3>Language bindings with xtensor</h3>
<div><img alt="Python bingings" src="xtensor-python.svg" width="35%"/></div>
<div><img alt="JuliaLang bindings" src="xtensor-julia.svg" width="35%"/></div>
<div><img alt="R bindings" src="xtensor-r.svg" width="35%"/></div>
</section>
<section>
<h2>LIVE DEMO XTENSOR-PYTHON</h2>
</section>
<section>
<img alt="xtensor-cookiecutter" src="xtensor-cookiecutter.svg" width="70%"/>
<div style="font-size: 24px;">
<p>Generate your packaged xtensor extension</p>
<ul>
<li>With a few examples from the documentation</li>
<li>Unit-tests</li>
<li>HTML documentation</li>
<li>Packaging boilerplate (setup.py, build.jl)</li>
</ul>
</div>
</section>
<section>
<h2>Authoring extensions - Best practices</h2>
<ul>
<li>1 extension = 2 packages</li>
<li>A pure C++ library accepting any kind of expression</li>
<li>Python bindings based on xtensor-python</li>
</ul>
</section>
<section>
<h3>Continually benchmarking</h3>
<p style="font-size: 24px;">We benchmark. <br><i style="font-size: 18px;">A lot!</i></p>
<img src="benchmarks.png" width="60%"/>
</section>
<section>
<h2>Extending C++ from Python</h2>
<p>LIVE DEMO</p>
</section>
<section>
<h2>Resources:</h2>
<div style="width: 60%; margin: auto;">
<p>GitHub</p>
<ul style="font-size: 25px;">
<li>xtensor: github.com/QuantStack/xtensor/</li>
<li>xtensor-blas: github.com/QuantStack/xtensor-blas/</li>
<li>xtensor-python: github.com/QuantStack/xtensor-python/</li>
<li>xtensor-r: github.com/QuantStack/xtensor-r/</li>
<li>xtensor-julia: github.com/QuantStack/xtensor-julia/</li>
<li>xsimd: github.com/QuantStack/xsimd/</li>
<li>xtensor-fftw: github.com/egpbos/xtensor-fftw/</li>
<li>xtensor-python-cookiecutter: github.com/QuantStack/xtensor-python-cookiecutter</li>
</ul>
</div>
</section>
<section>
<h2>Resources:</h2>
<p>Documentation</p>
<ul style="font-size: 25px;">
<li>xtensor.readthedocs.io</li>
<li>xtensor-python.readthedocs.io</li>
<li>xtensor-julia.readthedocs.io</li>
<li>xtensor-r.readthedocs.io</li>
<li>xsimd.readthedocs.io</li>
</ul>
</section>
<section>
<h2>Questions?</h2>
</section>
</div>
</div>
<script src="lib/js/head.min.js"></script>
<script src="js/reveal.js"></script>
<script>
// More info https://github.com/hakimel/reveal.js#configuration
Reveal.initialize({
history: true,
width: "100%",
height: "100%",
margin: 0,
minScale: 1,
maxScale: 1,
// More info https://github.com/hakimel/reveal.js#dependencies
dependencies: [
{ src: 'plugin/markdown/marked.js' },
{ src: 'plugin/markdown/markdown.js' },
{ src: 'plugin/notes/notes.js', async: true },
{ src: 'plugin/highlight/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } }
]
});
</script>
</body>
</html>