-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathindex.html
More file actions
26 lines (24 loc) · 775 Bytes
/
index.html
File metadata and controls
26 lines (24 loc) · 775 Bytes
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
<html>
<head>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@1.0.0/dist/tf.min.js"></script>
<script src="utility.js"></script>
</head>
<body>
<img id="slideBg" src='test.jpg' crossorigin='anonymous' />
<script>
function main(model){
let img = document.getElementById("slideBg");
img.onload=()=>{
setTimeout(() => {
predict(img,model);
}, 1000);
};
if(img.complete)
{
predict(img,model);
}
}
tf.loadLayersModel('https://raw.githubusercontent.com/ffantasy/CapchaBot/master/object_detection_model/model.json').then(m=>main(m));
</script>
</body>
</html>