-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
156 lines (154 loc) · 8 KB
/
Copy pathindex.html
File metadata and controls
156 lines (154 loc) · 8 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
<!DOCTYPE html>
<html>
<head>
<!--Import Google Icon Font-->
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!--Import materialize.css-->
<link type="text/css" rel="stylesheet" href="sass/materialize.css" media="screen,projection" />
<!--Let browser know website is optimized for mobile-->
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!-- Import custom CSS -->
<link rel="stylesheet" href="css/styles.css">
<title>Image Labeler</title>
</head>
<body>
<header>
<h1 class="center pink-text text-lighten-2">
Open Image Labeler
</h1>
</header>
<div class="container">
<div class="row">
<div class="col l2">
<ul>
<li>
<ul class="collapsible">
<li><a href="#"
class="collapsible-header waves-effect waves-purple pink-text text-lighten-2 bold">
Import
</a>
<div class="collapsible-body no-padding">
<ul>
<a href="#!" id="import-image" class="waves-effect waves-purple display-block">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">insert_photo</i>Image</li>
</a>
<a href="#!" id="import-folder" class="waves-effect waves-purple">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">folder_open</i>Image Folder
</li>
</a>
</ul>
</div>
</li>
</ul>
</li>
<li>
<ul class="collapsible remove-top-border">
<li><a href="#"
class="collapsible-header waves-effect waves-purple pink-text text-lighten-2 bold">
Mode
</a>
<div class="collapsible-body no-padding">
<ul>
<a href="#!" onclick="changeAnnotationMode('rect');" class="waves-effect waves-purple display-block">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">check_box_outline_blank</i>Rectangle
</li>
</a>
<a href="#!" onclick="changeAnnotationMode('poly');" class="waves-effect waves-purple full-width">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">gesture</i>Polygon</li>
</a>
</ul>
</div>
</li>
</ul>
</li>
<li>
<div id="navigation" class="z-depth-1 pink-text text-lighten-2 center">
<a onclick="changeImage('left');" href="#"><i
class="no-margin material-icons left pink-text text-lighten-2 waves-effect waves-purple">arrow_back_ios</i></a>
<span id="navigator-text">0 / 0</span>
<a onclick="changeImage('right');" href="#"><i
class="no-margin material-icons right flip-horizontal pink-text text-lighten-2 waves-effect waves-purple">arrow_back_ios</i></a>
</div>
</li>
</ul>
</div>
<div class="col l8">
<div id="placeholder"></div>
</div>
<div class="col l2">
<ul>
<li>
<ul class="collapsible">
<li><a href="#"
class="collapsible-header waves-effect waves-purple pink-text text-lighten-2 bold">
Export
</a>
<div class="collapsible-body no-padding">
<ul>
<a href="#!" onclick="exportPascalVOCXML();" class="waves-effect waves-purple display-block">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">save</i>Pascal VOC XML</li>
</a>
</ul>
</div>
<div class="collapsible-body no-padding">
<ul>
<a href="#!" onclick="exportAWSObjectDetection();" class="waves-effect waves-purple display-block">
<li class="option-padding pink-text text-lighten-2"><i
class="material-icons sub-icons left">save</i>AWS Sagemaker Object Detection</li>
</a>
</ul>
</div>
</li>
</ul>
</li>
<li>
<div id="labels-container" class="labels-container z-depth-1">
<span class="bold pink-text text-lighten-2">Labels</span>
<div class="chips-placeholder" id="chips-selector"></div>
</div>
</li>
</ul>
</div>
</div>
</div>
<!-- JQuery -->
<script src="https://code.jquery.com/jquery-3.5.1.min.js"
integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=" crossorigin="anonymous"></script>
<!-- Materialize JS -->
<script type="text/javascript" src="js/bin/materialize.min.js"></script>
<!-- p5.js -->
<script src="https://cdn.jsdelivr.net/npm/p5@1.0.0/lib/p5.js"></script>
<!-- Import JSZip -->
<script src="js/jszip.min.js"></script>
<!-- Import FileSaver -->
<script src="js/FileSaver.js"></script>
<!-- Custom JS -->
<script src="js/annotator.js"></script>
<script src="js/inputHandler.js"></script>
<script src="js/navigator.js"></script>
<script src="js/chipHandler.js"></script>
<script src="js/exporter.js"></script>
<script>
$(document).ready(function () {
$('.collapsible').collapsible();
});
$('.chips-placeholder').chips({
onChipSelect: (input) => chipSelected(input),
onChipAdd: (input) => chipAdded(input[0].childNodes[input[0].childNodes.length - 2], input[0].childNodes.length === 2),
onChipDelete: (input) => chipDeleted(input[0].childNodes.length === 2, input[0].childNodes.length === 1),
placeholder: 'Enter a label',
secondaryPlaceholder: '+Label',
});
let chipsStartupInstance = M.Chips.getInstance(document.getElementById('chips-selector'));
chipsStartupInstance.addChip({
tag: 'default'
});
setChipsInstance(chipsStartupInstance);
</script>
</body>
</html>