├── .gitignore
├── Assets
├── 1024px-CRISP-DM_Process_Diagram.png
├── cleaned_pycon_au_2014_video_data.csv
├── full-stack-python-map.png
├── my_model.pkl
├── myfirstforest.csv
├── pycon_au_2014_video_data.json
├── pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore.htm
├── pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files
│ ├── a.htm
│ ├── a_data
│ │ ├── _VO8QxIkjqY.htm
│ │ ├── _VO8QxIkjqY_data
│ │ │ ├── html5player.js
│ │ │ ├── www-embed-player-vflgCpj6W.css
│ │ │ ├── www-embed-player.js
│ │ │ └── z1tsfoqMN4f_UymXs1auYUUzM2Lgo2SCiysmZHNic-8.js
│ │ ├── analytics.js
│ │ ├── bootstrap.css
│ │ ├── embedder.css
│ │ ├── embedder.js
│ │ ├── iframe_api
│ │ ├── nr-515.js
│ │ └── www-widgetapi.js
│ ├── api.js
│ ├── bootstrap.css
│ ├── bootstrap.js
│ ├── browserid.js
│ ├── communication_iframe.htm
│ ├── communication_iframe_data
│ │ └── communication_iframe.js
│ ├── embedder-iframe
│ ├── ga.js
│ ├── include.js
│ ├── jquery-1.js
│ ├── loading.gif
│ ├── persona-buttons.css
│ ├── richard.css
│ ├── videos.js
│ ├── widget.htm
│ └── widget_002.htm
├── pyvideo.org - PyCon AU 2014.htm
├── pyvideo.org - PyCon AU 2014_files
│ ├── api.js
│ ├── bootstrap.css
│ ├── bootstrap.js
│ ├── browserid.js
│ ├── communication_iframe.htm
│ ├── communication_iframe_data
│ │ └── communication_iframe.js
│ ├── ga.js
│ ├── hqdefault.jpg
│ ├── hqdefault_002.jpg
│ ├── hqdefault_003.jpg
│ ├── hqdefault_004.jpg
│ ├── hqdefault_005.jpg
│ ├── hqdefault_006.jpg
│ ├── hqdefault_007.jpg
│ ├── hqdefault_008.jpg
│ ├── hqdefault_009.jpg
│ ├── hqdefault_010.jpg
│ ├── hqdefault_011.jpg
│ ├── hqdefault_012.jpg
│ ├── hqdefault_013.jpg
│ ├── hqdefault_014.jpg
│ ├── hqdefault_015.jpg
│ ├── hqdefault_016.jpg
│ ├── hqdefault_017.jpg
│ ├── hqdefault_018.jpg
│ ├── hqdefault_019.jpg
│ ├── hqdefault_020.jpg
│ ├── hqdefault_021.jpg
│ ├── hqdefault_022.jpg
│ ├── hqdefault_023.jpg
│ ├── hqdefault_024.jpg
│ ├── hqdefault_025.jpg
│ ├── hqdefault_026.jpg
│ ├── hqdefault_027.jpg
│ ├── hqdefault_028.jpg
│ ├── hqdefault_029.jpg
│ ├── hqdefault_030.jpg
│ ├── hqdefault_031.jpg
│ ├── hqdefault_032.jpg
│ ├── hqdefault_033.jpg
│ ├── hqdefault_034.jpg
│ ├── hqdefault_035.jpg
│ ├── hqdefault_036.jpg
│ ├── hqdefault_037.jpg
│ ├── hqdefault_038.jpg
│ ├── hqdefault_039.jpg
│ ├── hqdefault_040.jpg
│ ├── hqdefault_041.jpg
│ ├── hqdefault_042.jpg
│ ├── hqdefault_043.jpg
│ ├── hqdefault_044.jpg
│ ├── hqdefault_045.jpg
│ ├── hqdefault_046.jpg
│ ├── hqdefault_047.jpg
│ ├── hqdefault_048.jpg
│ ├── hqdefault_049.jpg
│ ├── hqdefault_050.jpg
│ ├── hqdefault_051.jpg
│ ├── include.js
│ ├── jquery-1.js
│ ├── persona-buttons.css
│ ├── richard.css
│ ├── widget.htm
│ └── widget_002.htm
├── test.csv
├── top_100_hacker_news_stories.json
└── train.csv
├── Consuming APIs.ipynb
├── Flask
├── helloworld.py
└── predict.py
├── Introduction.ipynb
├── Machine Learning 101.ipynb
├── Notebooks as HTML
├── Consuming APIs.html
├── Introduction.html
├── Machine Learning 101.html
├── Python Syntax.html
├── Web Development with Flask.html
└── Web Scraping 101.html
├── Python Syntax.ipynb
├── README.md
├── Web Development with Flask.ipynb
└── Web Scraping 101.ipynb
/.gitignore:
--------------------------------------------------------------------------------
1 | #IPython
2 |
3 | .ipynb_checkpoints/
4 |
5 | #Pycharm
6 |
7 | .idea/
8 |
9 | # Byte-compiled / optimized / DLL files
10 | __pycache__/
11 | *.py[cod]
12 |
13 | # C extensions
14 | *.so
15 |
16 | # Distribution / packaging
17 | .Python
18 | env/
19 | build/
20 | develop-eggs/
21 | dist/
22 | downloads/
23 | eggs/
24 | lib/
25 | lib64/
26 | parts/
27 | sdist/
28 | var/
29 | *.egg-info/
30 | .installed.cfg
31 | *.egg
32 |
33 | # PyInstaller
34 | # Usually these files are written by a python script from a template
35 | # before PyInstaller builds the exe, so as to inject date/other infos into it.
36 | *.manifest
37 | *.spec
38 |
39 | # Installer logs
40 | pip-log.txt
41 | pip-delete-this-directory.txt
42 |
43 | # Unit test / coverage reports
44 | htmlcov/
45 | .tox/
46 | .coverage
47 | .cache
48 | nosetests.xml
49 | coverage.xml
50 |
51 | # Translations
52 | *.mo
53 | *.pot
54 |
55 | # Django stuff:
56 | *.log
57 |
58 | # Sphinx documentation
59 | docs/_build/
60 |
61 | # PyBuilder
62 | target/
63 |
--------------------------------------------------------------------------------
/Assets/1024px-CRISP-DM_Process_Diagram.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/1024px-CRISP-DM_Process_Diagram.png
--------------------------------------------------------------------------------
/Assets/cleaned_pycon_au_2014_video_data.csv:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/cleaned_pycon_au_2014_video_data.csv
--------------------------------------------------------------------------------
/Assets/full-stack-python-map.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/full-stack-python-map.png
--------------------------------------------------------------------------------
/Assets/my_model.pkl:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/my_model.pkl
--------------------------------------------------------------------------------
/Assets/myfirstforest.csv:
--------------------------------------------------------------------------------
1 | ,PassangerId,Survived
2 | 0,892,0
3 | 1,893,0
4 | 2,894,0
5 | 3,895,1
6 | 4,896,0
7 | 5,897,0
8 | 6,898,0
9 | 7,899,0
10 | 8,900,1
11 | 9,901,0
12 | 10,902,0
13 | 11,903,0
14 | 12,904,1
15 | 13,905,0
16 | 14,906,1
17 | 15,907,1
18 | 16,908,0
19 | 17,909,1
20 | 18,910,0
21 | 19,911,0
22 | 20,912,1
23 | 21,913,1
24 | 22,914,1
25 | 23,915,1
26 | 24,916,1
27 | 25,917,0
28 | 26,918,1
29 | 27,919,1
30 | 28,920,1
31 | 29,921,0
32 | 30,922,0
33 | 31,923,0
34 | 32,924,1
35 | 33,925,0
36 | 34,926,1
37 | 35,927,1
38 | 36,928,0
39 | 37,929,0
40 | 38,930,0
41 | 39,931,1
42 | 40,932,0
43 | 41,933,1
44 | 42,934,0
45 | 43,935,1
46 | 44,936,1
47 | 45,937,0
48 | 46,938,0
49 | 47,939,0
50 | 48,940,1
51 | 49,941,1
52 | 50,942,0
53 | 51,943,0
54 | 52,944,1
55 | 53,945,1
56 | 54,946,0
57 | 55,947,0
58 | 56,948,0
59 | 57,949,0
60 | 58,950,0
61 | 59,951,1
62 | 60,952,0
63 | 61,953,0
64 | 62,954,0
65 | 63,955,1
66 | 64,956,1
67 | 65,957,1
68 | 66,958,1
69 | 67,959,0
70 | 68,960,0
71 | 69,961,1
72 | 70,962,1
73 | 71,963,0
74 | 72,964,0
75 | 73,965,0
76 | 74,966,1
77 | 75,967,0
78 | 76,968,0
79 | 77,969,1
80 | 78,970,0
81 | 79,971,1
82 | 80,972,1
83 | 81,973,0
84 | 82,974,0
85 | 83,975,0
86 | 84,976,0
87 | 85,977,0
88 | 86,978,1
89 | 87,979,0
90 | 88,980,1
91 | 89,981,1
92 | 90,982,0
93 | 91,983,0
94 | 92,984,1
95 | 93,985,0
96 | 94,986,0
97 | 95,987,0
98 | 96,988,1
99 | 97,989,0
100 | 98,990,0
101 | 99,991,0
102 | 100,992,1
103 | 101,993,0
104 | 102,994,0
105 | 103,995,0
106 | 104,996,1
107 | 105,997,0
108 | 106,998,0
109 | 107,999,0
110 | 108,1000,1
111 | 109,1001,0
112 | 110,1002,0
113 | 111,1003,1
114 | 112,1004,1
115 | 113,1005,1
116 | 114,1006,1
117 | 115,1007,0
118 | 116,1008,0
119 | 117,1009,1
120 | 118,1010,0
121 | 119,1011,1
122 | 120,1012,1
123 | 121,1013,0
124 | 122,1014,1
125 | 123,1015,0
126 | 124,1016,0
127 | 125,1017,1
128 | 126,1018,0
129 | 127,1019,1
130 | 128,1020,0
131 | 129,1021,0
132 | 130,1022,1
133 | 131,1023,0
134 | 132,1024,0
135 | 133,1025,0
136 | 134,1026,0
137 | 135,1027,0
138 | 136,1028,0
139 | 137,1029,0
140 | 138,1030,0
141 | 139,1031,0
142 | 140,1032,0
143 | 141,1033,1
144 | 142,1034,0
145 | 143,1035,0
146 | 144,1036,1
147 | 145,1037,0
148 | 146,1038,0
149 | 147,1039,0
150 | 148,1040,1
151 | 149,1041,0
152 | 150,1042,1
153 | 151,1043,0
154 | 152,1044,0
155 | 153,1045,1
156 | 154,1046,0
157 | 155,1047,0
158 | 156,1048,1
159 | 157,1049,0
160 | 158,1050,1
161 | 159,1051,1
162 | 160,1052,1
163 | 161,1053,1
164 | 162,1054,1
165 | 163,1055,1
166 | 164,1056,0
167 | 165,1057,1
168 | 166,1058,0
169 | 167,1059,0
170 | 168,1060,1
171 | 169,1061,0
172 | 170,1062,0
173 | 171,1063,0
174 | 172,1064,0
175 | 173,1065,0
176 | 174,1066,0
177 | 175,1067,1
178 | 176,1068,1
179 | 177,1069,1
180 | 178,1070,1
181 | 179,1071,1
182 | 180,1072,0
183 | 181,1073,0
184 | 182,1074,1
185 | 183,1075,0
186 | 184,1076,1
187 | 185,1077,0
188 | 186,1078,1
189 | 187,1079,0
190 | 188,1080,0
191 | 189,1081,0
192 | 190,1082,0
193 | 191,1083,0
194 | 192,1084,1
195 | 193,1085,0
196 | 194,1086,1
197 | 195,1087,0
198 | 196,1088,1
199 | 197,1089,0
200 | 198,1090,0
201 | 199,1091,0
202 | 200,1092,1
203 | 201,1093,1
204 | 202,1094,0
205 | 203,1095,1
206 | 204,1096,0
207 | 205,1097,0
208 | 206,1098,0
209 | 207,1099,0
210 | 208,1100,1
211 | 209,1101,0
212 | 210,1102,0
213 | 211,1103,0
214 | 212,1104,0
215 | 213,1105,0
216 | 214,1106,0
217 | 215,1107,0
218 | 216,1108,1
219 | 217,1109,0
220 | 218,1110,1
221 | 219,1111,0
222 | 220,1112,1
223 | 221,1113,0
224 | 222,1114,1
225 | 223,1115,1
226 | 224,1116,1
227 | 225,1117,0
228 | 226,1118,0
229 | 227,1119,1
230 | 228,1120,0
231 | 229,1121,0
232 | 230,1122,0
233 | 231,1123,1
234 | 232,1124,0
235 | 233,1125,0
236 | 234,1126,1
237 | 235,1127,0
238 | 236,1128,1
239 | 237,1129,1
240 | 238,1130,1
241 | 239,1131,1
242 | 240,1132,1
243 | 241,1133,1
244 | 242,1134,0
245 | 243,1135,0
246 | 244,1136,0
247 | 245,1137,0
248 | 246,1138,1
249 | 247,1139,0
250 | 248,1140,1
251 | 249,1141,0
252 | 250,1142,1
253 | 251,1143,0
254 | 252,1144,0
255 | 253,1145,0
256 | 254,1146,0
257 | 255,1147,0
258 | 256,1148,0
259 | 257,1149,0
260 | 258,1150,1
261 | 259,1151,0
262 | 260,1152,0
263 | 261,1153,0
264 | 262,1154,1
265 | 263,1155,1
266 | 264,1156,0
267 | 265,1157,0
268 | 266,1158,0
269 | 267,1159,0
270 | 268,1160,0
271 | 269,1161,0
272 | 270,1162,0
273 | 271,1163,0
274 | 272,1164,1
275 | 273,1165,1
276 | 274,1166,0
277 | 275,1167,1
278 | 276,1168,0
279 | 277,1169,0
280 | 278,1170,0
281 | 279,1171,0
282 | 280,1172,0
283 | 281,1173,1
284 | 282,1174,1
285 | 283,1175,0
286 | 284,1176,1
287 | 285,1177,0
288 | 286,1178,0
289 | 287,1179,0
290 | 288,1180,0
291 | 289,1181,0
292 | 290,1182,0
293 | 291,1183,0
294 | 292,1184,0
295 | 293,1185,0
296 | 294,1186,0
297 | 295,1187,0
298 | 296,1188,1
299 | 297,1189,0
300 | 298,1190,0
301 | 299,1191,0
302 | 300,1192,0
303 | 301,1193,0
304 | 302,1194,0
305 | 303,1195,0
306 | 304,1196,1
307 | 305,1197,1
308 | 306,1198,1
309 | 307,1199,1
310 | 308,1200,0
311 | 309,1201,0
312 | 310,1202,0
313 | 311,1203,1
314 | 312,1204,0
315 | 313,1205,0
316 | 314,1206,1
317 | 315,1207,1
318 | 316,1208,0
319 | 317,1209,0
320 | 318,1210,0
321 | 319,1211,0
322 | 320,1212,0
323 | 321,1213,0
324 | 322,1214,0
325 | 323,1215,1
326 | 324,1216,1
327 | 325,1217,0
328 | 326,1218,1
329 | 327,1219,0
330 | 328,1220,0
331 | 329,1221,0
332 | 330,1222,1
333 | 331,1223,1
334 | 332,1224,0
335 | 333,1225,1
336 | 334,1226,0
337 | 335,1227,0
338 | 336,1228,1
339 | 337,1229,0
340 | 338,1230,0
341 | 339,1231,0
342 | 340,1232,0
343 | 341,1233,0
344 | 342,1234,0
345 | 343,1235,1
346 | 344,1236,0
347 | 345,1237,1
348 | 346,1238,0
349 | 347,1239,0
350 | 348,1240,0
351 | 349,1241,1
352 | 350,1242,1
353 | 351,1243,0
354 | 352,1244,0
355 | 353,1245,0
356 | 354,1246,1
357 | 355,1247,0
358 | 356,1248,1
359 | 357,1249,0
360 | 358,1250,0
361 | 359,1251,1
362 | 360,1252,0
363 | 361,1253,1
364 | 362,1254,1
365 | 363,1255,1
366 | 364,1256,1
367 | 365,1257,0
368 | 366,1258,0
369 | 367,1259,0
370 | 368,1260,1
371 | 369,1261,1
372 | 370,1262,0
373 | 371,1263,1
374 | 372,1264,0
375 | 373,1265,0
376 | 374,1266,1
377 | 375,1267,1
378 | 376,1268,0
379 | 377,1269,0
380 | 378,1270,0
381 | 379,1271,0
382 | 380,1272,0
383 | 381,1273,0
384 | 382,1274,1
385 | 383,1275,0
386 | 384,1276,0
387 | 385,1277,1
388 | 386,1278,0
389 | 387,1279,0
390 | 388,1280,0
391 | 389,1281,0
392 | 390,1282,0
393 | 391,1283,1
394 | 392,1284,0
395 | 393,1285,0
396 | 394,1286,0
397 | 395,1287,1
398 | 396,1288,0
399 | 397,1289,1
400 | 398,1290,0
401 | 399,1291,0
402 | 400,1292,1
403 | 401,1293,0
404 | 402,1294,1
405 | 403,1295,0
406 | 404,1296,0
407 | 405,1297,0
408 | 406,1298,0
409 | 407,1299,0
410 | 408,1300,1
411 | 409,1301,1
412 | 410,1302,1
413 | 411,1303,1
414 | 412,1304,0
415 | 413,1305,0
416 | 414,1306,1
417 | 415,1307,0
418 | 416,1308,0
419 | 417,1309,1
420 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
(Benford's) Law and Order (Fraud) by Rhys Elsmore
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 |
Description
100 |
"On the internet, fraudulent and abusive behavior is
101 | considered especially heinous. At Heroku, the dedicated detectives who
102 | investigate these vicious felonies are members of an elite squad armed
103 | with large amounts of data and spare CPU cycles. These are their
104 | stories."
105 |
Bad behavior can wreak havoc on your web application. It might be
106 | mass-signups, fraudulent orders, spammy posts, right up to automated
107 | bots designed to work around restrictions you have set in place; this
108 | can cost you time, resources, and lots of money. All is not lost though.
109 | Despite the ongoing efforts of abusers, their activity still leaves
110 | fingerprints and clues, which you can use to your advantage.
111 |
This talk is a 101 introduction to some of the methods which you can
112 | use to separate good from bad users using a combination of data mining,
113 | statistics, and some some basic machine learning. Basically, I want to
114 | get you thinking like an internet detective.
115 |
Some of the topics I will be covering include:
116 |
117 | Collecting and preparing data sources.
118 | Effective methods for classifying existing users.
119 | Feature extracting; what works and what doesn't.
120 | Analyzing user-provided data to profile your users, and weed out the bad operators.
121 | Determining a user's intentions by looking at their access patterns.
122 | Making use of 'outliers' to find suspicious users and transactions.
123 | Stopping bad users before they can wreak havoc.
124 |
125 |
As this is a 101 topic I will provide some basic examples, as well as
126 | links to more in-depth resources for further reading. I would recommend
127 | this talk to developers of web applications, especially those with a
128 | large number of users, the ability to process credit cards, or with a
129 | 'free' offering. Attendees should have a basic understanding of topics
130 | such as SQL, Pandas, and some basic understanding of mathematics and
131 | statistics, although this is not essential as I will be providing links
132 | to further reading.
133 |
134 |
135 |
136 |
137 |
138 |
219 |
220 |
221 |
222 |
223 |
224 |
258 |
259 |
260 |
261 |
262 |
263 |
264 |
265 |
266 |
267 |
268 |
269 |
270 |
271 |
282 |
283 |
284 |
285 |
286 |
296 |
297 |
298 |
299 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/a.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Amara widget
5 |
6 |
7 |
8 |
9 |
10 |
11 |
18 |
39 |
40 |
59 |
60 |
61 |
62 |
63 |
64 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/a_data/_VO8QxIkjqY_data/z1tsfoqMN4f_UymXs1auYUUzM2Lgo2SCiysmZHNic-8.js:
--------------------------------------------------------------------------------
1 | /* Anti-spam. Want to say hello? Contact (base64) Ym90Z3VhcmQtY29udGFjdEBnb29nbGUuY29t */(function(){eval('var f=this,g=function(a,b,c){if(b=typeof a,"object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;if(c=Object.prototype.toString.call(a),"[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null";else if("function"==b&&"undefined"==typeof a.call)return"object";return b},k=Array.prototype,n=function(a,b,c){return 2>=arguments.length?k.slice.call(a,b):k.slice.call(a,b,c)},r=function(a,b,c,d,e){c=a.split("."),d=f,c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(;c.length&&(e=c.shift());)c.length||void 0===b?d=d[e]?d[e]:d[e]={}:d[e]=b},t,u=(new function(){},function(a,b,c,d,e){for(a=a.replace(/\\r\\n/g,"\\n"),b=[],d=c=0;de?b[c++]=e:(2048>e?b[c++]=e>>6|192:(b[c++]=e>>12|224,b[c++]=e>>6&63|128),b[c++]=e&63|128);return b}),A=function(a,b,c,d,e,h){try{if(this.c=[],w(this,this.b,0),w(this,this.m,0),w(this,this.u,0),w(this,this.g,[]),w(this,this.d,[]),w(this,this.I,"object"==typeof window?window:f),w(this,this.L,this),w(this,this.o,0),w(this,this.w,0),w(this,this.K,0),w(this,this.h,x(4)),w(this,this.H,[]),w(this,this.n,{}),w(this,this.k,2048),this.F=true,a&&"!"==a.charAt(0))this.p=a;else{if(window.atob){for(c=window.atob(a),a=[],e=d=0;e>=8;a[d++]=h}b=a}else b=null;(this.e=b)&&this.e.length?(this.R=[],this.G()):this.f(this.T)}}catch(l){z(this,l)}},D=(A.prototype.ma=function(a,b){b.push(a[0]<<24|a[1]<<16|a[2]<<8|a[3]),b.push(a[4]<<24|a[5]<<16|a[6]<<8|a[7]),b.push(a[8]<<24|a[9]<<16|a[10]<<8|a[11])},t=A.prototype,t.d=8,t.t={},A.prototype.f=function(a,b,c,d){d=this.a(this.m),a=[a,d>>8&255,d&255],void 0!=c&&a.push(c),0==this.a(this.g).length&&(this.c[this.g]=void 0,w(this,this.g,a)),c="",b&&(b.message&&(c+=b.message),b.stack&&(c+=":"+b.stack)),b=this.a(this.k),3v;)v++,a=a[e.q];return c[e.da+q+!(!a+(v>>2))]},d[e.M]=e,c[e.Y]=a,a=void 0,d}),F=function(a,b,c,d){return c=a.a(a.b),a.e&&c>>c)}catch(e){throw e;}},t.V=33,function(a,b,c){if(b=a.a(a.b),!(b in a.e))throw a.f(a.U),a.t;return void 0==a.D&&(a.D=G(a.e,b-4),a.C=void 0),a.C!=b>>3&&(a.C=b>>3,c=[0,0,0,a.a(a.u)],a.fa=H(a.D,a.C,c)),w(a,a.b,b+1),a.e[b]^a.fa[b%8]}),J=function(a,b){return b<=a.X?b==a.g||b==a.d||b==a.h||b==a.H?a.l:b==a.J||b==a.I||b==a.L||b==a.n?a.s:b==a.v?a.j:b==a.k||b==a.w||b==a.b||b==a.m||b==a.A?2:b==a.o?1:4:[1,2,4,a.j,a.l,a.s][b%a.Z]},K=(t.H=14,t.w=16,t.b=7,function(a,b,c,d){for(b={},b.P=a.a(I(a)),b.Q=I(a),c=I(a)-1,d=I(a),b.self=a.a(d),b.B=[];c--;)d=I(a),b.B.push(a.a(d));return b}),H=(t.j=-1,t.k=0,t.A=1,t.T=17,function(a,b,c,d){try{for(d=0;84941944608!=d;)a+=(b<<4^b>>>5)+b^d+c[d&3],d+=2654435769,b+=(a<<4^a>>>5)+a^d+c[d>>>11&3];return[a>>>24,a>>16&255,a>>8&255,a&255,b>>>24,b>>16&255,b>>8&255,b&255]}catch(e){throw e;}}),L=(t.M="toString",function(a,b,c){return c=function(){return a},b=function(){return c()},b.ia=function(b){a=b},b}),M=function(a,b,c,d){return function(){if(!d||a.F)return w(a,a.J,arguments),w(a,a.n,c),F(a,b)}},C=(t.ca=42,function(a,b,c,d){for(d=b-1,c=[];0<=d;d--)c[b-1-d]=a>>8*d&255;return c}),w=(A.prototype.a=function(a,b){if(b=this.c[a],void 0===b)throw this.f(this.W,0,a),this.t;return b()},t.X=17,t.O=[function(a,b,c,d){b=I(a),c=a.a(I(a)),d=a.a(I(a)),w(a,b,M(a,c,d))},function(a,b,c,d){b=I(a),c=I(a),d=I(a),a.a(b)>a.a(c)&&w(a,d,a.a(d)+1)},function(a,b,c){b=I(a),c=I(a),w(a,c,a.a(c)*a.a(b))},function(a,b){b=a.a(I(a)),E(a,b)},function(a,b,c,d,e){b=I(a),c=I(a),d=J(a,b),e=J(a,c),c!=a.g&&(d==a.j&&e==a.j?(void 0==a.c[c]&&w(a,c,""),w(a,c,a.a(c)+a.a(b))):e==a.l&&(0>d?(b=a.a(b),d==a.j&&(b=u(""+b)),B(a,c,C(b.length,2)),B(a,c,b)):0>c)},function(a){I(a)},function(a,b,c){b=I(a),c=I(a),0!=a.a(b)&&w(a,a.b,a.a(c))},function(){},function(a,b,c,d,e){b=K(a),e=b.P,d=b.self,c=b.B;switch(c.length){case 0:c=new d[e];break;case 1:c=new d[e](c[0]);break;case 2:c=new d[e](c[0],c[1]);break;case 3:c=new d[e](c[0],c[1],c[2]);break;case 4:c=new d[e](c[0],c[1],c[2],c[3]);break;default:a.f(a.r);return}w(a,b.Q,c)},function(a,b,c,d,e){b=I(a),c=a.a(I(a)),d=a.a(I(a)),e=a.a(I(a)),a.a(b).addEventListener(c,M(a,d,e,true),false)},function(a,b,c,d,e,h){if(b=I(a),c=I(a),d=I(a),e=I(a),b=a.a(b),c=a.a(c),d=a.a(d),a=a.a(e),"object"==g(b)){for(h in e=[],b)e.push(h);b=e}for(e=0,h=b.length;el?c[h++]=String.fromCharCode(l):191l?(p=d[e++],c[h++]=String.fromCharCode((l&31)<<6|p&63)):(p=d[e++],m=d[e++],c[h++]=String.fromCharCode((l&15)<<12|(p&63)<<6|m&63));c=c.join("")}else for(c=Array(d),e=0;ec;c++)b[c]+=a[c];for(c=0,d=[13,8,13,12,16,5,3,10,15];9>c;c++)b[3](b,c%3,d[c])}},t.$=15,t.aa=12,function(a,b){a.p=("E:"+b.message+":"+b.stack).slice(0,2048)}),E=function(a,b){a.R.push(a.c.slice()),a.c[a.b]=void 0,w(a,a.b,b)},B=function(a,b,c,d,e,h){for(e=a.a(b),b=b==a.h?function(b,c,d,h){if(c=e.length,d=c-4>>3,e.ga!=d){e.ga=d,d=(d<<3)-4,h=[0,0,0,a.a(a.K)];try{e.ea=H(G(e,d),G(e,d+4),h)}catch(q){throw q;}}e.push(e.ea[c&7]^b)}:function(a){e.push(a)},d&&b(d&255),h=0,d=c.length;ha.length)return String.fromCharCode.apply(null,a);for(c=0,b="";ce.max&&(e.max=n),ne)return n.slice(0,r).join("");return n.join("")}function i(n,e){var t=0,o="";return u(n,function(n,i){var a,u,s=[];if("string"==typeof i)a="&"+n+"="+r(i),t+=a.length,o+=a;else if(i.length){for(t+=9,u=0;u=e));u++)s.push(a);o+="&"+n+"=%5B"+s.join(",")+"%5D"}}),o}function a(n,e){return e&&"string"==typeof e?"&"+n+"="+r(e):""}var u=n(1),s={"%2C":",","%3A":":","%2F":"/","%40":"@","%24":"$","%3B":";"},f=n(2),c=u(s,function(n){return n}),l=new RegExp(c.join("|"),"g");e.exports={obj:i,fromArray:o,qs:r,param:a}},{1:22,2:13}],4:[function(n,e){function t(n){return n&&n.url?n.jsonp?t.jsonp(n.url,n.jsonp):n.body||n.xhr?t.xhr(n.url,n.body):t.img(n.url):!1}e.exports=t,t.jsonp=function(n,e){var t=document.createElement("script");return t.type="text/javascript",t.src=n+"&jsonp="+e,document.body.appendChild(t),t},t.xhr=function(n,e){var t=new XMLHttpRequest;return t.open("POST",n),t.send(e),t},t.img=function(n){var e=new Image;return e.src=n,e}},{}],5:[function(n,e){function t(n,e){if(n.info.beacon){n.info.queueTime&&e.store("measures","qt",{value:n.info.queueTime}),n.info.applicationTime&&e.store("measures","ap",{value:n.info.applicationTime}),e.measure("be","starttime","firstbyte"),e.measure("fe","firstbyte","onload"),e.measure("dc","firstbyte","domContent");var t=e.get("measures"),r=p(t,function(n,e){return"&"+n+"="+e.params.value}).join("");if(r){var o="1",i=[c(n)];if(i.push(r),i.push(v("tt",n.info.ttGuid)),i.push(v("us",n.info.user)),i.push(v("ac",n.info.account)),i.push(v("pr",n.info.product)),i.push(v("tk",n.info.agentToken)),i.push(v("f",g(p(n.features,function(n){return n})))),window.performance&&"undefined"!=typeof window.performance.timing){var a={};a.timing=m.addPT(window.performance.timing,{}),a.navigation=m.addPN(window.performance.navigation,{}),i.push(v("perf",g(a)))}i.push(v("xx",n.info.extra)),i.push(v("ua",n.info.userAttributes)),i.push(v("at",n.info.atts)),y({url:n.proto+n.info.beacon+"/"+o+"/"+n.info.licenseKey+h.fromArray(i,n.maxBytes),jsonp:w})}}}function r(n,e){var t=!1;return p(k,function(r){var i=o(r,n,e);i&&(t=!0)}),t}function o(n,e,t){var r=i(n,t);return a(e,n,r.body,r.qs,t)}function i(n,e){for(var t=l({}),r=l({}),o=k[n]||[],i=0;i
";var o=r.getElementsByTagName("div").length;t.ieVersion=4===o?6:3===o?7:2===o?8:1===o?9:0,e.exports=t.ieVersion},{loader:!1}],7:[function(n){function e(n){p.emit("rates",[n])}function t(n,e,t,r,o,i){if(m+=1,d.info.beacon){var a=d.proto+d.info.beacon+"/1/"+d.info.licenseKey;a+="?a="+d.info.applicationID+"&",a+="t="+n+"&",a+="qt="+e+"&",a+="ap="+t+"&",a+="be="+r+"&",a+="dc="+o+"&",a+="fe="+i+"&",a+="c="+m,f({url:a})}}function r(n){var e="s";"pagehide"===n.type&&(e="h"),a.navCookie&&(document.cookie="NREUM="+e+"="+Number(new Date)+"&r="+o(document.location.href)+"&p="+o(document.referrer)+"; path=/")}var o=n(1),i=n(2),a=n(6),u=n(7),s=n(9),f=n(3),c=n(8),l=n(4),d=n("loader"),p=n("ee"),m=0,h="undefined"!=typeof window.NREUM.autorun?window.NREUM.autorun:!0;window.NREUM.setToken=e,window.NREUM.inlineHit=t,d.maxBytes=6===n(5)?2e3:3e4;var v=s(r);i("beforeunload",v),i("pagehide",v),i("unload",function(){c.sendAll(d,!1)}),l("mark",u.mark),u.mark("done"),h&&c.sendBeacon(d,u)},{1:10,2:1,3:4,4:9,5:6,6:12,7:2,8:5,9:11,ee:!1,loader:!1}],8:[function(n,e){function t(n,e){var t=n.navigationStart;return e.of=t,o(n.navigationStart,t,e,"n"),o(n.unloadEventStart,t,e,"u"),o(n.unloadEventEnd,t,e,"ue"),o(n.domLoading,t,e,"dl"),o(n.domInteractive,t,e,"di"),o(n.domContentLoadedEventStart,t,e,"ds"),o(n.domContentLoadedEventEnd,t,e,"de"),o(n.domComplete,t,e,"dc"),o(n.loadEventStart,t,e,"l"),o(n.loadEventEnd,t,e,"le"),o(n.redirectStart,t,e,"r"),o(n.redirectEnd,t,e,"re"),o(n.fetchStart,t,e,"f"),o(n.domainLookupStart,t,e,"dn"),o(n.domainLookupEnd,t,e,"dne"),o(n.connectStart,t,e,"c"),o(n.connectEnd,t,e,"ce"),o(n.secureConnectionStart,t,e,"s"),o(n.requestStart,t,e,"rq"),o(n.responseStart,t,e,"rp"),o(n.responseEnd,t,e,"rpe"),e}function r(n,e){return o(n.type,0,e,"ty"),o(n.redirectCount,0,e,"rc"),e}function o(n,e,t,r){"number"==typeof n&&n>0&&(t[r]=Math.round(n-e))}e.exports={addPT:t,addPN:r}},{}],9:[function(n,e){function t(n,e){if(r.listeners(n).length)return!1;r.on(n,e);var t=r.q[n];if(t){for(var o=0;ot)return}return"undefined"!=typeof window.performance&&window.performance.timing&&"undefined"!=typeof window.performance.timing.navigationStart?(e.exports.navCookie=!1,window.performance.timing.navigationStart):void 0}function o(){for(var n=document.cookie.split(" "),e=0;e6e4)return;return o}}}var i=n(1),a=n(2),u=n("loader");e.exports={navCookie:!0},t()},{1:10,2:2,loader:!1}],13:[function(n,e){function t(n){try{return o("",{"":n})}catch(e){try{a.emit("internal-error",[e])}catch(t){}}}function r(n){return u.lastIndex=0,u.test(n)?'"'+n.replace(u,function(n){var e=s[n];return"string"==typeof e?e:"\\u"+("0000"+n.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+n+'"'}function o(n,e){var t=e[n];switch(typeof t){case"string":return r(t);case"number":return isFinite(t)?String(t):"null";case"boolean":return String(t);case"object":if(!t)return"null";var a=[];if("[object Array]"===Object.prototype.toString.apply(t)){for(var u=t.length,s=0;u>s;s+=1)a[s]=o(s,t)||"null";return 0===a.length?"[]":"["+a.join(",")+"]"}return i(t,function(n){var e=o(n,t);e&&a.push(r(n)+":"+e)}),0===a.length?"{}":"{"+a.join(",")+"}"}}var i=n(1),a=n("ee"),u=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,s={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};e.exports=t},{1:22,ee:!1}],14:[function(n,e){function t(n){if(n){var e=n.match(r);return e?e[1]:void 0}}var r=/([a-z0-9]+)$/i;e.exports=t},{}],15:[function(n,e){function t(n){var e=n.match(r);return e?e[3]?e[1]+e[3]:e[1]:null}e.exports=t;var r=/^([^?]+)(\?[^#]*)?(#.*)?$/},{}],16:[function(n,e){function t(n,e){return Object.prototype.hasOwnProperty.call(n,e)}e.exports=function(){function n(n){var e=l.exec(String(n.constructor));return e&&e.length>1?e[1]:"unknown"}function e(n){return n&&n.indexOf("nrWrapper")>=0}function r(n){return n?n.replace(d,""):null}function o(t){if(!t.stack)return null;for(var o,i,a=/^\s*at (?:((?:\[object object\])?(?:[^(]*\([^)]*\))*[^()]*(?: \[as \S+\])?) )?\(?((?:file|http|https|chrome-extension):.*?)?:(\d+)(?::(\d+))?\)?\s*$/i,u=/^\s*(?:(\S*)(?:\(.*?\))?@)?((?:file|http|https|chrome|safari-extension).*?):(\d+)(?::(\d+))?\s*$/i,s=/^\s*at .+ \(eval at \S+ \((?:(?:file|http|https):[^)]+)?\)(?:, [^:]*:\d+:\d+)?\)$/i,f=/^\s*at Function code \(Function code:\d+:\d+\)\s*/i,c=t.stack.split("\n"),l=[],d=[],p=!1,m=(/^(.*) is undefined$/.exec(t.message),0),h=c.length;h>m;++m){if(o=u.exec(c[m]))i={url:o[2],func:o[1]||null,line:+o[3],column:o[4]?+o[4]:null};else if(o=a.exec(c[m]))i={url:o[2],func:o[1]||null,line:+o[3],column:o[4]?+o[4]:null},"Anonymous function"===i.func&&(i.func=null);else{if(!s.exec(c[m])&&!f.exec(c[m])&&"anonymous"!==c[m]){d.push(c[m]);continue}i={func:"evaluated code"}}e(i.func)?p=!0:d.push(c[m]),p||l.push(i)}return l.length?{mode:"stack",name:t.name||n(t),message:t.message,stackString:r(d.join("\n")),frames:l}:null}function i(t){for(var o,i=t.stacktrace,a=/ line (\d+), column (\d+) in (?:]+)>|([^\)]+))\(.*\) in (.*):\s*$/i,u=i.split("\n"),s=[],f=[],c=!1,l=0,d=u.length;d>l;l+=2)if(o=a.exec(u[l])){var p={line:+o[1],column:+o[2],func:o[3]||o[4],url:o[5]};e(p.func)?c=!0:f.push(u[l]),c||s.push(p)}else f.push(u[l]);return s.length?{mode:"stacktrace",name:t.name||n(t),message:t.message,stackString:r(f.join("\n")),frames:s}:null}function a(o){var i=o.message.split("\n");if(i.length<4)return null;var a,u,s,f=/^\s*Line (\d+) of linked script ((?:file|http|https)\S+)(?:: in function (\S+))?\s*$/i,c=/^\s*Line (\d+) of inline#(\d+) script in ((?:file|http|https)\S+)(?:: in function (\S+))?\s*$/i,l=/^\s*Line (\d+) of function script\s*$/i,d=[],p=[],m=document.getElementsByTagName("script"),h=[],v=!1;for(u in m)t(m,u)&&!m[u].src&&h.push(m[u]);for(u=2,s=i.length;s>u;u+=2){var g=null;if(a=f.exec(i[u]))g={url:a[2],func:a[3],line:+a[1]};else if(a=c.exec(i[u]))g={url:a[3],func:a[4]};else if(a=l.exec(i[u])){var y=window.location.href.replace(/#.*$/,""),x=a[1];g={url:y,line:x,func:""}}g&&(e(g.func)?v=!0:p.push(i[u]),v||d.push(g))}return d.length?{mode:"multiline",name:o.name||n(o),message:i[0],stackString:r(p.join("\n")),frames:d}:null}function u(e){if(!("line"in e))return null;var t=e.name||n(e);if(!e.sourceURL)return{mode:"sourceline",name:t,message:e.message,stackString:n(e)+": "+e.message+"\n in evaluated code",frames:[{func:"evaluated code"}]};var r=t+": "+e.message+"\n at "+e.sourceURL;return e.line&&(r+=":"+e.line,e.column&&(r+=":"+e.column)),{mode:"sourceline",name:t,message:e.message,stackString:r,frames:[{url:e.sourceURL,line:e.line,column:e.column}]}}function s(e){var t=e.name||n(e);return t?{mode:"nameonly",name:t,message:e.message,stackString:t+": "+e.message,frames:[]}:null}function f(n){var e=null;try{if(e=i(n))return e}catch(t){if(c)throw t}try{if(e=o(n))return e}catch(t){if(c)throw t}try{if(e=a(n))return e}catch(t){if(c)throw t}try{if(e=u(n))return e}catch(t){if(c)throw t}try{if(e=s(n))return e}catch(t){if(c)throw t}return{mode:"failed",stackString:"",frames:[]}}var c=!1,l=/function (.+)\(/,d=/^\n+|\n+$/g;return f}()},{}],17:[function(n,e){function t(n){return s(n.exceptionClass)^n.stackHash}function r(n,e,r){var d=u(n);e||(e=(new Date).getTime());for(var p="",m=0;m"),p+=h.url),h.line&&(p+=":"+h.line)}var g={stackHash:s(p),exceptionClass:d.name,request_uri:window.location.pathname};if(d.message&&(g.message=d.message),c[g.stackHash]?g.browser_stack_hash=s(d.stackString):(c[g.stackHash]=!0,g.stack_trace=d.stackString),document.referrer){var y=a(document.referrer);y&&(g.request_referer=y)}var x=t(g);l[x]||(g.pageview=1,l[x]=!0),o.store(r?"ierr":"err",x,g,{time:e-f.offset})}var o=n(1),i=n(5),a=n(6),u=n(7),s=n(8),f=n("loader"),c={},l={},d=n(2),p=n(3);n(4),f.features.err&&(p.on("jserrors",function(){return{body:o.take(["err","ierr"])}}),p.pingErrors(f),setInterval(function(){var n=p.sendX("jserrors",f,!1);n||p.pingErrors(f)},6e4),d("err",r),d("ierr",r),e.exports=r)},{1:2,2:9,3:5,4:12,5:14,6:15,7:16,8:18,loader:!1}],18:[function(n,e){function t(n){var e,t=0;if(!n||!n.length)return t;for(var r=0;r0&&(r=n[e]-w.offset,c({n:e,s:r,e:r,o:"document",t:"timing"}))}function r(n,e,t,r){var o={n:r,s:e-w.offset,e:t-w.offset,o:"window",t:"timer"};c(o)}function o(n,e,t,r){if(n.type in T)return!1;var o={n:i(n.type),s:t-w.offset,e:r-w.offset,o:a(n.target,e),t:"event"};c(o)}function i(n){var e=n;return b(q,function(t,r){n in r&&(e=t)}),e}function a(n,e){var t="unknown";if(n&&n instanceof XMLHttpRequest){var r=n["nr@context"].params;t=r.status+" "+r.method+": "+r.host+r.pathname}else n&&"string"==typeof n.tagName&&(t=n.tagName.toLowerCase(),n.id&&(t+="#"+n.id),n.className&&(t+="."+E(n.classList).join(".")));return"unknown"===t&&(e===document?t="document":e===window?t="window":e instanceof FileReader&&(t="FileReader")),t}function u(n,e,t){var r={n:"history.pushState",s:t-w.offset,e:t-w.offset,o:n,t:e};c(r)}function s(n){n.forEach(function(n){var e=S(n.name),t={n:n.initiatorType,s:0|n.fetchStart,e:0|n.responseEnd,o:e.protocol+"://"+e.hostname+":"+e.port+e.pathname,t:n.entryType};t.st.s-e?o.e=t.e:r.push(t),n}}function h(n,e){return e}function v(n,e){return n.concat(e)}function g(){}var y=n(1),x=n(2),w=(n(3),n("loader")),b=n(5),k=n(6),E=n(8),S=n(7),j="",T={mouseup:!0,mousedown:!0},A={typing:1e3,scrolling:1e3,mousing:1e3,touching:1e3},q={typing:{keydown:!0,keyup:!0,keypress:!0},mousing:{mousemove:!0,mouseenter:!0,mouseleave:!0,mouseover:!0,mouseout:!0},scrolling:{scroll:!0},touching:{touchstart:!0,touchmove:!0,touchend:!0,touchcancel:!0,touchenter:!0,touchleave:!0}},N={},_=n("ee");if(e.exports={_takeSTNs:d},n(4),w.features.stn){var C=setTimeout(function(){y("bst",g),y("bstTimer",g),y("bstResource",g),y("bstHist",g),y("bstAgg",g),y("bstApi",g)},1e4);_.on("rates",function(n){if(n&&n.stn){clearTimeout(C),t(window.performance.timing),x.on("resources",l(d));var e=x.sendX("resources",w,!0);e.addEventListener("load",function(){j=this.responseText},!1),y("bst",o),y("bstTimer",r),y("bstResource",s),y("bstHist",u),y("bstAgg",f),y("bstApi",c),setInterval(function(){var n=0;return Date.now()-w.offset>9e5?void(N={}):(b(N,function(e,t){t&&t.length&&(n+=t.length)}),n>30&&x.sendX("resources",w,!0),void(n>1e3&&(N={})))},1e4)}});var L=0}},{1:9,2:5,3:2,4:12,5:22,6:24,7:21,8:23,ee:!1,loader:!1}],20:[function(n,e){function t(n,e,t){e.time=t-u.offset,n.cat?r.store("xhr",a([n.status,n.cat]),n,e):r.store("xhr",a([n.status,n.host,n.pathname]),n,e)}var r=n(1),o=n(2),i=n(3),a=n(4),u=n("loader");u.features.xhr&&(i.on("jserrors",function(){return{body:r.take(["xhr"])}}),o("xhr",t),e.exports=t)},{1:2,2:9,3:5,4:13,loader:!1}],21:[function(n,e){e.exports=function(n){var e=document.createElement("a"),t=window.location,r={};e.href=n,r.port=e.port;var o=e.href.split("://");return!r.port&&o[1]&&(r.port=o[1].split("/")[0].split("@").pop().split(":")[1]),r.port&&"0"!==r.port||(r.port="https"===o[0]?"443":"80"),r.hostname=e.hostname||t.hostname,r.pathname=e.pathname,r.protocol=o[0],"/"!==r.pathname.charAt(0)&&(r.pathname="/"+r.pathname),r.sameOrigin=!e.hostname||e.hostname===document.domain&&e.port===t.port&&e.protocol===t.protocol,r}},{}],22:[function(n,e){function t(n,e){var t=[],o="",i=0;for(o in n)r.call(n,o)&&(t[i]=e(o,n[o]),i+=1);return t}var r=Object.prototype.hasOwnProperty;e.exports=t},{}],23:[function(n,e){function t(n,e,t){e||(e=0),"undefined"==typeof t&&(t=n?n.length:0);for(var r=-1,o=t-e||0,i=Array(0>o?0:o);++r>>0),ba=0;function ca(a,b,c){return a.call.apply(a.bind,arguments)}
4 | function da(a,b,c){if(!a)throw Error();if(2b?1:0};var w=Array.prototype,fa=w.indexOf?function(a,b,c){return w.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(p(a))return p(b)&&1==b.length?a.indexOf(b,c):-1;for(;cc?null:p(a)?a.charAt(c):a[c]}function ha(a){return w.concat.apply(w,arguments)}function ia(a){var b=a.length;if(0parseFloat(a))?String(b):a}(),qa={};
9 | function ra(a){if(!qa[a]){for(var b=0,c=ea(String(pa)).split("."),d=ea(String(a)).split("."),e=Math.max(c.length,d.length),f=0;0==b&&fb?e+="000":256>b?e+="00":4096>b&&(e+="0");return G[a]=e+b.toString(16)}),'"')};function H(){this.k=this.k;this.t=this.t}H.prototype.k=!1;H.prototype.dispose=function(){this.k||(this.k=!0,this.H())};H.prototype.H=function(){if(this.t)for(;this.t.length;)this.t.shift()()};function I(){H.call(this);this.d=[];this.j={}}u(I,H);g=I.prototype;g.O=1;g.D=0;g.subscribe=function(a,b,c){var d=this.j[a];d||(d=this.j[a]=[]);var e=this.O;this.d[e]=a;this.d[e+1]=b;this.d[e+2]=c;this.O=e+3;d.push(e);return e};g.unsubscribe=function(a,b,c){if(a=this.j[a]){var d=this.d;if(a=ga(a,function(a){return d[a+1]==b&&d[a+2]==c}))return Aa(this,a)}return!1};
13 | function Aa(a,b){if(0!=a.D)return a.o||(a.o=[]),a.o.push(b),!1;var c=a.d[b];if(c){var d=a.j[c];if(d){var e=fa(d,b);0<=e&&w.splice.call(d,e,1)}delete a.d[b];delete a.d[b+1];delete a.d[b+2]}return!!c}g.publish=function(a,b){var c=this.j[a];if(c){this.D++;for(var d=Array(arguments.length-1),e=1,f=arguments.length;ed)b=null;else{e=b.indexOf("&",d);if(0>e||e>c)e=c;d+=a.length+1;b=decodeURIComponent(b.substr(d,e-d).replace(/\+/g," "))}null===b||(l[a]=b)});c.src=S(a.j,"host")+a.G()+"?"+Sa(l);return c}
26 | g.P=function(){this.d&&this.d.contentWindow?this.J({event:"listening"}):window.clearInterval(this.k)};function ab(a){db(a.j,a,a.L);a.k=Ja(r(a.P,a));Qa(a.d,"load",r(function(){window.clearInterval(this.k);this.k=Ja(r(this.P,this))},a))}function cb(a,b){a.N[b]||(a.N[b]=!0,U(a,"addEventListener",[b]))}
27 | g.J=function(a){a.id=this.L;var b=[];F(new xa,a,b);a=b.join("");var b=this.j,c,d=Ca(this.d.src);c=d[1];var e=d[2],f=d[3],d=d[4],k="";c&&(k+=c+":");f&&(k+="//",e&&(k+=e+"@"),k+=f,d&&(k+=":"+d));c=k;b=0==c.indexOf("https:")?[c]:b.d?[c.replace("http:","https:")]:b.k?[c]:[c,c.replace("http:","https:")];for(c=0;c=c.length)throw eb;var d;d=c.key(b++);if(a)return d;d=c.getItem(d);if(!p(d))throw"Storage mechanism: Invalid value was encountered";return d};return d};V.prototype.key=function(a){return this.d.key(a)};function ib(){var a=null;try{a=window.localStorage||null}catch(b){}this.d=a}u(ib,V);function jb(){var a=null;try{a=window.sessionStorage||null}catch(b){}this.d=a}u(jb,V);(new ib).isAvailable();(new jb).isAvailable();function kb(a){return(0==a.search("cue")||0==a.search("load"))&&"loadModule"!=a}function lb(a){return 0==a.search("get")||0==a.search("is")};var mb="corp.google.com googleplex.com youtube.com youtube-nocookie.com youtubeeducation.com borg.google.com prod.google.com sandbox.google.com docs.google.com drive.google.com mail.google.com photos.google.com plus.google.com play.google.com googlevideo.com talkgadget.google.com survey.g.doubleclick.net youtube.googleapis.com vevo.com".split(" "),nb="";function W(a){this.j=a||{};this.defaults={};this.defaults.host="http://www.youtube.com";this.defaults.title="";this.k=this.d=!1;a=document.getElementById("www-widgetapi-script");if(this.d=!!("https:"==document.location.protocol||a&&0==a.src.indexOf("https:"))){a=[this.j,window.YTConfig||{},this.defaults];for(var b=0;b
2 |
8 |
9 | non-interactive iframe
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/embedder-iframe:
--------------------------------------------------------------------------------
1 |
2 | // This must be done when the js file is first loaded
3 | var scriptFiles = document.getElementsByTagName("script");
4 | var THIS_JS_FILE = scriptFiles[scriptFiles.length-1].src;
5 |
6 | (function(window) {
7 | var AmaraIframeController = function() {
8 | var iframes = [];
9 | var loadingDivs = [];
10 | var timers = [];
11 | var iframeDomain = '';
12 | var resize = function(index, width, height) {
13 | if (iframes[index].style.visibility == "visible")
14 | iframes[index].parentNode.style.height = "";
15 | iframes[index].width = 0;
16 | iframes[index].width = width;
17 | iframes[index].height = height;
18 | };
19 | var updateContent = function(index, content) {
20 | iframes[index].innerHTML = content;
21 | };
22 | var updateLoading = function(index, error) {
23 | if (error) {
24 | loadingDivs[index].innerHTML = "This video type is not supported by the Amara embedder. You can check if your hosting service offers HTML5 video resources.";
25 | } else {
26 | loadingDivs[index].style.display = "none";
27 | iframes[index].style.visibility = "visible";
28 | iframes[index].style.opacity = 1;
29 | iframes[index].parentNode.style.backgroundColor = "transparent";
30 | }
31 | };
32 | this.resizeReceiver = function(e) {
33 | if (e.data.initDone)
34 | window.clearInterval(timers[e.data.index]);
35 | if (e.data.resize)
36 | resize(e.data.index, e.data.width, e.data.height);
37 | if (e.data.content)
38 | updateContent(e.data.index, e.data.content);
39 | if (e.data.error == window.MediaError.MEDIA_ERR_SRC_NOT_SUPPORTED)
40 | updateLoading(e.data.index, true);
41 | if (e.data.videoReady)
42 | updateLoading(e.data.index);
43 | if (e.data.thumbnailReady)
44 | updateLoading(e.data.index);
45 | };
46 |
47 | this.initIframes = function(elements) {
48 | var parser = document.createElement('a');
49 | parser.href = THIS_JS_FILE;
50 | iframeDomain = parser.protocol + '//' + parser.host;
51 | for (var i = 0 ; i < elements.length ; i++) {
52 | var currentDiv = elements[i];
53 | var noanalytics = false;
54 | var loadingDiv = document.createElement("DIV");
55 | if (currentDiv.dataset.noanalytics)
56 | noanalytics = true;
57 | if (currentDiv.dataset.width)
58 | currentDiv.style.width = currentDiv.dataset.width;
59 | if (currentDiv.dataset.height)
60 | currentDiv.style.height = (36 + parseInt(currentDiv.dataset.height)) + "px";
61 | currentDiv.style.backgroundColor = "#1b1c1d";
62 | currentDiv.style.color = "white";
63 | if (currentDiv.dataset.height)
64 | loadingDiv.style.paddingTop = ((36 + parseInt(currentDiv.dataset.height)) / 2 - 33) + "px";
65 | else
66 | loadingDiv.style.paddingTop = "200px";
67 | loadingDiv.style.paddingLeft = loadingDiv.style.paddingRight = "50px";
68 | loadingDiv.style.textAlign = "center";
69 | loadingImg = document.createElement("IMG");
70 | loadingImg.src = "//s3.amazonaws.com/s3.www.universalsubtitles.org/32604e97/images/embedder/loading.gif";
71 | loadingDiv.appendChild(loadingImg);
72 | currentDiv.appendChild(loadingDiv);
73 |
74 | var iframe = document.createElement("IFRAME");
75 | iframe.src = parser.protocol + "//" + parser.host + "/embedder-widget-iframe/";
76 | if (noanalytics) iframe.src += "noanalytics/";
77 | iframe.src += "?data=" +
78 | encodeURIComponent(JSON.stringify(currentDiv.dataset));
79 | iframe.style.border = "none";
80 | iframe.style.overflow = "hidden";
81 | iframe.scrolling = "no";
82 | iframe.style.opacity = 0;
83 | currentDiv.appendChild(iframe);
84 | loadingDivs.push(loadingDiv);
85 | iframes.push(iframe);
86 | }
87 | };
88 | this.initResize = function() {
89 | var controller = this;
90 | iframes.forEach(function(iframe, index) {
91 | timers.push(window.setInterval(function() {
92 | controller.postToIframe(iframe, index);
93 | }
94 | ,100));
95 | });
96 | };
97 | this.postToIframe = function(iframe, index) {
98 | if (iframe.contentWindow) {
99 | iframe.contentWindow.postMessage({fromIframeController: true, index: index}, iframeDomain);
100 | }
101 | };
102 | };
103 | window.AmaraIframeController = AmaraIframeController;
104 |
105 | var initIframeController = function() {
106 | var controller = new window.AmaraIframeController();
107 | window.addEventListener('message', controller.resizeReceiver, false);
108 | controller.initIframes(document.getElementsByClassName("amara-embed"));
109 | controller.initResize();
110 | document.addEventListener("DOMNodeInserted", function(event) {
111 | var elements = document.getElementsByClassName("amara-embed");
112 | var emptyElements = [];
113 | for (var i = 0 ; i < elements.length ; i++) {
114 | if (elements[i].childNodes.length == 0 || ((elements[i].childNodes.length == 1) && (elements[i].childNodes[0].nodeType == 3)))
115 | emptyElements.push(elements[i]);
116 | }
117 | if (emptyElements.length > 0)
118 | controller.initIframes(emptyElements);
119 | controller.initResize();
120 |
121 | });
122 |
123 | };
124 | window.initIframeController = initIframeController;
125 |
126 | })(window);
127 |
128 | if(window.attachEvent) {
129 | window.attachEvent('onload', window.initIframeController);
130 | } else {
131 | if(window.onload) {
132 | var curronload = window.onload;
133 | var newonload = function() {
134 | curronload();
135 | window.initIframeController();
136 | };
137 | window.onload = newonload;
138 | } else {
139 | window.onload = window.initIframeController;
140 | }
141 | }
142 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/include.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Uncompressed source can be found at https://login.persona.org/include.orig.js
3 | *
4 | * This Source Code Form is subject to the terms of the Mozilla Public
5 | * License, v. 2.0. If a copy of the MPL was not distributed with this
6 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 |
8 | (function(){var a;navigator.mozId?navigator.id=navigator.mozId:function(){var a,b=function(){function f(a){return Array.isArray?Array.isArray(a):a.constructor.toString().indexOf("Array")!=-1}function e(a,b,d){var e=c[b][d];for(var f=0;f1)throw"scope may not contain double colons: '::'"}var k=function(){var a="",b="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";for(var c=0;c<5;c++)a+=b.charAt(Math.floor(Math.random()*b.length));return a}(),l={},m={},n={},o=!1,p=[],q=function(a,b,c){var d=!1,e=!1;return{origin:b,invoke:function(b,d){if(!n[a])throw"attempting to invoke a callback of a nonexistent transaction: "+a;var e=!1;for(var f=0;f0)for(var k=0;k=0;d--)try{if(c[d].location.protocol===window.location.protocol&&c[d].location.host===window.location.host&&c[d].name===b)return c[d]}catch(e){}return}function i(a){/^https?:\/\//.test(a)||(a=window.location.href);var b=/^(https?:\/\/[\-_a-zA-Z\.0-9:]+)/.exec(a);return b?b[1]:a}function h(){return window.JSON&&window.JSON.stringify&&window.JSON.parse&&window.postMessage}function g(){try{var a=navigator.userAgent;return a.indexOf("Fennec/")!=-1||a.indexOf("Firefox/")!=-1&&a.indexOf("Android")!=-1}catch(b){}return!1}function f(){var a=-1,b=navigator.userAgent;if(navigator.appName==="Microsoft Internet Explorer"){var c=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");c.exec(b)!=null&&(a=parseFloat(RegExp.$1))}else if(b.indexOf("Trident")>-1){var c=new RegExp("rv:([0-9]{2,2}[.0-9]{0,})");c.exec(b)!==null&&(a=parseFloat(RegExp.$1))}return a>=8}function e(a,b,c){a.detachEvent?a.detachEvent("on"+b,c):a.removeEventListener&&a.removeEventListener(b,c,!1)}function d(a,b,c){a.attachEvent?a.attachEvent("on"+b,c):a.addEventListener&&a.addEventListener(b,c,!1)}var b="__winchan_relay_frame",c="die",k=f();return h()?{open:function(f,h){function s(a){if(a.origin===m)try{var b=JSON.parse(a.data);b.a==="ready"?n.postMessage(q,m):b.a==="error"?(r(),h&&(h(b.d),h=null)):b.a==="response"&&(r(),h&&(h(null,b.d),h=null))}catch(c){}}function r(){l&&document.body.removeChild(l),l=a,p&&(p=clearInterval(p)),e(window,"message",s),e(window,"unload",r);if(o)try{o.close()}catch(b){n.postMessage(c,m)}o=n=a}if(!h)throw"missing required callback argument";var j;f.url||(j="missing required 'url' parameter"),f.relay_url||(j="missing required 'relay_url' parameter"),j&&setTimeout(function(){h(j)},0),f.window_name||(f.window_name=null);if(!f.window_features||g())f.window_features=a;var l,m=i(f.url);if(m!==i(f.relay_url))return setTimeout(function(){h("invalid arguments: origin of url and relay_url must match")},0);var n;k&&(l=document.createElement("iframe"),l.setAttribute("src",f.relay_url),l.style.display="none",l.setAttribute("name",b),document.body.appendChild(l),n=l.contentWindow);var o=window.open(f.url,f.window_name,f.window_features);n||(n=o);var p=setInterval(function(){o&&o.closed&&(r(),h&&(h("unknown closed window"),h=null))},500),q=JSON.stringify({a:"request",d:f.params});d(window,"unload",r),d(window,"message",s);return{close:r,focus:function(){if(o)try{o.focus()}catch(a){}}}},onOpen:function(b){function l(a){if(a.data===c)try{window.close()}catch(b){}}function i(c){var d;try{d=JSON.parse(c.data)}catch(g){}!!d&&d.a==="request"&&(e(window,"message",i),f=c.origin,b&&setTimeout(function(){b(f,d.d,function(c){b=a,h({a:"response",d:c})})},0))}function h(a){a=JSON.stringify(a),k?g.doPost(a,f):g.postMessage(a,f)}var f="*",g=k?j():window.opener;if(!g)throw"can't find relay frame";d(k?g:window,"message",i),d(k?g:window,"message",l);try{h({a:"ready"})}catch(m){d(g,"load",function(a){h({a:"ready"})})}var n=function(){try{e(k?g:window,"message",l)}catch(c){}b&&h({a:"error",d:"client closed window"}),b=a;try{window.close()}catch(d){}};d(window,"unload",n);return{detach:function(){e(window,"unload",n)}}}}:{open:function(a,b,c,d){setTimeout(function(){d("unsupported browser")},0)},onOpen:function(a){setTimeout(function(){a("unsupported browser")},0)}}}();var c=function(){function l(){return c}function k(){c=g()||h()||i()||j();return!c}function j(){if(!(window.JSON&&window.JSON.stringify&&window.JSON.parse))return"JSON_NOT_SUPPORTED"}function i(){if(!a.postMessage)return"POSTMESSAGE_NOT_SUPPORTED"}function h(){try{var b="localStorage"in a&&a.localStorage!==null;if(b)a.localStorage.setItem("test","true"),a.localStorage.removeItem("test");else return"LOCALSTORAGE_NOT_SUPPORTED"}catch(c){return"LOCALSTORAGE_DISABLED"}}function g(){return f()}function f(){var a=e(),b=a>-1&&a<8;if(b)return"BAD_IE_VERSION"}function e(){var a=-1;if(b.appName=="Microsoft Internet Explorer"){var c=b.userAgent,d=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");d.exec(c)!=null&&(a=parseFloat(RegExp.$1))}return a}function d(c,d){b=c,a=d}var a=window,b=navigator,c;return{setTestEnv:d,isSupported:k,getNoSupportReason:l}}();navigator.id||(navigator.id={});if(!navigator.id.request||navigator.id._shimmed){var d="https://login.persona.org",e=navigator.userAgent,f=e.indexOf("Fennec/")!=-1||e.indexOf("Firefox/")!=-1&&e.indexOf("Android")!=-1,g=f?a:"menubar=0,location=1,resizable=1,scrollbars=1,status=0,width=700,height=375",h=e.match(/CriOS/)||e.match(/Windows Phone/),i="WATCH_NEEDED",j="__persona_dialog",k,l={login:null,logout:null,match:null,ready:null},m,n=a;function o(b){b!==!0;if(n===a)n=b;else if(n!=b)throw new Error("you cannot combine the navigator.id.watch() API with navigator.id.getVerifiedEmail() or navigator.id.get()this site should instead use navigator.id.request() and navigator.id.watch()")}var p,q=!1,r=c.isSupported();function s(a){document.addEventListener?document.addEventListener("DOMContentLoaded",function b(){document.removeEventListener("DOMContentLoaded",b),a()},!1):document.attachEvent&&document.readyState&&document.attachEvent("onreadystatechange",function c(){var b=document.readyState;if(b==="loaded"||b==="complete"||b==="interactive")document.detachEvent("onreadystatechange",c),a()})}function t(){if(!!r){var c=window.document;if(!c.body){q||(s(t),q=!0);return}try{if(!p){var e=c.createElement("iframe");e.style.display="none",c.body.appendChild(e),e.src=d+"/communication_iframe",p=b.build({window:e.contentWindow,origin:d,scope:"mozid_ni",onReady:function(){p.call({method:"loaded",success:function(){l.ready&&l.ready()},error:function(){}})}}),p.bind("logout",function(a,b){l.logout&&l.logout()}),p.bind("login",function(a,b){l.login&&l.login(b)}),p.bind("match",function(a,b){l.match&&l.match()}),u(m)&&p.notify({method:"loggedInUser",params:m})}}catch(f){p=a}}}function u(a){return typeof a!="undefined"}function v(a){try{console.warn(a)}catch(b){}}function w(a,b){if(u(a[b])){v(b+" has been deprecated");return!0}}function x(a,b,c){if(u(a[b])&&u(a[c]))throw new Error("you cannot supply *both* "+b+" and "+c);w(a,b)&&(a[c]=a[b],delete a[b])}function y(a){if(typeof a=="object"){if(a.onlogin&&typeof a.onlogin!="function"||a.onlogout&&typeof a.onlogout!="function"||a.onmatch&&typeof a.onmatch!="function"||a.onready&&typeof a.onready!="function")throw new Error("non-function where function expected in parameters to navigator.id.watch()");if(!a.onlogin)throw new Error("'onlogin' is a required argument to navigator.id.watch()");if(!a.onlogout&&(a.onmatch||"loggedInUser"in a))throw new Error("stateless api only allows onlogin and onready options");l.login=a.onlogin||null,l.logout=a.onlogout||null,l.match=a.onmatch||null,l.ready=a.onready||null,x(a,"loggedInEmail","loggedInUser"),m=a.loggedInUser,m===!1&&(m=null);if(!z(m)&&!A(m)&&!B(m))throw new Error("loggedInUser is not a valid type");t()}}function z(a){return a===null}function A(a){return typeof a=="undefined"}function B(a){return Object.prototype.toString.apply(a)==="[object String]"}var C;function D(){var a=C;a==="request"&&(l.logout?a=l.ready?"watch_with_onready":"watch_without_onready":a="stateless");return a}function E(b){function r(){if(p)return p.call({method:"redirect_flow",params:JSON.stringify(b),success:function(){window.location=d+"/sign_in"}})}function n(){var a=c.getNoSupportReason();if(!a&&!e)return i}function m(){return c.isSupported()&&e}w(b,"requiredEmail"),x(b,"tosURL","termsOfService"),x(b,"privacyURL","privacyPolicy"),b.termsOfService&&!b.privacyPolicy&&v("termsOfService ignored unless privacyPolicy also defined"),b.privacyPolicy&&!b.termsOfService&&v("privacyPolicy ignored unless termsOfService also defined"),b.rp_api=D();var e=!h||C==="request"||C==="auth";C=null,b.start_time=(new Date).getTime();if(k)try{k.focus()}catch(f){}else{if(!m()){var o=n(),q="unsupported_dialog";o==="LOCALSTORAGE_DISABLED"?q="cookies_disabled":o===i&&(q="unsupported_dialog_without_watch"),k=window.open(d+"/"+q,j,g);return}p&&p.notify({method:"dialog_running"});if(h)return r();k=WinChan.open({url:d+"/sign_in",relay_url:d+"/relay",window_features:g,window_name:j,params:{method:"get",params:b}},function(c,d){if(p){!c&&d&&d.email&&p.notify({method:"loggedInUser",params:d.email});var e=!(c||d&&d.assertion);p.notify({method:"dialog_complete",params:e})}k=a;if(!c&&d&&d.assertion)try{l.login&&l.login(d.assertion)}catch(f){console.log(f);throw f}if(c==="client closed window"||!d)b&&b.oncancel&&b.oncancel(),delete b.oncancel})}}navigator.id={request:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");if(!l.login)throw new Error("navigator.id.watch must be called before navigator.id.request");a=a||{},o(!1),C="request",a.returnTo||(a.returnTo=document.location.pathname);return E(a)},watch:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");o(!1),y(a)},logout:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");t(),p&&p.notify({method:"logout"}),typeof a=="function"&&(v("navigator.id.logout callback argument has been deprecated."),setTimeout(a,0))},get:function(b,c){var d={};c=c||{},d.privacyPolicy=c.privacyPolicy||a,d.termsOfService=c.termsOfService||a,d.privacyURL=c.privacyURL||a,d.tosURL=c.tosURL||a,d.siteName=c.siteName||a,d.siteLogo=c.siteLogo||a,d.backgroundColor=c.backgroundColor||a,d.experimental_emailHint=c.experimental_emailHint||a,C=C||"get";w(c,"silent")?b&&setTimeout(function(){b(null)},0):(o(!0),y({onlogin:function(a){b&&(b(a),b=null)},onlogout:function(){}}),d.oncancel=function(){b&&(b(null),b=null),l.login=l.logout=l.match=l.ready=null},E(d))},getVerifiedEmail:function(a){v("navigator.id.getVerifiedEmail has been deprecated"),o(!0),C="getVerifiedEmail",navigator.id.get(a)},_shimmed:!0}}}()})()
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/loading.gif
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/persona-buttons.css:
--------------------------------------------------------------------------------
1 | /* Link body */
2 | .persona-button{
3 | color: #fff;
4 | display: inline-block;
5 | font-size: 14px;
6 | font-family: Helvetica, Arial, sans-serif;
7 | font-weight: bold;
8 | line-height: 1.1;
9 | overflow: hidden;
10 | position: relative;
11 | text-decoration: none;
12 | text-shadow: 0 1px rgba(0,0,0,0.5), 0 0 2px rgba(0,0,0,0.2);
13 |
14 | background: #297dc3;
15 | background: -moz-linear-gradient(top, #43a6e2, #287cc2);
16 | background: -ms-linear-gradient(top, #43a6e2, #287cc2);
17 | background: -o-linear-gradient(top, #43a6e2, #287cc2);
18 | background: -webkit-linear-gradient(top, #43a6e2, #287cc2);
19 | background: linear-gradient(top, #43a6e2, #287cc2);
20 |
21 | -moz-border-radius: 3px;
22 | -ms-border-radius: 3px;
23 | -o-border-radius: 3px;
24 | -webkit-border-radius: 3px;
25 | border-radius: 3px;
26 |
27 | -moz-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
28 | -ms-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
29 | -o-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
30 | -webkit-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
31 | box-shadow: 0 1px 0 rgba(0,0,0,0.2);
32 | }
33 |
34 | .persona-button:hover{
35 | background: #21669f;
36 | background: -moz-linear-gradient(top, #3788b9, #21669f);
37 | background: -ms-linear-gradient(top, #3788b9, #21669f);
38 | background: -o-linear-gradient(top, #3788b9, #21669f);
39 | background: -webkit-linear-gradient(top, #3788b9, #21669f);
40 | background: linear-gradient(top, #3788b9, #21669f);
41 | }
42 |
43 | .persona-button:active, .persona-button:focus{
44 | top: 1px;
45 | -moz-box-shadow: none;
46 | -ms-box-shadow: none;
47 | -o-box-shadow: none;
48 | -webkit-box-shadow: none;
49 | box-shadow: none;
50 | }
51 |
52 | .persona-button span{
53 | display: inline-block;
54 | padding: 5px 10px 5px 40px;
55 | }
56 |
57 | /* Icon */
58 | .persona-button span:after{
59 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAAPCAYAAAA/I0V3AAAA4klEQVR42o2RWaqEMBRE3YaCiDjPwQGcd9CrysLv4wTyoLFD90dxqbp1EgdPRB7Kskznea6Zn/aPoKoqUUrJOI5m4l2QBfSyLHKep1zXZSae3An1fS/7vst931bGkzuhaZrsLVbGkzuheZ7lOI6HyJ2QUkqv6yrbtv0LT+6E7G0UrfBfP3lZlpoXH4ZBmHgn5Pv+KwxDfqp0XQdgJp6c/RsUBIGOokiSJDE/s21bACbe5Ozp0TdAHMdSFIXUdS1N01C2wpObPT36HifwCJzI0iX29Oh7XP0E3CB9L01TzM+i/wePv4ZE5RtAngAAAABJRU5ErkJggg==) 10px center no-repeat;
60 | content: '';
61 | display: block;
62 | width: 31px;
63 |
64 | position: absolute;
65 | bottom: 0;
66 | left: -3px;
67 | top: 0;
68 | z-index: 10;
69 | }
70 |
71 | /* Icon background */
72 | .persona-button span:before{
73 | content: '';
74 | display: block;
75 | height: 100%;
76 | width: 20px;
77 |
78 | position: absolute;
79 | bottom: 0;
80 | left: 0;
81 | top: 0;
82 | z-index: 1;
83 |
84 | background: #42a9dd;
85 | background: -moz-linear-gradient(top, #50b8e8, #3095ce);
86 | background: -ms-linear-gradient(top, #50b8e8, #3095ce);
87 | background: -o-linear-gradient(top, #50b8e8, #3095ce);
88 | background: -webkit-linear-gradient(top, #50b8e8, #3095ce);
89 | background: linear-gradient(top, #50b8e8, #3095ce);
90 |
91 | -moz-border-radius: 3px 0 0 3px;
92 | -ms-border-radius: 3px 0 0 3px;
93 | -o-border-radius: 3px 0 0 3px;
94 | -webkit-border-radius: 3px 0 0 3px;
95 | border-radius: 3px 0 0 3px;
96 | }
97 |
98 | /* Triangle */
99 | .persona-button:before{
100 | background: #42a9dd;
101 | content: '';
102 | display: block;
103 | height: 26px;
104 | width: 26px;
105 |
106 | position: absolute;
107 | left: 2px;
108 | top: 50%;
109 | margin-top: -13px;
110 | z-index: 0;
111 |
112 | background: -moz-linear-gradient(-45deg, #50b8e8, #3095ce);
113 | background: -ms-linear-gradient(-45deg, #50b8e8, #3095ce);
114 | background: -o-linear-gradient(-45deg, #50b8e8, #3095ce);
115 | background: -webkit-linear-gradient(-45deg, #50b8e8, #3095ce);
116 | background: linear-gradient(-45deg, #3095ce, #50b8e8); /* flipped for updated spec */
117 |
118 | -moz-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
119 | -ms-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
120 | -o-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
121 | -webkit-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
122 | box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
123 |
124 | -moz-transform: rotate(45deg);
125 | -ms-transform: rotate(45deg);
126 | -o-transform: rotate(45deg);
127 | -webkit-transform: rotate(45deg);
128 | transform: rotate(45deg);
129 | }
130 |
131 | /* Inset shadow (required here because the icon background clips it when on the `a` element) */
132 | .persona-button:after{
133 | content: '';
134 | display: block;
135 | height: 100%;
136 | width: 100%;
137 |
138 | position: absolute;
139 | left: 0;
140 | top: 0;
141 | bottom: 0;
142 | right: 0;
143 | z-index: 10;
144 |
145 | -moz-border-radius: 3px;
146 | -ms-border-radius: 3px;
147 | -o-border-radius: 3px;
148 | -webkit-border-radius: 3px;
149 | border-radius: 3px;
150 |
151 | -moz-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
152 | -ms-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
153 | -o-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
154 | -webkit-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
155 | box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
156 | }
157 |
158 | /* ========================================================
159 | * Dark button
160 | * ===================================================== */
161 | .persona-button.dark{
162 | background: #3c3c3c;
163 | background: -moz-linear-gradient(top, #606060, #3c3c3c);
164 | background: -ms-linear-gradient(top, #606060, #3c3c3c);
165 | background: -o-linear-gradient(top, #606060, #3c3c3c);
166 | background: -webkit-linear-gradient(top, #606060, #3c3c3c);
167 | background: linear-gradient(top, #606060, #3c3c3c);
168 | }
169 | .persona-button.dark:hover{
170 | background: #2d2d2d;
171 | background: -moz-linear-gradient(top, #484848, #2d2d2d);
172 | background: -ms-linear-gradient(top, #484848, #2d2d2d);
173 | background: -o-linear-gradient(top, #484848, #2d2d2d);
174 | background: -webkit-linear-gradient(top, #484848, #2d2d2d);
175 | background: linear-gradient(top, #484848, #2d2d2d);
176 | }
177 | .persona-button.dark span:before{ /* Icon BG */
178 | background: #d34f2d;
179 | background: -moz-linear-gradient(top, #ebac45, #d34f2d);
180 | background: -ms-linear-gradient(top, #ebac45, #d34f2d);
181 | background: -o-linear-gradient(top, #ebac45, #d34f2d);
182 | background: -webkit-linear-gradient(top, #ebac45, #d34f2d);
183 | background: linear-gradient(top, #ebac45, #d34f2d);
184 | }
185 | .persona-button.dark:before{ /* Triangle */
186 | background: #d34f2d;
187 | background: -moz-linear-gradient(-45deg, #ebac45, #d34f2d);
188 | background: -ms-linear-gradient(-45deg, #ebac45, #d34f2d);
189 | background: -o-linear-gradient(-45deg, #ebac45, #d34f2d);
190 | background: -webkit-linear-gradient(-45deg, #ebac45, #d34f2d);
191 | background: linear-gradient(-45deg, #d34f2d, #ebac45); /* flipped for updated spec */
192 | }
193 |
194 | /* ========================================================
195 | * Orange button
196 | * ===================================================== */
197 | .persona-button.orange{
198 | background: #ee731a;
199 | background: -moz-linear-gradient(top, #ee731a, #d03116);
200 | background: -ms-linear-gradient(top, #ee731a, #d03116);
201 | background: -o-linear-gradient(top, #ee731a, #d03116);
202 | background: -webkit-linear-gradient(top, #ee731a, #d03116);
203 | background: linear-gradient(top, #ee731a, #d03116);
204 | }
205 | .persona-button.orange:hover{
206 | background: #cb6216;
207 | background: -moz-linear-gradient(top, #cb6216, #b12a13);
208 | background: -ms-linear-gradient(top, #cb6216, #b12a13);
209 | background: -o-linear-gradient(top, #cb6216, #b12a13);
210 | background: -webkit-linear-gradient(top, #cb6216, #b12a13);
211 | background: linear-gradient(top, #cb6216, #b12a13);
212 | }
213 | .persona-button.orange span:before{ /* Icon BG */
214 | background: #e84a21;
215 | background: -moz-linear-gradient(top, #f7ad27, #e84a21);
216 | background: -ms-linear-gradient(top, #f7ad27, #e84a21);
217 | background: -o-linear-gradient(top, #f7ad27, #e84a21);
218 | background: -webkit-linear-gradient(top, #f7ad27, #e84a21);
219 | background: linear-gradient(top, #f7ad27, #e84a21);
220 | }
221 | .persona-button.orange:before{ /* Triangle */
222 | background: #e84a21;
223 | background: -moz-linear-gradient(-45deg, #f7ad27, #e84a21);
224 | background: -ms-linear-gradient(-45deg, #f7ad27, #e84a21);
225 | background: -o-linear-gradient(-45deg, #f7ad27, #e84a21);
226 | background: -webkit-linear-gradient(-45deg, #f7ad27, #e84a21);
227 | background: linear-gradient(-45deg, #e84a21, #f7ad27); /* flipped for updated spec */
228 | }
229 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/richard.css:
--------------------------------------------------------------------------------
1 | a.feed:before {
2 | content:url(/static/img/rss_feed.png);
3 | }
4 |
5 | .news-item {
6 | padding: 10px 0 15px 0;
7 | }
8 |
9 | .section {
10 | padding: 10px 0 15px 0;
11 | }
12 |
13 | div.signin {
14 | padding: 11px 0 0 0;
15 | }
16 |
17 | div#sidebar dd {
18 | padding: 6px;
19 | }
20 |
21 | div#footer {
22 | border-top: 1px solid #ccc;
23 | clear: both;
24 | padding: 15px 0 15px 0;
25 | }
26 |
27 | .stats-number strong {
28 | font-size: 2em;
29 | }
30 |
31 | .stats-number em {
32 | font-size: 1.1em;
33 | font-style: normal;
34 | }
35 |
36 | .navbar-inner {
37 | border-radius: 0px;
38 | }
39 |
40 | .centered {
41 | text-align: center;
42 | }
43 |
44 | .videobox-inner {
45 | border-radius: 4px;
46 | background: #ccc;
47 | margin: 0 auto;
48 | padding: 10px;
49 | text-align: center;
50 | }
51 |
52 | div.videobox-inner div.amara-embed {
53 | margin: 0 auto 10px auto !important;
54 | display: inline-block;
55 | }
56 |
57 | .indent {
58 | padding-left: 2em;
59 | }
60 |
61 | div#video-summary-content .video-summary {
62 | clear: left;
63 | min-height: 140px;
64 | padding: 5px 0 5px 0;
65 | }
66 |
67 | div#video-summary-content .video-summary .thumbnail-data {
68 | float: left;
69 | width: 178px;
70 | }
71 |
72 | div#video-summary-content .video-summary .video-summary-data {
73 | margin: 3px 0 0 204px;
74 | }
75 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/videos.js:
--------------------------------------------------------------------------------
1 | // Parse the hash at the end of the URL and return it as object.
2 | // Example: '#t=3m&foo=bar' returns {t: '3m', foo: 'bar'}
3 | // TODO: error handling
4 | function parseLocationHash() {
5 | var parts = window.location.hash.slice(1).split('&');
6 | var result = {};
7 |
8 | for (var i = 0, length = parts.length; i < length; i++) {
9 | var tuple = parts[i].split('=');
10 | result[tuple[0]] = tuple[1];
11 | }
12 |
13 | return result;
14 | }
15 |
16 | // Parse time string and return the value in seconds.
17 | // Example: '3m16s' returns 196
18 | function parseTime(value) {
19 | var time = 0;
20 |
21 | try {
22 | var minutes = value.split('m');
23 | var seconds = minutes.slice(-1)[0].split('s');
24 |
25 | time = minutes.length > 1 ? parseInt(minutes[0], 10) * 60 : 0;
26 | time += seconds.length > 1 ? parseInt(seconds[0], 10) : 0;
27 | } catch (error) {
28 | // if parsing the time string fails, just fall back to 0
29 | }
30 |
31 | return time;
32 | }
33 |
34 | // Seek to specified time in the video and start playing.
35 | function UnisubsSeekVideo(time) {
36 | // We need to wait until the player is initialized before we can set
37 | // a time. This just checks every second if a certain global is
38 | // defined.
39 | // FIXME: this does not mean the player/video is ready! I hope we
40 | // find a better way to do this.
41 | if (typeof(unisubs) === "undefined") {
42 | setTimeout(function() { UnisubsSeekVideo(time); }, 1000);
43 | return;
44 | }
45 |
46 | var widgets = unisubs.widget.Widget.getAllWidgets();
47 |
48 | if (widgets.length > 0) {
49 | widgets[0].playAt(time);
50 | }
51 | }
52 |
53 | // Seek to specified time in the video and start playing.
54 | function HTML5SeekVideo(time) {
55 | var elements = $("video");
56 |
57 | if (elements.length === 0) {
58 | return;
59 | }
60 |
61 | var v = elements[0];
62 |
63 | function waitForMetadata() {
64 | if (v.readyState >= 1) {
65 | v.currentTime = time;
66 | v.play();
67 | return;
68 | }
69 |
70 | setTimeout(waitForMetadata, 500);
71 | }
72 |
73 | waitForMetadata();
74 | }
75 |
76 | function updateVideoOffset(embed_type) {
77 | // Only UniversalSubtitles and HTML5 players are supported
78 | if ($.inArray(embed_type, ["unisubs", "html5"]) === -1) {
79 | return;
80 | }
81 |
82 | var config = parseLocationHash();
83 | if (typeof(config.t) === "undefined") {
84 | return;
85 | }
86 |
87 | var time = parseTime(config.t);
88 |
89 | if (embed_type === "unisubs") {
90 | UnisubsSeekVideo(time);
91 | } else if (embed_type === "html5") {
92 | HTML5SeekVideo(time);
93 | }
94 | }
95 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/widget.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
97 |
98 |
99 |
100 | Gratipay
101 |
102 |
103 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - (Benford's) Law and Order (Fraud) by Rhys Elsmore_files/widget_002.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
97 |
98 |
99 |
100 | Gratipay
101 |
102 |
103 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/api.js:
--------------------------------------------------------------------------------
1 | /* This Source Code Form is subject to the terms of the Mozilla Public
2 | * License, v. 2.0. If a copy of the MPL was not distributed with this
3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4 |
5 | ;(function($, navigator, window_location) {
6 | 'use strict';
7 |
8 | // Public API
9 | var django_browserid = {
10 | /**
11 | * Retrieve an assertion and use it to log the user into your site.
12 | * @param {object} requestArgs Options to pass to navigator.id.request.
13 | * @return {jQuery.Deferred} Deferred that resolves once the user has
14 | * been logged in.
15 | */
16 | login: function login(requestArgs) {
17 | return django_browserid.getAssertion(requestArgs).then(function(assertion) {
18 | return django_browserid.verifyAssertion(assertion);
19 | });
20 | },
21 |
22 | /**
23 | * Log the user out of your site.
24 | * @return {jQuery.Deferred} Deferred that resolves once the user has
25 | * been logged out.
26 | */
27 | logout: function logout() {
28 | var info = this.getInfo();
29 | return this.getCsrfToken().then(function(csrfToken) {
30 | return $.ajax(info.logoutUrl, {
31 | type: 'POST',
32 | headers: {'X-CSRFToken': csrfToken},
33 | });
34 | });
35 | },
36 |
37 | /**
38 | * Retrieve an assertion via BrowserID.
39 | * @param {object} requestArgs Options to pass to navigator.id.request.
40 | * @return {jQuery.Deferred} Deferred that resolves with the assertion
41 | * once it is retrieved.
42 | */
43 | getAssertion: function getAssertion(requestArgs) {
44 | requestArgs = $.extend({}, this.getInfo().requestArgs, requestArgs);
45 |
46 | this._requestDeferred = $.Deferred();
47 | navigator.id.request(requestArgs);
48 | return this._requestDeferred;
49 | },
50 |
51 | /**
52 | * Verify that the given assertion is valid, and log the user in.
53 | * @param {string} Assertion to verify.
54 | * @return {jQuery.Deferred} Deferred that resolves with the login view
55 | * response once login is complete.
56 | */
57 | verifyAssertion: function verifyAssertion(assertion) {
58 | var info = this.getInfo();
59 | return this.getCsrfToken().then(function(csrfToken) {
60 | return $.ajax(info.loginUrl, {
61 | type: 'POST',
62 | data: {assertion: assertion},
63 | headers: {'X-CSRFToken': csrfToken},
64 | });
65 | });
66 | },
67 |
68 | // Cache for the info fetched by django_browserid.getInfo().
69 | _info: null,
70 |
71 | /**
72 | * Fetch the info for the Persona popup and login requests.
73 | * @return {object} Data encoded in the browserid-info tag.
74 | */
75 | getInfo: function getInfo() {
76 | if (!this._info) {
77 | this._info = $('#browserid-info').data('info');
78 | }
79 |
80 | return this._info;
81 | },
82 |
83 | /**
84 | * Fetch a CSRF token from the backend.
85 | * @return {jqXHR} jQuery XmlHttpResponse that returns the token.
86 | */
87 | getCsrfToken: function getCsrfToken() {
88 | return $.get(this.getInfo().csrfUrl);
89 | },
90 |
91 | // Deferred for post-watch-callback actions.
92 | // Stored on the public API so tests can reset it.
93 | _requestDeferred: null,
94 |
95 | /**
96 | * Register callbacks with navigator.id.watch that make the API work.
97 | * This must be called before calling any other API methods.
98 | * @param {function} Function to run on automatically-triggered logins.
99 | * @return {jqXHR} Deferred that resolves after the handlers have been
100 | * have been registered.
101 | */
102 | registerWatchHandlers: function registerWatchHandlers(onAutoLogin) {
103 | var assertion = null;
104 | var self = this;
105 |
106 | navigator.id.watch({
107 | loggedInUser: null,
108 | onlogin: function(new_assertion) {
109 | assertion = new_assertion;
110 | navigator.id.logout();
111 | },
112 | onlogout: function() {
113 | if (assertion) {
114 | if (self._requestDeferred) {
115 | self._requestDeferred.resolve(assertion);
116 | } else if ($.isFunction(onAutoLogin)) {
117 | onAutoLogin(assertion);
118 | }
119 | }
120 | }
121 | });
122 | }
123 | };
124 |
125 | window.django_browserid = django_browserid;
126 | })(window.jQuery, window.navigator, window.location);
127 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/browserid.js:
--------------------------------------------------------------------------------
1 | /* This Source Code Form is subject to the terms of the Mozilla Public
2 | * License, v. 2.0. If a copy of the MPL was not distributed with this
3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4 |
5 | ;(function($, window) {
6 | 'use strict';
7 |
8 | // Some platforms (Windows Phone and Chrome for iOS thusfar) require Persona
9 | // to use redirects instead of popups. Thus, while I'd like to ignore all
10 | // onlogin calls that don't happen after the user clicks a login link, we
11 | // have to for login to work on those platforms.
12 | // Solution? Store state in sessionStorage, which persists per-tab. Then we
13 | // can still support user-triggered logins across the redirect flow without
14 | // having other open tabs trigger auto-login.
15 | function onAutoLogin(assertion) {
16 | if (window.sessionStorage.browseridLoginAttempt === 'true') {
17 | window.sessionStorage.browseridLoginAttempt = 'false';
18 | django_browserid.verifyAssertion(assertion).then(function(verifyResult) {
19 | window.location = verifyResult.redirect;
20 | });
21 | }
22 | }
23 |
24 | /**
25 | * Compare the given URL to the current page's URL to see if they share the
26 | * same origin.
27 | */
28 | function matchesCurrentOrigin(url) {
29 | var a = document.createElement('a');
30 | a.href = url;
31 | var hostMatch = !a.host || window.location.host === a.host;
32 | var protocolMatch = !a.protocol || window.location.protocol === a.protocol;
33 | return hostMatch && protocolMatch;
34 | }
35 |
36 | $(function() {
37 | django_browserid.registerWatchHandlers(onAutoLogin);
38 |
39 | // Trigger login whenever a login link is clicked, and redirect the user
40 | // once it succeeds.
41 | $(document).on('click', '.browserid-login', function(e) {
42 | e.preventDefault();
43 | var $link = $(this);
44 | window.sessionStorage.browseridLoginAttempt = 'true';
45 | django_browserid.login().then(function(verifyResult) {
46 | window.sessionStorage.browseridLoginAttempt = 'false';
47 | var redirect = $link.data('next') || verifyResult.redirect;
48 | if (matchesCurrentOrigin(redirect)) {
49 | window.location = redirect;
50 | }
51 | });
52 | });
53 |
54 | // Trigger logout whenever a logout link is clicked, and redirect the
55 | // user once it succeeds.
56 | $(document).on('click', '.browserid-logout', function(e) {
57 | e.preventDefault();
58 | var $link = $(this);
59 | django_browserid.logout().then(function(logoutResult) {
60 | var redirect = $link.attr('next') || logoutResult.redirect;
61 | if (matchesCurrentOrigin(redirect)) {
62 | window.location = redirect;
63 | }
64 | });
65 | });
66 | });
67 | })(jQuery, window);
68 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/communication_iframe.htm:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 | non-interactive iframe
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_002.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_002.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_003.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_003.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_004.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_004.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_005.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_005.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_006.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_006.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_007.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_007.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_008.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_008.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_009.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_009.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_010.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_010.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_011.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_011.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_012.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_012.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_013.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_013.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_014.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_014.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_015.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_015.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_016.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_016.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_017.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_017.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_018.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_018.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_019.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_019.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_020.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_020.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_021.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_021.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_022.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_022.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_023.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_023.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_024.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_024.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_025.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_025.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_026.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_026.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_027.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_027.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_028.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_028.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_029.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_029.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_030.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_030.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_031.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_031.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_032.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_032.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_033.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_033.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_034.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_034.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_035.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_035.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_036.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_036.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_037.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_037.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_038.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_038.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_039.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_039.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_040.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_040.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_041.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_041.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_042.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_042.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_043.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_043.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_044.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_044.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_045.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_045.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_046.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_046.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_047.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_047.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_048.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_048.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_049.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_049.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_050.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_050.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_051.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jackgolding/FullStackDataAnalysis/d8a02bd12bddf5fe4ded008a27bda5f03c6d504c/Assets/pyvideo.org - PyCon AU 2014_files/hqdefault_051.jpg
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/include.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Uncompressed source can be found at https://login.persona.org/include.orig.js
3 | *
4 | * This Source Code Form is subject to the terms of the Mozilla Public
5 | * License, v. 2.0. If a copy of the MPL was not distributed with this
6 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 |
8 | (function(){var a;navigator.mozId?navigator.id=navigator.mozId:function(){var a,b=function(){function f(a){return Array.isArray?Array.isArray(a):a.constructor.toString().indexOf("Array")!=-1}function e(a,b,d){var e=c[b][d];for(var f=0;f1)throw"scope may not contain double colons: '::'"}var k=function(){var a="",b="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";for(var c=0;c<5;c++)a+=b.charAt(Math.floor(Math.random()*b.length));return a}(),l={},m={},n={},o=!1,p=[],q=function(a,b,c){var d=!1,e=!1;return{origin:b,invoke:function(b,d){if(!n[a])throw"attempting to invoke a callback of a nonexistent transaction: "+a;var e=!1;for(var f=0;f0)for(var k=0;k=0;d--)try{if(c[d].location.protocol===window.location.protocol&&c[d].location.host===window.location.host&&c[d].name===b)return c[d]}catch(e){}return}function i(a){/^https?:\/\//.test(a)||(a=window.location.href);var b=/^(https?:\/\/[\-_a-zA-Z\.0-9:]+)/.exec(a);return b?b[1]:a}function h(){return window.JSON&&window.JSON.stringify&&window.JSON.parse&&window.postMessage}function g(){try{var a=navigator.userAgent;return a.indexOf("Fennec/")!=-1||a.indexOf("Firefox/")!=-1&&a.indexOf("Android")!=-1}catch(b){}return!1}function f(){var a=-1,b=navigator.userAgent;if(navigator.appName==="Microsoft Internet Explorer"){var c=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");c.exec(b)!=null&&(a=parseFloat(RegExp.$1))}else if(b.indexOf("Trident")>-1){var c=new RegExp("rv:([0-9]{2,2}[.0-9]{0,})");c.exec(b)!==null&&(a=parseFloat(RegExp.$1))}return a>=8}function e(a,b,c){a.detachEvent?a.detachEvent("on"+b,c):a.removeEventListener&&a.removeEventListener(b,c,!1)}function d(a,b,c){a.attachEvent?a.attachEvent("on"+b,c):a.addEventListener&&a.addEventListener(b,c,!1)}var b="__winchan_relay_frame",c="die",k=f();return h()?{open:function(f,h){function s(a){if(a.origin===m)try{var b=JSON.parse(a.data);b.a==="ready"?n.postMessage(q,m):b.a==="error"?(r(),h&&(h(b.d),h=null)):b.a==="response"&&(r(),h&&(h(null,b.d),h=null))}catch(c){}}function r(){l&&document.body.removeChild(l),l=a,p&&(p=clearInterval(p)),e(window,"message",s),e(window,"unload",r);if(o)try{o.close()}catch(b){n.postMessage(c,m)}o=n=a}if(!h)throw"missing required callback argument";var j;f.url||(j="missing required 'url' parameter"),f.relay_url||(j="missing required 'relay_url' parameter"),j&&setTimeout(function(){h(j)},0),f.window_name||(f.window_name=null);if(!f.window_features||g())f.window_features=a;var l,m=i(f.url);if(m!==i(f.relay_url))return setTimeout(function(){h("invalid arguments: origin of url and relay_url must match")},0);var n;k&&(l=document.createElement("iframe"),l.setAttribute("src",f.relay_url),l.style.display="none",l.setAttribute("name",b),document.body.appendChild(l),n=l.contentWindow);var o=window.open(f.url,f.window_name,f.window_features);n||(n=o);var p=setInterval(function(){o&&o.closed&&(r(),h&&(h("unknown closed window"),h=null))},500),q=JSON.stringify({a:"request",d:f.params});d(window,"unload",r),d(window,"message",s);return{close:r,focus:function(){if(o)try{o.focus()}catch(a){}}}},onOpen:function(b){function l(a){if(a.data===c)try{window.close()}catch(b){}}function i(c){var d;try{d=JSON.parse(c.data)}catch(g){}!!d&&d.a==="request"&&(e(window,"message",i),f=c.origin,b&&setTimeout(function(){b(f,d.d,function(c){b=a,h({a:"response",d:c})})},0))}function h(a){a=JSON.stringify(a),k?g.doPost(a,f):g.postMessage(a,f)}var f="*",g=k?j():window.opener;if(!g)throw"can't find relay frame";d(k?g:window,"message",i),d(k?g:window,"message",l);try{h({a:"ready"})}catch(m){d(g,"load",function(a){h({a:"ready"})})}var n=function(){try{e(k?g:window,"message",l)}catch(c){}b&&h({a:"error",d:"client closed window"}),b=a;try{window.close()}catch(d){}};d(window,"unload",n);return{detach:function(){e(window,"unload",n)}}}}:{open:function(a,b,c,d){setTimeout(function(){d("unsupported browser")},0)},onOpen:function(a){setTimeout(function(){a("unsupported browser")},0)}}}();var c=function(){function l(){return c}function k(){c=g()||h()||i()||j();return!c}function j(){if(!(window.JSON&&window.JSON.stringify&&window.JSON.parse))return"JSON_NOT_SUPPORTED"}function i(){if(!a.postMessage)return"POSTMESSAGE_NOT_SUPPORTED"}function h(){try{var b="localStorage"in a&&a.localStorage!==null;if(b)a.localStorage.setItem("test","true"),a.localStorage.removeItem("test");else return"LOCALSTORAGE_NOT_SUPPORTED"}catch(c){return"LOCALSTORAGE_DISABLED"}}function g(){return f()}function f(){var a=e(),b=a>-1&&a<8;if(b)return"BAD_IE_VERSION"}function e(){var a=-1;if(b.appName=="Microsoft Internet Explorer"){var c=b.userAgent,d=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");d.exec(c)!=null&&(a=parseFloat(RegExp.$1))}return a}function d(c,d){b=c,a=d}var a=window,b=navigator,c;return{setTestEnv:d,isSupported:k,getNoSupportReason:l}}();navigator.id||(navigator.id={});if(!navigator.id.request||navigator.id._shimmed){var d="https://login.persona.org",e=navigator.userAgent,f=e.indexOf("Fennec/")!=-1||e.indexOf("Firefox/")!=-1&&e.indexOf("Android")!=-1,g=f?a:"menubar=0,location=1,resizable=1,scrollbars=1,status=0,width=700,height=375",h=e.match(/CriOS/)||e.match(/Windows Phone/),i="WATCH_NEEDED",j="__persona_dialog",k,l={login:null,logout:null,match:null,ready:null},m,n=a;function o(b){b!==!0;if(n===a)n=b;else if(n!=b)throw new Error("you cannot combine the navigator.id.watch() API with navigator.id.getVerifiedEmail() or navigator.id.get()this site should instead use navigator.id.request() and navigator.id.watch()")}var p,q=!1,r=c.isSupported();function s(a){document.addEventListener?document.addEventListener("DOMContentLoaded",function b(){document.removeEventListener("DOMContentLoaded",b),a()},!1):document.attachEvent&&document.readyState&&document.attachEvent("onreadystatechange",function c(){var b=document.readyState;if(b==="loaded"||b==="complete"||b==="interactive")document.detachEvent("onreadystatechange",c),a()})}function t(){if(!!r){var c=window.document;if(!c.body){q||(s(t),q=!0);return}try{if(!p){var e=c.createElement("iframe");e.style.display="none",c.body.appendChild(e),e.src=d+"/communication_iframe",p=b.build({window:e.contentWindow,origin:d,scope:"mozid_ni",onReady:function(){p.call({method:"loaded",success:function(){l.ready&&l.ready()},error:function(){}})}}),p.bind("logout",function(a,b){l.logout&&l.logout()}),p.bind("login",function(a,b){l.login&&l.login(b)}),p.bind("match",function(a,b){l.match&&l.match()}),u(m)&&p.notify({method:"loggedInUser",params:m})}}catch(f){p=a}}}function u(a){return typeof a!="undefined"}function v(a){try{console.warn(a)}catch(b){}}function w(a,b){if(u(a[b])){v(b+" has been deprecated");return!0}}function x(a,b,c){if(u(a[b])&&u(a[c]))throw new Error("you cannot supply *both* "+b+" and "+c);w(a,b)&&(a[c]=a[b],delete a[b])}function y(a){if(typeof a=="object"){if(a.onlogin&&typeof a.onlogin!="function"||a.onlogout&&typeof a.onlogout!="function"||a.onmatch&&typeof a.onmatch!="function"||a.onready&&typeof a.onready!="function")throw new Error("non-function where function expected in parameters to navigator.id.watch()");if(!a.onlogin)throw new Error("'onlogin' is a required argument to navigator.id.watch()");if(!a.onlogout&&(a.onmatch||"loggedInUser"in a))throw new Error("stateless api only allows onlogin and onready options");l.login=a.onlogin||null,l.logout=a.onlogout||null,l.match=a.onmatch||null,l.ready=a.onready||null,x(a,"loggedInEmail","loggedInUser"),m=a.loggedInUser,m===!1&&(m=null);if(!z(m)&&!A(m)&&!B(m))throw new Error("loggedInUser is not a valid type");t()}}function z(a){return a===null}function A(a){return typeof a=="undefined"}function B(a){return Object.prototype.toString.apply(a)==="[object String]"}var C;function D(){var a=C;a==="request"&&(l.logout?a=l.ready?"watch_with_onready":"watch_without_onready":a="stateless");return a}function E(b){function r(){if(p)return p.call({method:"redirect_flow",params:JSON.stringify(b),success:function(){window.location=d+"/sign_in"}})}function n(){var a=c.getNoSupportReason();if(!a&&!e)return i}function m(){return c.isSupported()&&e}w(b,"requiredEmail"),x(b,"tosURL","termsOfService"),x(b,"privacyURL","privacyPolicy"),b.termsOfService&&!b.privacyPolicy&&v("termsOfService ignored unless privacyPolicy also defined"),b.privacyPolicy&&!b.termsOfService&&v("privacyPolicy ignored unless termsOfService also defined"),b.rp_api=D();var e=!h||C==="request"||C==="auth";C=null,b.start_time=(new Date).getTime();if(k)try{k.focus()}catch(f){}else{if(!m()){var o=n(),q="unsupported_dialog";o==="LOCALSTORAGE_DISABLED"?q="cookies_disabled":o===i&&(q="unsupported_dialog_without_watch"),k=window.open(d+"/"+q,j,g);return}p&&p.notify({method:"dialog_running"});if(h)return r();k=WinChan.open({url:d+"/sign_in",relay_url:d+"/relay",window_features:g,window_name:j,params:{method:"get",params:b}},function(c,d){if(p){!c&&d&&d.email&&p.notify({method:"loggedInUser",params:d.email});var e=!(c||d&&d.assertion);p.notify({method:"dialog_complete",params:e})}k=a;if(!c&&d&&d.assertion)try{l.login&&l.login(d.assertion)}catch(f){console.log(f);throw f}if(c==="client closed window"||!d)b&&b.oncancel&&b.oncancel(),delete b.oncancel})}}navigator.id={request:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");if(!l.login)throw new Error("navigator.id.watch must be called before navigator.id.request");a=a||{},o(!1),C="request",a.returnTo||(a.returnTo=document.location.pathname);return E(a)},watch:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");o(!1),y(a)},logout:function(a){if(this!=navigator.id)throw new Error("all navigator.id calls must be made on the navigator.id object");t(),p&&p.notify({method:"logout"}),typeof a=="function"&&(v("navigator.id.logout callback argument has been deprecated."),setTimeout(a,0))},get:function(b,c){var d={};c=c||{},d.privacyPolicy=c.privacyPolicy||a,d.termsOfService=c.termsOfService||a,d.privacyURL=c.privacyURL||a,d.tosURL=c.tosURL||a,d.siteName=c.siteName||a,d.siteLogo=c.siteLogo||a,d.backgroundColor=c.backgroundColor||a,d.experimental_emailHint=c.experimental_emailHint||a,C=C||"get";w(c,"silent")?b&&setTimeout(function(){b(null)},0):(o(!0),y({onlogin:function(a){b&&(b(a),b=null)},onlogout:function(){}}),d.oncancel=function(){b&&(b(null),b=null),l.login=l.logout=l.match=l.ready=null},E(d))},getVerifiedEmail:function(a){v("navigator.id.getVerifiedEmail has been deprecated"),o(!0),C="getVerifiedEmail",navigator.id.get(a)},_shimmed:!0}}}()})()
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/persona-buttons.css:
--------------------------------------------------------------------------------
1 | /* Link body */
2 | .persona-button{
3 | color: #fff;
4 | display: inline-block;
5 | font-size: 14px;
6 | font-family: Helvetica, Arial, sans-serif;
7 | font-weight: bold;
8 | line-height: 1.1;
9 | overflow: hidden;
10 | position: relative;
11 | text-decoration: none;
12 | text-shadow: 0 1px rgba(0,0,0,0.5), 0 0 2px rgba(0,0,0,0.2);
13 |
14 | background: #297dc3;
15 | background: -moz-linear-gradient(top, #43a6e2, #287cc2);
16 | background: -ms-linear-gradient(top, #43a6e2, #287cc2);
17 | background: -o-linear-gradient(top, #43a6e2, #287cc2);
18 | background: -webkit-linear-gradient(top, #43a6e2, #287cc2);
19 | background: linear-gradient(top, #43a6e2, #287cc2);
20 |
21 | -moz-border-radius: 3px;
22 | -ms-border-radius: 3px;
23 | -o-border-radius: 3px;
24 | -webkit-border-radius: 3px;
25 | border-radius: 3px;
26 |
27 | -moz-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
28 | -ms-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
29 | -o-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
30 | -webkit-box-shadow: 0 1px 0 rgba(0,0,0,0.2);
31 | box-shadow: 0 1px 0 rgba(0,0,0,0.2);
32 | }
33 |
34 | .persona-button:hover{
35 | background: #21669f;
36 | background: -moz-linear-gradient(top, #3788b9, #21669f);
37 | background: -ms-linear-gradient(top, #3788b9, #21669f);
38 | background: -o-linear-gradient(top, #3788b9, #21669f);
39 | background: -webkit-linear-gradient(top, #3788b9, #21669f);
40 | background: linear-gradient(top, #3788b9, #21669f);
41 | }
42 |
43 | .persona-button:active, .persona-button:focus{
44 | top: 1px;
45 | -moz-box-shadow: none;
46 | -ms-box-shadow: none;
47 | -o-box-shadow: none;
48 | -webkit-box-shadow: none;
49 | box-shadow: none;
50 | }
51 |
52 | .persona-button span{
53 | display: inline-block;
54 | padding: 5px 10px 5px 40px;
55 | }
56 |
57 | /* Icon */
58 | .persona-button span:after{
59 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAAPCAYAAAA/I0V3AAAA4klEQVR42o2RWaqEMBRE3YaCiDjPwQGcd9CrysLv4wTyoLFD90dxqbp1EgdPRB7Kskznea6Zn/aPoKoqUUrJOI5m4l2QBfSyLHKep1zXZSae3An1fS/7vst931bGkzuhaZrsLVbGkzuheZ7lOI6HyJ2QUkqv6yrbtv0LT+6E7G0UrfBfP3lZlpoXH4ZBmHgn5Pv+KwxDfqp0XQdgJp6c/RsUBIGOokiSJDE/s21bACbe5Ozp0TdAHMdSFIXUdS1N01C2wpObPT36HifwCJzI0iX29Oh7XP0E3CB9L01TzM+i/wePv4ZE5RtAngAAAABJRU5ErkJggg==) 10px center no-repeat;
60 | content: '';
61 | display: block;
62 | width: 31px;
63 |
64 | position: absolute;
65 | bottom: 0;
66 | left: -3px;
67 | top: 0;
68 | z-index: 10;
69 | }
70 |
71 | /* Icon background */
72 | .persona-button span:before{
73 | content: '';
74 | display: block;
75 | height: 100%;
76 | width: 20px;
77 |
78 | position: absolute;
79 | bottom: 0;
80 | left: 0;
81 | top: 0;
82 | z-index: 1;
83 |
84 | background: #42a9dd;
85 | background: -moz-linear-gradient(top, #50b8e8, #3095ce);
86 | background: -ms-linear-gradient(top, #50b8e8, #3095ce);
87 | background: -o-linear-gradient(top, #50b8e8, #3095ce);
88 | background: -webkit-linear-gradient(top, #50b8e8, #3095ce);
89 | background: linear-gradient(top, #50b8e8, #3095ce);
90 |
91 | -moz-border-radius: 3px 0 0 3px;
92 | -ms-border-radius: 3px 0 0 3px;
93 | -o-border-radius: 3px 0 0 3px;
94 | -webkit-border-radius: 3px 0 0 3px;
95 | border-radius: 3px 0 0 3px;
96 | }
97 |
98 | /* Triangle */
99 | .persona-button:before{
100 | background: #42a9dd;
101 | content: '';
102 | display: block;
103 | height: 26px;
104 | width: 26px;
105 |
106 | position: absolute;
107 | left: 2px;
108 | top: 50%;
109 | margin-top: -13px;
110 | z-index: 0;
111 |
112 | background: -moz-linear-gradient(-45deg, #50b8e8, #3095ce);
113 | background: -ms-linear-gradient(-45deg, #50b8e8, #3095ce);
114 | background: -o-linear-gradient(-45deg, #50b8e8, #3095ce);
115 | background: -webkit-linear-gradient(-45deg, #50b8e8, #3095ce);
116 | background: linear-gradient(-45deg, #3095ce, #50b8e8); /* flipped for updated spec */
117 |
118 | -moz-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
119 | -ms-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
120 | -o-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
121 | -webkit-box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
122 | box-shadow: 1px -1px 1px rgba(0,0,0,0.1);
123 |
124 | -moz-transform: rotate(45deg);
125 | -ms-transform: rotate(45deg);
126 | -o-transform: rotate(45deg);
127 | -webkit-transform: rotate(45deg);
128 | transform: rotate(45deg);
129 | }
130 |
131 | /* Inset shadow (required here because the icon background clips it when on the `a` element) */
132 | .persona-button:after{
133 | content: '';
134 | display: block;
135 | height: 100%;
136 | width: 100%;
137 |
138 | position: absolute;
139 | left: 0;
140 | top: 0;
141 | bottom: 0;
142 | right: 0;
143 | z-index: 10;
144 |
145 | -moz-border-radius: 3px;
146 | -ms-border-radius: 3px;
147 | -o-border-radius: 3px;
148 | -webkit-border-radius: 3px;
149 | border-radius: 3px;
150 |
151 | -moz-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
152 | -ms-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
153 | -o-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
154 | -webkit-box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
155 | box-shadow: inset 0 -1px 0 rgba(0,0,0,0.3);
156 | }
157 |
158 | /* ========================================================
159 | * Dark button
160 | * ===================================================== */
161 | .persona-button.dark{
162 | background: #3c3c3c;
163 | background: -moz-linear-gradient(top, #606060, #3c3c3c);
164 | background: -ms-linear-gradient(top, #606060, #3c3c3c);
165 | background: -o-linear-gradient(top, #606060, #3c3c3c);
166 | background: -webkit-linear-gradient(top, #606060, #3c3c3c);
167 | background: linear-gradient(top, #606060, #3c3c3c);
168 | }
169 | .persona-button.dark:hover{
170 | background: #2d2d2d;
171 | background: -moz-linear-gradient(top, #484848, #2d2d2d);
172 | background: -ms-linear-gradient(top, #484848, #2d2d2d);
173 | background: -o-linear-gradient(top, #484848, #2d2d2d);
174 | background: -webkit-linear-gradient(top, #484848, #2d2d2d);
175 | background: linear-gradient(top, #484848, #2d2d2d);
176 | }
177 | .persona-button.dark span:before{ /* Icon BG */
178 | background: #d34f2d;
179 | background: -moz-linear-gradient(top, #ebac45, #d34f2d);
180 | background: -ms-linear-gradient(top, #ebac45, #d34f2d);
181 | background: -o-linear-gradient(top, #ebac45, #d34f2d);
182 | background: -webkit-linear-gradient(top, #ebac45, #d34f2d);
183 | background: linear-gradient(top, #ebac45, #d34f2d);
184 | }
185 | .persona-button.dark:before{ /* Triangle */
186 | background: #d34f2d;
187 | background: -moz-linear-gradient(-45deg, #ebac45, #d34f2d);
188 | background: -ms-linear-gradient(-45deg, #ebac45, #d34f2d);
189 | background: -o-linear-gradient(-45deg, #ebac45, #d34f2d);
190 | background: -webkit-linear-gradient(-45deg, #ebac45, #d34f2d);
191 | background: linear-gradient(-45deg, #d34f2d, #ebac45); /* flipped for updated spec */
192 | }
193 |
194 | /* ========================================================
195 | * Orange button
196 | * ===================================================== */
197 | .persona-button.orange{
198 | background: #ee731a;
199 | background: -moz-linear-gradient(top, #ee731a, #d03116);
200 | background: -ms-linear-gradient(top, #ee731a, #d03116);
201 | background: -o-linear-gradient(top, #ee731a, #d03116);
202 | background: -webkit-linear-gradient(top, #ee731a, #d03116);
203 | background: linear-gradient(top, #ee731a, #d03116);
204 | }
205 | .persona-button.orange:hover{
206 | background: #cb6216;
207 | background: -moz-linear-gradient(top, #cb6216, #b12a13);
208 | background: -ms-linear-gradient(top, #cb6216, #b12a13);
209 | background: -o-linear-gradient(top, #cb6216, #b12a13);
210 | background: -webkit-linear-gradient(top, #cb6216, #b12a13);
211 | background: linear-gradient(top, #cb6216, #b12a13);
212 | }
213 | .persona-button.orange span:before{ /* Icon BG */
214 | background: #e84a21;
215 | background: -moz-linear-gradient(top, #f7ad27, #e84a21);
216 | background: -ms-linear-gradient(top, #f7ad27, #e84a21);
217 | background: -o-linear-gradient(top, #f7ad27, #e84a21);
218 | background: -webkit-linear-gradient(top, #f7ad27, #e84a21);
219 | background: linear-gradient(top, #f7ad27, #e84a21);
220 | }
221 | .persona-button.orange:before{ /* Triangle */
222 | background: #e84a21;
223 | background: -moz-linear-gradient(-45deg, #f7ad27, #e84a21);
224 | background: -ms-linear-gradient(-45deg, #f7ad27, #e84a21);
225 | background: -o-linear-gradient(-45deg, #f7ad27, #e84a21);
226 | background: -webkit-linear-gradient(-45deg, #f7ad27, #e84a21);
227 | background: linear-gradient(-45deg, #e84a21, #f7ad27); /* flipped for updated spec */
228 | }
229 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/richard.css:
--------------------------------------------------------------------------------
1 | a.feed:before {
2 | content:url(/static/img/rss_feed.png);
3 | }
4 |
5 | .news-item {
6 | padding: 10px 0 15px 0;
7 | }
8 |
9 | .section {
10 | padding: 10px 0 15px 0;
11 | }
12 |
13 | div.signin {
14 | padding: 11px 0 0 0;
15 | }
16 |
17 | div#sidebar dd {
18 | padding: 6px;
19 | }
20 |
21 | div#footer {
22 | border-top: 1px solid #ccc;
23 | clear: both;
24 | padding: 15px 0 15px 0;
25 | }
26 |
27 | .stats-number strong {
28 | font-size: 2em;
29 | }
30 |
31 | .stats-number em {
32 | font-size: 1.1em;
33 | font-style: normal;
34 | }
35 |
36 | .navbar-inner {
37 | border-radius: 0px;
38 | }
39 |
40 | .centered {
41 | text-align: center;
42 | }
43 |
44 | .videobox-inner {
45 | border-radius: 4px;
46 | background: #ccc;
47 | margin: 0 auto;
48 | padding: 10px;
49 | text-align: center;
50 | }
51 |
52 | div.videobox-inner div.amara-embed {
53 | margin: 0 auto 10px auto !important;
54 | display: inline-block;
55 | }
56 |
57 | .indent {
58 | padding-left: 2em;
59 | }
60 |
61 | div#video-summary-content .video-summary {
62 | clear: left;
63 | min-height: 140px;
64 | padding: 5px 0 5px 0;
65 | }
66 |
67 | div#video-summary-content .video-summary .thumbnail-data {
68 | float: left;
69 | width: 178px;
70 | }
71 |
72 | div#video-summary-content .video-summary .video-summary-data {
73 | margin: 3px 0 0 204px;
74 | }
75 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/widget.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
97 |
98 |
99 |
100 | Gratipay
101 |
102 |
103 |
--------------------------------------------------------------------------------
/Assets/pyvideo.org - PyCon AU 2014_files/widget_002.htm:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
97 |
98 |
99 |
100 | Gratipay
101 |
102 |
103 |
--------------------------------------------------------------------------------
/Consuming APIs.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "metadata": {
3 | "name": "",
4 | "signature": "sha256:422e232381e881c25ffdf8c4eb8c08431b88cda7371cf59491b64f96934f0625"
5 | },
6 | "nbformat": 3,
7 | "nbformat_minor": 0,
8 | "worksheets": [
9 | {
10 | "cells": [
11 | {
12 | "cell_type": "markdown",
13 | "metadata": {},
14 | "source": [
15 | "#Consuming APIs with requests\n",
16 | "\n",
17 | "We will look at Hacker New's API as it does not require authentication!"
18 | ]
19 | },
20 | {
21 | "cell_type": "code",
22 | "collapsed": false,
23 | "input": [
24 | "import requests\n",
25 | "import pandas as pd\n",
26 | "import json"
27 | ],
28 | "language": "python",
29 | "metadata": {},
30 | "outputs": [],
31 | "prompt_number": 46
32 | },
33 | {
34 | "cell_type": "code",
35 | "collapsed": false,
36 | "input": [
37 | "top_100_stories = requests.get('https://hacker-news.firebaseio.com/v0/topstories.json')"
38 | ],
39 | "language": "python",
40 | "metadata": {},
41 | "outputs": [],
42 | "prompt_number": 28
43 | },
44 | {
45 | "cell_type": "markdown",
46 | "metadata": {},
47 | "source": [
48 | "top_100_stories is a string, not a list!"
49 | ]
50 | },
51 | {
52 | "cell_type": "code",
53 | "collapsed": false,
54 | "input": [
55 | "print(top_100_stories.text)\n",
56 | "print(type(top_100_stories.text))"
57 | ],
58 | "language": "python",
59 | "metadata": {},
60 | "outputs": [
61 | {
62 | "output_type": "stream",
63 | "stream": "stdout",
64 | "text": [
65 | "[8988819,8987434,8989455,8988949,8985625,8986920,8988984,8987441,8986551,8986183,8984648,8983355,8989495,8985151,8987931,8987014,8987459,8984266,8989453,8988594,8986497,8987602,8989245,8988902,8984343,8984797,8983771,8986459,8985179,8985496,8989138,8988301,8987813,8985541,8985217,8984508,8983804,8987783,8985376,8988837,8987676,8983158,8985211,8985349,8986998,8985976,8984425,8988403,8982526,8984385,8986489,8983875,8984493,8983441,8985134,8988612,8984580,8988279,8982962,8984129,8988684,8987727,8988332,8986000,8986127,8983938,8987698,8986624,8984926,8985334,8979620,8987380,8984497,8981690,8985009,8987855,8985124,8989110,8987550,8981642,8980255,8988291,8980498,8983905,8982013,8981314,8981707,8988248,8983973,8986395,8984173,8982620,8977550,8988389,8982241,8983134,8987027,8986575,8989093,8986547]\n",
66 | "\n"
67 | ]
68 | }
69 | ],
70 | "prompt_number": 30
71 | },
72 | {
73 | "cell_type": "markdown",
74 | "metadata": {},
75 | "source": [
76 | "json.loads the string!"
77 | ]
78 | },
79 | {
80 | "cell_type": "code",
81 | "collapsed": false,
82 | "input": [
83 | "top_100_stories_list = json.loads(top_100_stories.text)\n",
84 | "print(type(top_100_stories_list))"
85 | ],
86 | "language": "python",
87 | "metadata": {},
88 | "outputs": [
89 | {
90 | "output_type": "stream",
91 | "stream": "stdout",
92 | "text": [
93 | "\n"
94 | ]
95 | }
96 | ],
97 | "prompt_number": 31
98 | },
99 | {
100 | "cell_type": "code",
101 | "collapsed": false,
102 | "input": [
103 | "top_100_story_json_list = []\n",
104 | "\n",
105 | "for story in top_100_stories_list:\n",
106 | " story_request = requests.get('https://hacker-news.firebaseio.com/v0/item/'+str(story)+'.json')\n",
107 | " top_100_story_json_list.append(json.loads(story_request.text))"
108 | ],
109 | "language": "python",
110 | "metadata": {},
111 | "outputs": [],
112 | "prompt_number": 35
113 | },
114 | {
115 | "cell_type": "code",
116 | "collapsed": false,
117 | "input": [
118 | "with open(r'./Assets/top_100_hacker_news_stories.json', 'w') as outfile:\n",
119 | " json.dump(top_100_story_json_list, outfile)"
120 | ],
121 | "language": "python",
122 | "metadata": {},
123 | "outputs": [],
124 | "prompt_number": 48
125 | },
126 | {
127 | "cell_type": "code",
128 | "collapsed": false,
129 | "input": [
130 | "df = pd.read_json(r'./Assets/top_100_hacker_news_stories.json')"
131 | ],
132 | "language": "python",
133 | "metadata": {},
134 | "outputs": [],
135 | "prompt_number": 49
136 | },
137 | {
138 | "cell_type": "markdown",
139 | "metadata": {},
140 | "source": [
141 | "The time value is in Unix Time (seconds since epoch) - we change this to date-time"
142 | ]
143 | },
144 | {
145 | "cell_type": "code",
146 | "collapsed": false,
147 | "input": [
148 | "df['date_time'] = pd.to_datetime(df['time'], unit='s')"
149 | ],
150 | "language": "python",
151 | "metadata": {},
152 | "outputs": [],
153 | "prompt_number": 57
154 | },
155 | {
156 | "cell_type": "code",
157 | "collapsed": false,
158 | "input": [
159 | "df.sort('score', ascending=False)[['score', 'title']][0:5]"
160 | ],
161 | "language": "python",
162 | "metadata": {},
163 | "outputs": [
164 | {
165 | "html": [
166 | "\n",
167 | "
\n",
168 | " \n",
169 | " \n",
170 | " \n",
171 | " score \n",
172 | " title \n",
173 | " \n",
174 | " \n",
175 | " \n",
176 | " \n",
177 | " 11 \n",
178 | " 686 \n",
179 | " Windows 10 for Raspberry Pi 2 \n",
180 | " \n",
181 | " \n",
182 | " 48 \n",
183 | " 564 \n",
184 | " Turbocharged Raspberry Pi 2 unleashed \n",
185 | " \n",
186 | " \n",
187 | " 4 \n",
188 | " 540 \n",
189 | " F.C.C. Is Expected to Propose Regulating the I... \n",
190 | " \n",
191 | " \n",
192 | " 1 \n",
193 | " 427 \n",
194 | " Google Is Developing Its Own Uber Competitor \n",
195 | " \n",
196 | " \n",
197 | " 10 \n",
198 | " 356 \n",
199 | " What Color Is Your Function? \n",
200 | " \n",
201 | " \n",
202 | "
\n",
203 | "
"
204 | ],
205 | "metadata": {},
206 | "output_type": "pyout",
207 | "prompt_number": 70,
208 | "text": [
209 | " score title\n",
210 | "11 686 Windows 10 for Raspberry Pi 2\n",
211 | "48 564 Turbocharged Raspberry Pi 2 unleashed\n",
212 | "4 540 F.C.C. Is Expected to Propose Regulating the I...\n",
213 | "1 427 Google Is Developing Its Own Uber Competitor\n",
214 | "10 356 What Color Is Your Function?"
215 | ]
216 | }
217 | ],
218 | "prompt_number": 70
219 | }
220 | ],
221 | "metadata": {}
222 | }
223 | ]
224 | }
--------------------------------------------------------------------------------
/Flask/helloworld.py:
--------------------------------------------------------------------------------
1 | from flask import Flask
2 |
3 | app = Flask(__name__)
4 |
5 |
6 | @app.route('/')
7 | def hello_world():
8 | return 'Hello World!'
9 |
10 |
11 | if __name__ == '__main__':
12 | app.run()
13 |
--------------------------------------------------------------------------------
/Flask/predict.py:
--------------------------------------------------------------------------------
1 | from flask import Flask, request
2 | from sklearn.externals import joblib
3 |
4 |
5 | model = joblib.load('../Assets/my_model.pkl')
6 | app = Flask(__name__)
7 |
8 | @app.route('/', methods=['POST'])
9 | def predict():
10 | survivor_data = request.get_json()
11 | survived = model.predict(
12 | [
13 | survivor_data['Pclass'],
14 | survivor_data['Age'],
15 | survivor_data['SibSp'],
16 | survivor_data['Parch'],
17 | survivor_data['Fare'],
18 | survivor_data['Embarked'],
19 | survivor_data['Gender']
20 | ]
21 | )
22 | if survived == 0:
23 | return('You Died :(')
24 | else:
25 | return('You Live :)')
26 |
27 |
28 | if __name__ == '__main__':
29 |
30 | app.run(debug=True)
--------------------------------------------------------------------------------
/Python Syntax.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "metadata": {
3 | "name": "",
4 | "signature": "sha256:fb66232788be4df9f50b867b0bbdbc29a690bb9c4aedc195cec6ed98351e31ed"
5 | },
6 | "nbformat": 3,
7 | "nbformat_minor": 0,
8 | "worksheets": [
9 | {
10 | "cells": [
11 | {
12 | "cell_type": "markdown",
13 | "metadata": {},
14 | "source": [
15 | "**Quick, Non-Comprehensive Introduction to Python Syntax**\n",
16 | "\n",
17 | "Based on http://en.wikipedia.org/wiki/Python_syntax_and_semantics"
18 | ]
19 | },
20 | {
21 | "cell_type": "markdown",
22 | "metadata": {},
23 | "source": [
24 | "**Hello World**\n",
25 | "As easy as they go"
26 | ]
27 | },
28 | {
29 | "cell_type": "code",
30 | "collapsed": false,
31 | "input": [
32 | "print('Hello World!')"
33 | ],
34 | "language": "python",
35 | "metadata": {},
36 | "outputs": [
37 | {
38 | "output_type": "stream",
39 | "stream": "stdout",
40 | "text": [
41 | "Hello World!\n"
42 | ]
43 | }
44 | ],
45 | "prompt_number": 2
46 | },
47 | {
48 | "cell_type": "markdown",
49 | "metadata": {},
50 | "source": [
51 | "As a Script"
52 | ]
53 | },
54 | {
55 | "cell_type": "code",
56 | "collapsed": false,
57 | "input": [
58 | "#!/usr/bin/env python \n",
59 | "\n",
60 | "\n",
61 | "if __name__ == '__main__':\n",
62 | " print('Hello World!')"
63 | ],
64 | "language": "python",
65 | "metadata": {},
66 | "outputs": [
67 | {
68 | "output_type": "stream",
69 | "stream": "stdout",
70 | "text": [
71 | "Hello World!\n"
72 | ]
73 | }
74 | ],
75 | "prompt_number": 3
76 | },
77 | {
78 | "cell_type": "markdown",
79 | "metadata": {},
80 | "source": [
81 | "**List of Python Keywords**"
82 | ]
83 | },
84 | {
85 | "cell_type": "code",
86 | "collapsed": false,
87 | "input": [
88 | "from keyword import kwlist\n",
89 | "for keyword in kwlist:\n",
90 | " print(keyword)"
91 | ],
92 | "language": "python",
93 | "metadata": {},
94 | "outputs": [
95 | {
96 | "output_type": "stream",
97 | "stream": "stdout",
98 | "text": [
99 | "False\n",
100 | "None\n",
101 | "True\n",
102 | "and\n",
103 | "as\n",
104 | "assert\n",
105 | "break\n",
106 | "class\n",
107 | "continue\n",
108 | "def\n",
109 | "del\n",
110 | "elif\n",
111 | "else\n",
112 | "except\n",
113 | "finally\n",
114 | "for\n",
115 | "from\n",
116 | "global\n",
117 | "if\n",
118 | "import\n",
119 | "in\n",
120 | "is\n",
121 | "lambda\n",
122 | "nonlocal\n",
123 | "not\n",
124 | "or\n",
125 | "pass\n",
126 | "raise\n",
127 | "return\n",
128 | "try\n",
129 | "while\n",
130 | "with\n",
131 | "yield\n"
132 | ]
133 | }
134 | ],
135 | "prompt_number": 4
136 | },
137 | {
138 | "cell_type": "markdown",
139 | "metadata": {},
140 | "source": [
141 | "**Python uses whitespace to delimit program blocks**"
142 | ]
143 | },
144 | {
145 | "cell_type": "code",
146 | "collapsed": false,
147 | "input": [
148 | "def isEven(number):\n",
149 | " return number%2==0\n",
150 | "\n",
151 | "for x in range(1,5):\n",
152 | " #Loop starts here\n",
153 | " if isEven(x):\n",
154 | " print(x,'is even')\n",
155 | " else:\n",
156 | " print(x,'is odd')\n",
157 | " print('This will be printed every iteration')\n",
158 | " #Loop ends here\n",
159 | "print('This will only be printed once')"
160 | ],
161 | "language": "python",
162 | "metadata": {},
163 | "outputs": [
164 | {
165 | "output_type": "stream",
166 | "stream": "stdout",
167 | "text": [
168 | "1 is odd\n",
169 | "This will be printed every iteration\n",
170 | "2 is even\n",
171 | "This will be printed every iteration\n",
172 | "3 is odd\n",
173 | "This will be printed every iteration\n",
174 | "4 is even\n",
175 | "This will be printed every iteration\n",
176 | "This will only be printed once\n"
177 | ]
178 | }
179 | ],
180 | "prompt_number": 15
181 | },
182 | {
183 | "cell_type": "markdown",
184 | "metadata": {},
185 | "source": [
186 | "**Data Structures**"
187 | ]
188 | },
189 | {
190 | "cell_type": "code",
191 | "collapsed": false,
192 | "input": [
193 | "def a_function(an_argument):\n",
194 | " \n",
195 | " #An inline comment\n",
196 | " \n",
197 | " a_string = 'String'\n",
198 | " \n",
199 | " # Raw strings are useful to avoid string formatting, I mainly use them for file paths\n",
200 | " \n",
201 | " a_raw_string = r'C:\\Foo\\Bar'\n",
202 | " \n",
203 | " an_integer = 2\n",
204 | " \n",
205 | " a_float = 3.14\n",
206 | "\n",
207 | " #Lists are your standard collections\n",
208 | " a_list = [1,2,3,'Four']\n",
209 | "\n",
210 | " #Access the list\n",
211 | " a_list[0] # is 1\n",
212 | "\n",
213 | " #Dictionaries are key-value stores\n",
214 | " a_dictionary = {'Key' : 'Value',\n",
215 | " 'Perth' : 'Just Right',\n",
216 | " 'Melbourne' : 'Bad Weather',\n",
217 | " 'Sydney' : 'Too Busy'}\n",
218 | "\n",
219 | " #Access the Dictionary\n",
220 | " a_dictionary['Perth'] # is equal to 'Just Right'\n",
221 | " \n",
222 | " #Tuples are like lists but are immutable, I personally don't use them very much\n",
223 | " a_tuple = ('Perth', 'Melbourne', 'Sydney')\n",
224 | "\n",
225 | " #Access a tuple\n",
226 | "\n",
227 | " a_tuple[0] # == Perth\n",
228 | " \n",
229 | " #Sets are unordered collections of unique elements, they are very useful for set operations!\n",
230 | " a_set = {0, False, 'Perth'}"
231 | ],
232 | "language": "python",
233 | "metadata": {},
234 | "outputs": [],
235 | "prompt_number": 5
236 | },
237 | {
238 | "cell_type": "markdown",
239 | "metadata": {},
240 | "source": [
241 | "**Functional Programming**"
242 | ]
243 | },
244 | {
245 | "cell_type": "code",
246 | "collapsed": false,
247 | "input": [
248 | "#List comprehensions are one of the most useful features of python\n",
249 | "#Creating complicated lists becomes easy!\n",
250 | "\n",
251 | "X = [x for x in range(0,100) if x%3==0]\n",
252 | "\n",
253 | "#Anonymous functions\n",
254 | "\n",
255 | "double = lambda x: x + x\n",
256 | "\n",
257 | "#map may be more readable than list comprehensions if you have already defined a function\n",
258 | "#In Python 3 it returns an iterable rather than a list for efficiency\n",
259 | "\n",
260 | "map(double, range(0,10))\n",
261 | "\n",
262 | "for number in map(double, range(0,10)):\n",
263 | " print(number)"
264 | ],
265 | "language": "python",
266 | "metadata": {},
267 | "outputs": [
268 | {
269 | "output_type": "stream",
270 | "stream": "stdout",
271 | "text": [
272 | "0\n",
273 | "2\n",
274 | "4\n",
275 | "6\n",
276 | "8\n",
277 | "10\n",
278 | "12\n",
279 | "14\n",
280 | "16\n",
281 | "18\n"
282 | ]
283 | }
284 | ],
285 | "prompt_number": 14
286 | }
287 | ],
288 | "metadata": {}
289 | }
290 | ]
291 | }
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # FullStackDataAnalysis
2 | Presentation: Full Stack Data Analysis With Python, February 2015 for Perth Data Science Meetup
3 |
4 | **Author**: Jack Golding, reachable at *jackgolding@live.com.au*
5 |
6 | View these notebooks at:
7 |
8 | http://nbviewer.ipython.org/github/jackgolding/FullStackDataAnalysis/tree/master/
9 |
10 | Video of talk at:
11 |
12 | https://www.youtube.com/watch?v=N17XGVWAjv8
13 |
14 | **Steps**
15 |
16 | 1. Clone this repo using `git clone https://github.com/jackgolding/FullStackDataAnalysis.git` or by simply downloading the files however you seem fit.
17 | 2. Download `Anaconda 2.1` with `Python 3.4` as outlined at http://continuum.io/downloads#34 if Anaconda or Python is updated on continuum's site after this talk has been given you will have to specify the version of Anaconda and/or Python later or risk the code not working.
18 | 3. Install Anaconda wherever you want. The beauty of using Anaconda is that deleting it if you don't want it is just a case of deleting the `Anaconda` file after installing.
19 | 4. Open a Command Prompt and navigate to the folder you downloaded in Step 1 using `cd FILEPATH` where FILEPATH is the path of the folder.
20 | 5. Run `conda create -n FullStack --clone root` if you downloaded Anaconda 2.1 and Python 3 in Sterp 2. If you are using a later version of Python and/or Anaconda you will probably need to run something like `conda create -n FullStack anaconda=2.1.0 python=3.4`
21 | 6. Verify the environment you created in `5` exists by running `conda info -e` and noticing you have two environments, `root` and `FullStack`
22 | 7. Activate the `FullStack` environment by running `source activate FullStack` - this command may differ depending on what operating system you are using but you should get an useful error message if it doesn't work.
23 | 8. To open notebooks run `ipython notebook` to start the IPython Notebook server.
24 |
25 | Please raise any errors as a github issue and star the project if you found it useful.
26 |
--------------------------------------------------------------------------------