## 2 Materials and Methods
### Fire Prevention and Fire Detection
#### 2.2.4 FireSense Image Annotation Tool  
For image annotation, there are many tools available. The drawing of polygons, rectangles, points, and lines is one of the fundamental features that every annotation tool must have. Additionally, they must be able to export annotated data in multiple formats that are used by different deep-learning models for computer vision. Data from various annotation tools are exported in a variety of formats. The two most popular formats are Pascal VOC and Microsoft COCO. The main difference between COCO and Pascal VOC is the file format. COCO is stored in JSON format [34], whereas Pascal VOC is stored in XML format [35]. There are also some additional distinctions in the way the annotation data are presented in the stored format. LabelMe [36] is the most-often-used tool for data annotation and was developed by MIT researchers. It is a Web-application tool for image annotation. Although the online application is closed to new users, a copy of the Python-written program has been created and is now in use. This application exports the data in XML format. The biggest disadvantage of the LabelMe annotation tool is that the dataset must be distributed to multiple computers in order for numerous users to annotate it. Another popular annotation tool is the free and open-source browser-based Computer Vision Annotation Tool (CVAT) [37]. It is used for digital image and video annotation. The tasks of image classification, object detection, and picture segmentation can be accomplished with CVAT. Annotators can cooperate on a particular project because projects can be local or shared online. One of the advantages of CVAT is that it can use the TensorFlow API to automatically annotate images. The client side of the CVAT application is limited to working only on the specified browser engine because it only supports Google Chrome and chromium-based browsers. Make Sense [38] is another well-liked tool for annotating data. Make Sense is a GitHub-hosted, free-to-use image-annotation online application. Users can export image-annotation data in a variety of formats. For the purpose of creating a quality dataset, a new image-annotation tool called FireSense was developed. It is based on the previously mentioned open-source Make Sense tool but with several improvements. The dataset is located on a centralized server, and batches of randomly selected images are sent to the annotators. Administators can easily manage the images in the dataset. Additionally, double-blind image annotation with a 90% intersection over union (IOU) overlap is enabled with random batches. Annotations are manually checked if the IOU is less than 90%. It has a backend (on the server side) and a frontend (on the client side), both of which are hosted on a dedicated server. Clients connect using a Web browser. It also allows users to export image-annotation data in a variety of formats, which include CSV, YOLO, VOC XML, VGG JSON, and COCO. When a user logs in, they immediately receive a batch of images. The large area in the middle shows the editor viewport, where polygons can be added or modified. In the left sidebar, all images from the batch are listed. The top-right sidebar shows all the labels that users annotated. There, the user can change the polygon's class, toggle the visibility, or remove the polygon. In the bottom-right sidebar, the user can change other information about the image, including type of space, time of day, whether there is an artificial light source, the size of the flame, etc. The FireSense interface is presented in Figure 12.  
To create an annotated-image dataset, some of the images from the dataset mentioned in Section 2.2.1 were used along with some additional fire images acquired from several different firefighting departments, and by using the abovementioned image-annotation tool, we created a dataset of 11,164 manually annotated images. That dataset includes a total of 48,662 flame annotations, 3350 smoke annotations, and 1230 non-fire images.