2
2
< html xmlns ="http://www.w3.org/1999/xhtml " lang ="en " xml:lang ="en "> < head >
3
3
4
4
< meta charset ="utf-8 ">
5
- < meta name ="generator " content ="quarto-1.1.251 ">
5
+ < meta name ="generator " content ="quarto-1.3.450 ">
6
6
7
7
< meta name ="viewport " content ="width=device-width, initial-scale=1.0, user-scalable=yes ">
8
8
17
17
ul .task-list {list-style : none;}
18
18
ul .task-list li input [type = "checkbox" ] {
19
19
width : 0.8em ;
20
- margin : 0 0.8em 0.2em -1.6 em ;
20
+ margin : 0 0.8em 0.2em -1 em ; /* quarto-specific, see https://github.com/quarto-dev/quarto-cli/issues/4556 */
21
21
vertical-align : middle;
22
22
}
23
23
</ style >
55
55
"search-more-matches-text" : "more matches in this document" ,
56
56
"search-clear-button-title" : "Clear" ,
57
57
"search-detached-cancel-button-title" : "Cancel" ,
58
- "search-submit-button-title" : "Submit"
58
+ "search-submit-button-title" : "Submit" ,
59
+ "search-label" : "Search"
59
60
}
60
61
} </ script >
61
62
74
75
< span class ="navbar-title "> Parallel Python with Dask</ span >
75
76
</ a >
76
77
</ div >
78
+ < div id ="quarto-search " class ="" title ="Search "> </ div >
77
79
< button class ="navbar-toggler " type ="button " data-bs-toggle ="collapse " data-bs-target ="#navbarCollapse " aria-controls ="navbarCollapse " aria-expanded ="false " aria-label ="Toggle navigation " onclick ="if (window.quartoToggleHeadroom) { window.quartoToggleHeadroom(); } ">
78
80
< span class ="navbar-toggler-icon "> </ span >
79
81
</ button >
80
82
< div class ="collapse navbar-collapse " id ="navbarCollapse ">
81
83
< ul class ="navbar-nav navbar-nav-scroll me-auto ">
82
84
< li class ="nav-item ">
83
- < a class ="nav-link active " href ="./index.html " aria-current ="page "> Home</ a >
85
+ < a class ="nav-link active " href ="./index.html " rel ="" target ="" aria-current ="page ">
86
+ < span class ="menu-text "> Home</ span > </ a >
84
87
</ li >
85
88
< li class ="nav-item ">
86
- < a class ="nav-link " href ="./setup.html "> Setup</ a >
89
+ < a class ="nav-link " href ="./setup.html " rel ="" target ="">
90
+ < span class ="menu-text "> Setup</ span > </ a >
87
91
</ li >
88
92
< li class ="nav-item ">
89
- < a class ="nav-link " href ="./notebooks/01a-pandas_fundamentals.html "> Fundamentals</ a >
93
+ < a class ="nav-link " href ="./notebooks/01a-pandas_fundamentals.html " rel ="" target ="">
94
+ < span class ="menu-text "> Fundamentals</ span > </ a >
90
95
</ li >
91
96
< li class ="nav-item ">
92
- < a class ="nav-link " href ="./notebooks/01b-TransitionToDask.html "> Dask</ a >
97
+ < a class ="nav-link " href ="./notebooks/polars-intro.html " rel ="" target ="">
98
+ < span class ="menu-text "> Polars Dataframes</ span > </ a >
93
99
</ li >
94
100
< li class ="nav-item ">
95
- < a class ="nav-link " href ="./notebooks/01c-Scientific_Computing.html "> Scientific Computing</ a >
101
+ < a class ="nav-link " href ="./notebooks/01b-TransitionToDask.html " rel ="" target ="">
102
+ < span class ="menu-text "> Dask</ span > </ a >
96
103
</ li >
97
104
< li class ="nav-item ">
98
- < a class ="nav-link " href ="./notebooks/01d-dask_delayed.html "> Dask Delayed</ a >
105
+ < a class ="nav-link " href ="./notebooks/01c-Scientific_Computing.html " rel ="" target ="">
106
+ < span class ="menu-text "> Scientific Computing</ span > </ a >
107
+ </ li >
108
+ < li class ="nav-item ">
109
+ < a class ="nav-link " href ="./notebooks/01d-dask_delayed.html " rel ="" target ="">
110
+ < span class ="menu-text "> Dask Delayed</ span > </ a >
99
111
</ li >
100
112
</ ul >
101
- < div id ="quarto-search " class ="" title ="Search "> </ div >
113
+ < div class ="quarto-navbar-tools ms-auto ">
114
+ </ div >
102
115
</ div > <!-- /navcollapse -->
103
116
</ div > <!-- /container-fluid -->
104
117
</ nav >
@@ -133,6 +146,7 @@ <h1 class="title">Parallel Python</h1>
133
146
< div class ="quarto-title-meta ">
134
147
135
148
149
+
136
150
137
151
</ div >
138
152
@@ -144,9 +158,8 @@ <h1 class="title">Parallel Python</h1>
144
158
< h2 class ="anchored " data-anchor-id ="trainers "> Trainers</ h2 >
145
159
< ul >
146
160
< li > Kristian Maras (Kris) (MSc Mathematics / Ba Commerce)</ li >
147
- < li > Nathaniel (Nate) Butterworth (PhD Computational Geophysics),
[email protected] </ li >
148
- < li > Darya Vanichkina (PhD Bioinformatics, SFHEA)</ li >
149
- < li > Tim White (PhD Physics and Astronomy)</ li >
161
+ < li > Thomas Mauch (Thomas) (PhD in astronomy)</ li >
162
+ < li > Nathaniel (Nate) Butterworth (PhD Computational Geophysics)</ li >
150
163
</ ul >
151
164
</ section >
152
165
< section id ="course-pre-requisites-and-setup-requirements " class ="level2 ">
@@ -170,8 +183,8 @@ <h2 class="anchored" data-anchor-id="code-of-conduct">Code of Conduct</h2>
170
183
< h2 class ="anchored " data-anchor-id ="general-session-timings "> General session timings</ h2 >
171
184
< ul >
172
185
< li > A. Intoduction and Revise Python Data Manipulation and Pandas Data Structure</ li >
173
- < li > B. Dask Fundamentals and application to solving data and computationally bounded bottlenecks. </ li >
174
- < li > C. Scientific Computing Demonstration </ li >
186
+ < li > B. Why Polars is a better option for dataframes </ li >
187
+ < li > C. Why Dask provides an ecosystem of tools that can run on clusters of machines. </ li >
175
188
</ ul >
176
189
</ section >
177
190
< section id ="setup-instructions " class ="level2 ">
@@ -211,9 +224,23 @@ <h2 class="anchored" data-anchor-id="setup-instructions">Setup Instructions</h2>
211
224
icon : icon
212
225
} ;
213
226
anchorJS . add ( '.anchored' ) ;
227
+ const isCodeAnnotation = ( el ) => {
228
+ for ( const clz of el . classList ) {
229
+ if ( clz . startsWith ( 'code-annotation-' ) ) {
230
+ return true ;
231
+ }
232
+ }
233
+ return false ;
234
+ }
214
235
const clipboard = new window . ClipboardJS ( '.code-copy-button' , {
215
- target : function ( trigger ) {
216
- return trigger . previousElementSibling ;
236
+ text : function ( trigger ) {
237
+ const codeEl = trigger . previousElementSibling . cloneNode ( true ) ;
238
+ for ( const childEl of codeEl . children ) {
239
+ if ( isCodeAnnotation ( childEl ) ) {
240
+ childEl . remove ( ) ;
241
+ }
242
+ }
243
+ return codeEl . innerText ;
217
244
}
218
245
} ) ;
219
246
clipboard . on ( 'success' , function ( e ) {
@@ -225,7 +252,24 @@ <h2 class="anchored" data-anchor-id="setup-instructions">Setup Instructions</h2>
225
252
button . classList . add ( 'code-copy-button-checked' ) ;
226
253
var currentTitle = button . getAttribute ( "title" ) ;
227
254
button . setAttribute ( "title" , "Copied!" ) ;
255
+ let tooltip ;
256
+ if ( window . bootstrap ) {
257
+ button . setAttribute ( "data-bs-toggle" , "tooltip" ) ;
258
+ button . setAttribute ( "data-bs-placement" , "left" ) ;
259
+ button . setAttribute ( "data-bs-title" , "Copied!" ) ;
260
+ tooltip = new bootstrap . Tooltip ( button ,
261
+ { trigger : "manual" ,
262
+ customClass : "code-copy-button-tooltip" ,
263
+ offset : [ 0 , - 8 ] } ) ;
264
+ tooltip . show ( ) ;
265
+ }
228
266
setTimeout ( function ( ) {
267
+ if ( tooltip ) {
268
+ tooltip . hide ( ) ;
269
+ button . removeAttribute ( "data-bs-title" ) ;
270
+ button . removeAttribute ( "data-bs-toggle" ) ;
271
+ button . removeAttribute ( "data-bs-placement" ) ;
272
+ }
229
273
button . setAttribute ( "title" , currentTitle ) ;
230
274
button . classList . remove ( 'code-copy-button-checked' ) ;
231
275
} , 1000 ) ;
@@ -261,24 +305,128 @@ <h2 class="anchored" data-anchor-id="setup-instructions">Setup Instructions</h2>
261
305
return note . innerHTML ;
262
306
} ) ;
263
307
}
308
+ let selectedAnnoteEl ;
309
+ const selectorForAnnotation = ( cell , annotation ) => {
310
+ let cellAttr = 'data-code-cell="' + cell + '"' ;
311
+ let lineAttr = 'data-code-annotation="' + annotation + '"' ;
312
+ const selector = 'span[' + cellAttr + '][' + lineAttr + ']' ;
313
+ return selector ;
314
+ }
315
+ const selectCodeLines = ( annoteEl ) => {
316
+ const doc = window . document ;
317
+ const targetCell = annoteEl . getAttribute ( "data-target-cell" ) ;
318
+ const targetAnnotation = annoteEl . getAttribute ( "data-target-annotation" ) ;
319
+ const annoteSpan = window . document . querySelector ( selectorForAnnotation ( targetCell , targetAnnotation ) ) ;
320
+ const lines = annoteSpan . getAttribute ( "data-code-lines" ) . split ( "," ) ;
321
+ const lineIds = lines . map ( ( line ) => {
322
+ return targetCell + "-" + line ;
323
+ } )
324
+ let top = null ;
325
+ let height = null ;
326
+ let parent = null ;
327
+ if ( lineIds . length > 0 ) {
328
+ //compute the position of the single el (top and bottom and make a div)
329
+ const el = window . document . getElementById ( lineIds [ 0 ] ) ;
330
+ top = el . offsetTop ;
331
+ height = el . offsetHeight ;
332
+ parent = el . parentElement . parentElement ;
333
+ if ( lineIds . length > 1 ) {
334
+ const lastEl = window . document . getElementById ( lineIds [ lineIds . length - 1 ] ) ;
335
+ const bottom = lastEl . offsetTop + lastEl . offsetHeight ;
336
+ height = bottom - top ;
337
+ }
338
+ if ( top !== null && height !== null && parent !== null ) {
339
+ // cook up a div (if necessary) and position it
340
+ let div = window . document . getElementById ( "code-annotation-line-highlight" ) ;
341
+ if ( div === null ) {
342
+ div = window . document . createElement ( "div" ) ;
343
+ div . setAttribute ( "id" , "code-annotation-line-highlight" ) ;
344
+ div . style . position = 'absolute' ;
345
+ parent . appendChild ( div ) ;
346
+ }
347
+ div . style . top = top - 2 + "px" ;
348
+ div . style . height = height + 4 + "px" ;
349
+ let gutterDiv = window . document . getElementById ( "code-annotation-line-highlight-gutter" ) ;
350
+ if ( gutterDiv === null ) {
351
+ gutterDiv = window . document . createElement ( "div" ) ;
352
+ gutterDiv . setAttribute ( "id" , "code-annotation-line-highlight-gutter" ) ;
353
+ gutterDiv . style . position = 'absolute' ;
354
+ const codeCell = window . document . getElementById ( targetCell ) ;
355
+ const gutter = codeCell . querySelector ( '.code-annotation-gutter' ) ;
356
+ gutter . appendChild ( gutterDiv ) ;
357
+ }
358
+ gutterDiv . style . top = top - 2 + "px" ;
359
+ gutterDiv . style . height = height + 4 + "px" ;
360
+ }
361
+ selectedAnnoteEl = annoteEl ;
362
+ }
363
+ } ;
364
+ const unselectCodeLines = ( ) => {
365
+ const elementsIds = [ "code-annotation-line-highlight" , "code-annotation-line-highlight-gutter" ] ;
366
+ elementsIds . forEach ( ( elId ) => {
367
+ const div = window . document . getElementById ( elId ) ;
368
+ if ( div ) {
369
+ div . remove ( ) ;
370
+ }
371
+ } ) ;
372
+ selectedAnnoteEl = undefined ;
373
+ } ;
374
+ // Attach click handler to the DT
375
+ const annoteDls = window . document . querySelectorAll ( 'dt[data-target-cell]' ) ;
376
+ for ( const annoteDlNode of annoteDls ) {
377
+ annoteDlNode . addEventListener ( 'click' , ( event ) => {
378
+ const clickedEl = event . target ;
379
+ if ( clickedEl !== selectedAnnoteEl ) {
380
+ unselectCodeLines ( ) ;
381
+ const activeEl = window . document . querySelector ( 'dt[data-target-cell].code-annotation-active' ) ;
382
+ if ( activeEl ) {
383
+ activeEl . classList . remove ( 'code-annotation-active' ) ;
384
+ }
385
+ selectCodeLines ( clickedEl ) ;
386
+ clickedEl . classList . add ( 'code-annotation-active' ) ;
387
+ } else {
388
+ // Unselect the line
389
+ unselectCodeLines ( ) ;
390
+ clickedEl . classList . remove ( 'code-annotation-active' ) ;
391
+ }
392
+ } ) ;
393
+ }
394
+ const findCites = ( el ) => {
395
+ const parentEl = el . parentElement ;
396
+ if ( parentEl ) {
397
+ const cites = parentEl . dataset . cites ;
398
+ if ( cites ) {
399
+ return {
400
+ el,
401
+ cites : cites . split ( ' ' )
402
+ } ;
403
+ } else {
404
+ return findCites ( el . parentElement )
405
+ }
406
+ } else {
407
+ return undefined ;
408
+ }
409
+ } ;
264
410
var bibliorefs = window . document . querySelectorAll ( 'a[role="doc-biblioref"]' ) ;
265
411
for ( var i = 0 ; i < bibliorefs . length ; i ++ ) {
266
412
const ref = bibliorefs [ i ] ;
267
- const cites = ref . parentNode . getAttribute ( 'data-cites' ) . split ( ' ' ) ;
268
- tippyHover ( ref , function ( ) {
269
- var popup = window . document . createElement ( 'div' ) ;
270
- cites . forEach ( function ( cite ) {
271
- var citeDiv = window . document . createElement ( 'div' ) ;
272
- citeDiv . classList . add ( 'hanging-indent' ) ;
273
- citeDiv . classList . add ( 'csl-entry' ) ;
274
- var biblioDiv = window . document . getElementById ( 'ref-' + cite ) ;
275
- if ( biblioDiv ) {
276
- citeDiv . innerHTML = biblioDiv . innerHTML ;
277
- }
278
- popup . appendChild ( citeDiv ) ;
413
+ const citeInfo = findCites ( ref ) ;
414
+ if ( citeInfo ) {
415
+ tippyHover ( citeInfo . el , function ( ) {
416
+ var popup = window . document . createElement ( 'div' ) ;
417
+ citeInfo . cites . forEach ( function ( cite ) {
418
+ var citeDiv = window . document . createElement ( 'div' ) ;
419
+ citeDiv . classList . add ( 'hanging-indent' ) ;
420
+ citeDiv . classList . add ( 'csl-entry' ) ;
421
+ var biblioDiv = window . document . getElementById ( 'ref-' + cite ) ;
422
+ if ( biblioDiv ) {
423
+ citeDiv . innerHTML = biblioDiv . innerHTML ;
424
+ }
425
+ popup . appendChild ( citeDiv ) ;
426
+ } ) ;
427
+ return popup . innerHTML ;
279
428
} ) ;
280
- return popup . innerHTML ;
281
- } ) ;
429
+ }
282
430
}
283
431
} ) ;
284
432
</ script >
0 commit comments