-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathindex.html
More file actions
458 lines (382 loc) · 14.7 KB
/
index.html
File metadata and controls
458 lines (382 loc) · 14.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ComputerVision</title>
<meta name="description" content="Free Bootstrap Theme by uicookies.com">
<meta name="keywords" content="free website templates, free bootstrap themes, free template, free bootstrap, free website template">
<!-- <link href="https://fonts.googleapis.com/css?family=Open+Sans:300,400" rel="stylesheet"> -->
<link rel="stylesheet" href="css/styles-merged.css">
<link rel="stylesheet" href="css/style.min.css">
<link rel="stylesheet" href="css/custom.css">
<link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="css/app.css">
<style>
#main2{
margin-top:-260px;
}
.button1 {
box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19);
background-color: #fff;
padding: 10px ;
border-radius: 12px;
position: relative;
margin: 12px 0 12px;
align-content: center;
left: 280px;
}
.button1:hover {
box-shadow: 0 12px 16px 0 rgba(0,0,0,0.24), 0 17px 50px 0 rgba(0,0,0,0.19);
opacity: 0.5;
}
.heading1 {
text-shadow: 3px 2px white;
font-family: Arial, Helvetica, sans-serif;
font-size: 50px;
font-weight: bold;
box-shadow: #fff;
}
.container{
text-align: center;
padding: 15px;
}
.bg1{
background: #ffffff;
}
.bg2{
background: #efefef;
}
.skeletal-gradient{
background-image: linear-gradient(to right, #43e97b 0%, #38f9d7 100%);
height: 80vh;
}
.modal1button {
background: rgb(0,0,0,0.2);
padding: 1em 2em;
border: 0;
}
.modal1button:hover {
background: rgb(0,0,0,0.2);
}
.modal1 {
display: block;
position: fixed;
z-index: 1;
left: 0;
top: 0;
height: 100%;
width: 100%;
overflow: auto;
background-color: rgba(0,0,0,0.2);
}
.modal1-content {
background-color: #f4f4f4;
margin: 10% auto;
width: 60%;
box-shadow: 0 5px 8px 0 rgba(0,0,0,0.2), 0 7px 20px 0 rgba(0,0,0,0.17);
animation-name: modalopen;
animation-duration:2s;
}
.modal1-header h2 .modal-footer h3{
margin: 0
}
.modal1-header{
background: #efefef;
padding: 15px;
color: #fff;
}
.modal1-body{
padding: 10px 20px;
}
.modal1-footer {
background: #efefef;
padding: 10px;
color: #fff;
text-align: center;
}
.closeBtnmodal1 {
float: right;
font-size: 30px;
padding:10px;
}
.closeBtnmodal1:hover,.closeBtn:focus{
text-decoration: none;
cursor: pointer;
}
.closeBtnmodal2 {
color: ;
float: right;
font-size: 30px;
color: ;
padding:10px;
}
.closeBtnmodal2:hover,.closeBtn:focus{
color: ;
text-decoration: none;
cursor: pointer;
}
@keyframes modalopen{
from{opacity: 0}
to{opacity: 1}
}
</style>
<!--[if lt IE 9]>
<script src="js/vendor/html5shiv.min.js"></script>
<script src="js/vendor/respond.min.js"></script>
<![endif]-->
</head>
<body>
<!-- START: header -->
<div class="probootstrap-loader"></div>
<div id="myModal" class="modal fade" role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">
<center>
<h2>New features added on page</h2>
</center>
</h4>
</div>
<div class="modal-body">
<p>1.Some text in the modal.</p>
<p>2.Some text in the modal.</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div>
</div>
</div>
</div>
<header role="banner" class="probootstrap-header">
<div class="container">
<a href="index.html" class="probootstrap-logo" style='height:30px;'>ComputerVision</a>
<a href="#" class="probootstrap-burger-menu visible-xs"><i>Menu</i></a>
<div class="mobile-menu-overlay"></div>
<nav role="navigation" class="probootstrap-nav hidden-xs">
<ul class="probootstrap-main-nav">
<li class="active"><a href="index.html">Home</a></li>
<li><a href="about.html">About</a></li>
<li><a href="contact.html">Contact</a></li>
</ul>
</nav>
</div>
</header>
<!-- END: header -->
<div class="probootstrap-main">
<section class="probootstrap-section-half">
<div class="probootstrap-image probootstrap-animate" data-animate-effect="fadeIn" style="background-image: url(img/image_1.jpg)"></div>
<div class="probootstrap-text">
<div class="probootstrap-inner probootstrap-animate">
<h1 class="heading">ComputerVision</h1>
<p>With the help of AI, machines now also have senses and they can work with the help of taking signals via
these senses. Image recognition is one of its senses. Here is a collection of some cool projects which
incorporates the image recognising power of computer and help you do creative things.</p>
<h1>Let's get started!</h1>
</div>
</div>
</section>
<!-- END section -->
<section class="probootstrap-section-half probootstrap-reverse skeletal-gradient">
<div class="container">
<h1 class="heading" style="color:#fff;">Skeletal</h1>
</div>
<div id = "simpleModal1" class = "modal1">
<div class = "modal1-content">
<span class="closeBtnmodal1">×</span>
<div class="modal1-header">
<h2>Skeletal</h2>
</div>
<div class = "modal1-body">
<p><b>Instructions</b></p>
<p><i>PoseNet runs with either a single-pose or multi-pose detection algorithm. The single person pose detector is faster and more accurate but requires only one subject present in the image.
The output stride and image scale factor have the largest effects on accuracy/speed. A higher output stride results in lower accuracy but higher speed. A higher image scale factor results in higher accuracy but lower speed.
Add the instruction window giving users the the insructions so that they are in proper lighting and at appropriate distance from the webcam. This should come under the Skeletal section before loading the canvas.</i>
</p>
</div>
<div class = "modal1-footer">
<h3></h3>
</div>
</div>
</div>
<div id='main' style='display:none;padding:50px;'>
<video id="video" playsinline style=" -moz-transform: scaleX(-1);
-o-transform: scaleX(-1);
-webkit-transform: scaleX(-1);
transform: scaleX(-1);
display: none;
">
</video>
<canvas id="output" />
</div>
<div id="loading" class="probootstrap-image probootstrap-animate " style="background-color:none;padding:50px;height:400px;width:35%;"></div>
<div id="menu" class="probootstrap-image probootstrap-animate bg1" style="padding:30px;height:400px;width:20%;"></div>
<canvas class="probootstrap-image probootstrap-animate bg2" id="output2" style="padding:50px;height:400px;width:35%;" />
</div>
<button class="button1" onclick="startVideo();">Start WebCam</button>
<button class="button1" onclick="stopVideo();">Stop WebCam</button>
<button id = "modal1Btn" class = "button1 modal1button">Click Here</button>
</section>
<!-- END section -->
<section class="probootstrap-section-half">
<div id="box" class="probootstrap-image probootstrap-animate" style="background-color:#57846c;padding:50px;height:600px;width:600px;"></div>
<div class="probootstrap-text">
<div class="probootstrap-inner probootstrap-animate">
<h1 class="heading">Tilt your head to change color</h1>
<p>This supercool project let you play with the css objects with the head gesture. Tilt your head left or right to change color of this box.</p>
<div id = "simpleModal2" class = "modal1">
<div class = "modal1-content">
<span class="closeBtnmodal2">×</span>
<div class="modal1-header">
<h2>Tilt Your Head</h2>
</div>
<div class = "modal1-body">
<p><b>Instructions</b></p>
<p class="text-modal2">This feature allows you to change the colour of the left adjoined box with just a tilt of your head! Just follow the below given steps and see the magic unfold.</p>
<ol class="steps-modal2">
<li>Click on the 'START WEBCAM' button, this will turn on your webcam so your head motions can be recogised</li>
<li>Tilt your head from one side to another and watch the box change its hues.</i>
<li>Click on 'STOP WEBCAM' button to shut off your webcam.</li>
</ol>
<br><br>
</div>
<div class = "modal1-footer">
<h3></h3>
</div>
</div>
</div>
<button class="button1" onclick="startVideo2();">Start WebCam</button>
<button class="button1">Stop WebCam</button>
<button id = "modal2Btn" class = "button1 modal1button">Click Here</button>
<div id='main2' style='display:none;'>
<video id="video2" playsinline style=" -moz-transform: scaleX(-1);
-o-transform: scaleX(-1);
-webkit-transform: scaleX(-1);
transform: scaleX(-1);
display: none;
">
</video>
<canvas id="output3" />
</div>
</div>
</div>
</section>
<!-- END section -->
<section class="probootstrap-section-half probootstrap-reverse">
<div class="probootstrap-image probootstrap-animate" data-animate-effect="fadeIn" style="background-color: #845858"></div>
<div class="probootstrap-text">
<div class="probootstrap-inner probootstrap-animate">
<h1 class="heading">Another awesome project</h1>
<p>Stay tuned.</p>
<h1></h1>
</div>
</div>
</section>
<!-- END section -->
<div class="container">
<div class="digit-demo-container" style="width:800px;background-color:#a2b9bc;">
<h3 id="digit-recognizer-live-demo" style="width:800px;background-color: #878f99;">Digit Recognizer</h3>
<div class="flex-two" style="margin-top: 20px;">
<button id="clear_canvas" style="background-color: #F5FFFA;" class="material-button-pink" onclick="clearCanvas(this.id)">Clear</button>
<select id="select_model">
<option>CNN</option>
<option>MLP</option>
</select>
<button id="predict_canvas" style="background-color: #F5FFFA;" class="material-button-pink" onclick="predict(this.id)">Predict</button>
</div>
<div class="flex-two">
<div id="canvas_box_wrapper" class="canvas-box-wrapper">
<div id="canvas_box" class="canvas-box"></div>
</div>
<div id="result_box">
<canvas id="chart_box" width="100" height="100"></canvas>
</div>
</div>
</div>
</div>
<!-- END section -->
<section class="probootstrap-section-half probootstrap-reverse">
</section>
<!-- END section -->
</div>
<footer class="probootstrap-footer">
<div class="container">
<div class="row">
<div class="col-md-12">
<p>
<br> This is a Pure Javascript implementation of: <a href="https://github.com/tensorflow/tfjs-models/tree/master/posenet"
target="_blank" rel="noopener">PoseNet</a>.
<br> Thank you <a href="https://js.tensorflow.org" target="_blank" rel="noopener">TensorFlow.js</a> for
your flexible and intuitive APIs.
</p>
</div>
</div>
</div>
</footer>
<div class="gototop js-top">
<a href="#" class="js-gotop"><i class="icon-chevron-thin-up"></i></a>
</div>
<script>
//Get modal element
var modal = document.getElementById('simpleModal1');
var modalBtn = document.getElementById('modal1Btn');
var closeBtn = document.getElementsByClassName('closeBtnmodal1')[0];
closeModal();
//listen for click
modalBtn.addEventListener('click', openModal);
//listen for close click
closeBtn.addEventListener('click', closeModal);
//Listen for outside click
window.addEventListener('click', outsideClick);
function openModal(){
modal.style.display = 'block';
}
function closeModal(){
modal.style.display = 'none';
}
function outsideClick(e){
if(e.target==modal){
modal.style.display = 'none';
}
}
var modal2 = document.getElementById('simpleModal2');
var modal2Btn = document.getElementById('modal2Btn');
var close2Btn = document.getElementsByClassName('closeBtnmodal2')[0];
closeModal2();
//listen for click
modal2Btn.addEventListener('click', openModal2);
//listen for close click
close2Btn.addEventListener('click', closeModal2);
//Listen for outside click
window.addEventListener('click', outsideClick2);
function openModal2(){
modal2.style.display = 'block';
}
function closeModal2(){
modal2.style.display = 'none';
}
function outsideClick2(e){
if(e.target==modal2){
modal2.style.display = 'none';
}
}
</script>
<script src="js/scripts.min.js"></script>
<script src="js/main.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/dat.gui@0.7.2/build/dat.gui.js"></script>
<script src="https://unpkg.com/@tensorflow/tfjs"></script>
<script src="https://unpkg.com/@tensorflow-models/posenet"></script>
<script src="js/demo_util.js"></script>
<script src="js/stats.min.js "></script>
<script src="js/camera.js"></script>
<script src="js/camera2.js"></script>
<script src="js/modal.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@latest"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.4.0/Chart.min.js"></script>
<script type="text/javascript" src="js/app.js"></script>
<script type="text/javascript" src="https://code.jquery.com/jquery-2.3.1.min.js"></script>
</body>
</html>