Sketch-based Manga Retrieval using Manga109 Dataset

Manga (Japanese comics) are popular worldwide. However, current e-manga archives offer very limited search support, including keyword-based search by title or author, or tag-based categorization. To make the manga search experience more intuitive, efficient, and enjoyable, we propose a content-based manga retrieval system. First, we propose a manga-specific image-describing framework. It consists of efficient margin labeling, edge orientation histogram feature description, and approximate nearest-neighbor search using product quantization. Second, we propose a sketch-based interface as a natural way to interact with manga content. The interface provides sketch-based querying, relevance feedback, and query retouch. For evaluation, we built a novel dataset of manga images, Manga109, which consists of 109 comic books of 21,142 pages drawn by professional manga artists. To the best of our knowledge, Manga109 is currently the biggest dataset of manga images available for research. We conducted a comparative study, a localization evaluation, and a large-scale qualitative study. From the experiments, we verified that: (1) the retrieval accuracy of the proposed method is higher than those of previous methods; (2) the proposed method can localize an object instance with reasonable runtime and accuracy; and (3) sketch querying is useful for manga search.


I. INTRODUCTION
M ANGA are Japanese black-and-white comics ( Fig. 1).
They are popular worldwide. Nowadays, manga are distributed not only in print, but also electronically via online stores such as Amazon Kindle Store 1 . Some e-manga archives are very large; e.g., the Amazon Kindle store sells more than 130,000 e-manga titles 2 . Therefore, users of online stores must retrieve titles from large collections when they purchase new manga.
However, current e-manga archives offer very limited search support, i.e., keyword-based search by title or author, or tagbased categorization. They are not suitable for large-scale search and searches cannot take the images (contents) of manga into consideration. For this reason, applying contentbased multimedia retrieval techniques to manga search would have the potential to make the manga-search experience more intuitive, efficient, and enjoyable.
There are three unique challenges associated with contentbased manga retrieval. (1) The manga image description Y. Matsui   problem. First, the visual characteristics of manga images are very different from those of naturalistic images. For example, as shown in Fig. 1, manga images are usually line drawings comprising black lines on a flat white background. Therefore, manga images often do not have varying gradient intensities, unlike naturalistic images. Traditional local-feature characterizations, such as scale-invariant feature transform (SIFT) [1], may not be suited to describing manga images. (2) Retrievallocalization problem. Furthermore, a manga page comprises several frames (rectangular areas). It is therefore necessary to retrieve not only an image, but also a part of the image. This is a combined problem of retrieval and localization, and solutions must allow fast processing to achieve large-scale retrieval. (3) Query modality problem. The final challenge is to find a way of efficiently querying manga images. Suppose that a user wants to retrieve the face of the boy in Fig. 1(c). Usually, we do not have annotations that describe the specific region, so we must somehow find a way of querying this region. Because manga images are mostly black-and-white drawings, users should have access to some form of drawing, such as examples of manga images or sketches of their own. For this reason, it is important to provide a natural sketch-based interface for manga retrieval.
In this paper, we propose a content-based manga retrieval system that addresses the above three challenges.
• First, we propose a manga-specific image-describing framework, namely an objectness-based edge orientation histogram (EOH) with product quantization. The system is composed of three steps: labeling of margin areas, EOH feature description [2], and approximate nearest-neighbor (ANN) search using product quantization (PQ) [3]. comparative study confirmed that the proposed method can efficiently describe manga images, and can yield better accuracy than the state-of-the-art sketch-based retrieval methods [4], [5]. In addition, we evaluated the proposed method in the instance detection framework, and verified that the proposed method can achieve both retrieval and localization from 21,142 manga pages in less than a second with reasonable accuracy. • Second, we study the feasibility of a sketch-based interface as a more natural way for people to interact with manga content. Sketch-based interfaces for retrieving multimedia contents have been explored previously [4], [6], [7], and we conjecture that they are particularly suited to manga. In addition, based on the sketch interaction, we built two interactive reranking schemes for an intuitive manga search experience: relevance feedback and query retouch. An overview of the GUI implementation of the proposed system is shown in Fig. 2. Given a query sketch ( Fig. 2(a)), the system retrieves similar areas from a manga dataset in real time, and shows the top results in thumbnail windows ( Fig. 2(c)). The retrieval is performed automatically after each stroke is completed. If a user clicks on one of the retrieved results in the thumbnail windows, a page containing the result is shown in a preview window ( Fig. 2(d)). In this case, the page containing the first-ranked result is shown. Please see the supplemental video for more details.
For evaluation, we built a novel dataset of manga images drawn by professional manga artists, Manga109, which consists of 109 comic books with a total of 21,142 pages. Manga109 will be very beneficial for the multimedia research community because it has been difficult for researchers to use "real" manga in experiments due to the copyright problem. Research so far has been limited to the small scale. We made this dataset with permission from 94 professional creators. The dataset covers a wide range of manga genres, and is publicly available for academic use.
Our contributions are summarized as follows: • We propose a sketch-based manga retrieval system, which enables us to retrieve a manga image in 70 ms from 21,142 pages using a notebook PC. The method consists of a manga-specific image description system, and a sketch-based interactive query scheme, including rele-vance feedback and query retouch. • We provide a publicly available manga dataset, Manga109, which includes 109 manga titles containing 21,142 pages that will be useful for manga imageprocessing research. For applications, the proposed method can be integrated in a tablet or a PC to retrieve purchased manga titles stored in each user's computers, or implemented as a Web-based interface to search manga titles at e-manga services such as Amazon. The system is useful in several scenarios. (1) A user wants to find a manga title that contains an object that is hard to represent by words, but easy to represent with a sketch query, such as "Japanese-style clothing" (Fig. 8(a)). (2) A user does not have a specific title in mind, but tries to find interesting manga, such as one in which cute girls appear. In these cases, our proposed query interactions can be useful ( Fig. 16(a)). (3) After the initial search is performed using text queries, a user can rerank the retrieved results by sketch interactions, e.g., a user selects "Dragon Ball" titles by typing "Dragon Ball", and then refines results by drawing some characters.
A preliminary version of this work appeared in our recent conference paper [8]. This paper contains significant differences: (1) we constructed and released the publicly available manga dataset; (2) we significantly improved the proposed algorithm by leveraging an objectness measure and PQ; and (3) we performed massive experimental evaluations using the new dataset, including comparisons with state-of-the-art methods.
The rest of the paper is organized as follows: Section II introduces related work. Section III presents our retrieval system and Section IV shows the proposed query interaction schemes. A novel dataset is introduced in Section V and evaluations are given in Section VI.

II. RELATED WORK
We discuss related studies in content-based manga retrieval by categorizing them into three challenges: the manga description problem, the retrieval-localization problem, and the querying problem. Additionally, we introduce research related to manga.

A. Manga image description
In the literature of content-based image retrieval, many methods have been proposed to describe images. A query and dataset images are converted to some form of vector representation to evaluate their similarity. A typical form is the bag-of-features (BoF) representation [9], in which local features such as SIFT [1] are extracted from an image and quantized into a sparse histogram. The distance between a query histogram and a dataset histogram can be computed efficiently using an inverted index structure. The BoF form has been studied widely because it achieved successful image description with fast computation.
Various extensions of BoF have been proposed so far, including query expansion [10], soft voting [11], and Hamming embedding [12]. The state-of-the-art in this line are the vector of locally aggregated descriptors (VLAD) and Fisher vector (FV) approaches [13], [14], [15], which are interpreted as generalized versions of BoF [16]. However, all of the above methods were designed for natural images for both query and dataset. Thus, special attention has been paid to cases in which a query is a line drawing, i.e., a sketch.
If a query is presented as a form of sketch, several special features tailored for sketch queries have been proposed. BoF using a histogram of oriented gradients [17] was proposed [5], [6], [18]. Because sketch images usually have a flat background of uniform white pixels, several methods tried to fill such blank areas with meaningful values and interpreted them as a feature vector; e.g., distance-transformed values from edge pixels [19] and Poisson image-editing-based interpolation values [20], [21]. To reduce the impact of noisy edges, a line segment-based descriptor was proposed [22]. Chamfer matching, which is a successful method for computing the similarity between two contours of objects, was incorporated in the sketch-based retrieval framework [4], [7], [23].
In the manga feature description task, we compared the proposed method with (1) BoF, (2) large-window FV as the state-of-the-art of BoF-based methods [5], and (3) compact oriented chamfer matching (Compact OCM) as the state-ofthe-art of chamfer-based methods [4].
Note that deep-learning techniques are becoming quite popular in image recognition because of their superior performance. These technologies are being applied to the sketch processing. However, the effectiveness of such methods has not yet been discussed sufficiently. For example, Yu and colleagues [24] reported that traditional methods such as FV are still competitive for a sketch recognition task, and therefore such deep learning-based features are beyond the scope of this paper.

B. Retrieval and localization
As shown in Fig. 1, our objective is to find not only a similar page, but also identify a similar region in the retrieved image. This kind of task has been tackled in spatial verification-based reranking methods [25], [26], [27], [28], [29], [30], [31]. These methods first find candidate images by BoF, and rerank the top results by spatial information such as relative positions among extracted SIFT features. However, such methods cannot be applied to manga for two reasons. First, the manga image's structure is more complex than that of a natural image. A single manga page usually consists of several frames, each of which is a totally different visual scene (see Fig. 1(b)). Therefore, a manga page can be interpreted as a set of images if we treat each frame as a single image. This is a much harder condition than those usual in image processing tasks such as retrieval or recognition, which assume that at least an image is a single image rather than a set of images. Second, BoF does not work well for manga as shown in the experimental section.
Another related area is object-detection methods, in which the position of a target object is identified in an input image. A number of methods have been proposed so far. Among them, contour-based object localization methods [32], [33] are closely related to our manga problem because an object is represented by its contour. In such methods, an instance of a target object such as "giraffe" is localized from an image by matching a query contour of giraffe, which is learned from training data. If we apply such methods to all dataset pages and select the best result, we might achieve both retrieval and localization at once. However, this is not realistic because: (1) these methods usually require learning to achieve reasonable performance, i.e., many giraffe images are required to localize an instance of giraffe, but a query is usually a single sketch in our case; and (2) localization usually takes time and cannot be scaled to a large number of images.
The proposed method makes use of a simple approach: window-based matching. It is also slow, but we formulate the search and localization as a single nearest-neighbor problem, and solve it using ANN methods.

C. Querying
How to query multimedia data has been an important problem in content-based multimedia retrieval [34]. Although many approaches have been proposed, including keywords, images, and spatial/image/group predicates [35], we focus on sketches drawn by users. Sketch-based interaction is the most natural way for humans to describe visual objects, and is widely adapted not only for image retrieval, but also in many applications such as shape modeling [36], image montage [37], texture design [38], and as a querying tool for recognizing objects [5], [39].
Several studies have explored manga retrieval [59], [60], [61], [62]. In these methods, inputs are usually not pages but cropped frames or characters, and evaluations were conducted using a small number of examples. In addition, the runtimes of these methods have not been discussed fully. Therefore, it is not known whether these methods can scale to a large dataset. On the other hand, the proposed method can perform a retrieval from 21,142 pages in 70 ms.

III. MANGA RETRIEVAL SYSTEM
In this section, we present the proposed manga retrieval system. Fig. 3 shows the framework of the system. First, input pages are preprocessed offline ( Fig. 3(d). This is discussed in Section III-D). Next, region of interest (ROI) areas are detected and EOH features are extracted ( Fig. 3(  Section III-A). These features are then compressed into PQ codes ( Fig. 3(b), as discussed in Section III-B). At query time, given a query sketch, similar EOF regions are retrieved ( Fig. 3(c), as discussed in Section III-C). The system is designed to solve both the manga image description and retrieval-localization problems.
The proposed framework is based on the window search paradigm; i.e., several features are extracted from dataset images using a generic object detector, and a query feature is compared with all features. Compared with the traditional image retrieval problem, such a window system is usually too slow to handle a large number of features. We formulate the problem as a single ANN search, and solve it using PQ, with effective preprocessing including the labeling of margin areas.
Note that we delete screen tone (texture) areas in advance during the preprocessing [52].

A. EOH feature description with object windows
We first show a core part of the system, feature description ( Fig. 3(a)). We employ EOH features [2], which compute an EOH for a square target ROI. Given a page, candidate areas of objects are detected automatically (Fig. 3(a1)), then EOH features are described from selected areas (Fig. 3(a2)). The retrieval is performed by matching an EOH feature of the query against the EOH features in the dataset. Fig. 4 shows an example of the feature representation. The EOF feature of the red square area in Fig. 4(a) is visualized as shown in Fig. 4(b).
The candidate areas of objects are detected by generic object detectors [63], [64], [65], which are successful ways to replace a sliding window paradigm. (Fig. 3(a1)). Intuitively, these detectors compute bounding boxes, which are more likely to contain any kinds of objects. These bounding boxes are considered as candidates for object instances, and a processing task such as image recognition is applied only to the bounding box areas, which greatly reduces computational costs compared with a simple sliding window approach.
We found that objectness measures can detect candidate manga image objectives more effectively than the sliding window approach. We constructed an experiment using a small dataset in which ground-truth objects (a head of a man) are annotated. The detection rate of a few methods were evaluated as shown in Fig. 5. BING [65], selective search [64], and sliding window (baseline) [8] are compared. From the results, we concluded that selective search is the best approach for this dataset. In the rest of this paper, we use selective search for our object detector. Note that a horizontally or vertically long bounding box is divided into several square boxes with overlaps because we restrict the shape of object areas to a square. After object areas have been detected (typically, 600 to 1000 areas are selected from a page), their EOF features are described ( Fig. 3(a2)). The selected square area is divided into c × c cells. The edges in each cell are quantized into four orientation bins and normalized, and the whole vector is then renormalized. Therefore, the dimension of the EOH vector is 4c 2 . Note that we discard features in which all elements are zero. For manga, the features should be robust against scale changes because we want to find areas of any size that are similar to the input sketch. For example, if a certain character's face is the target, it can be either small or large. To achieve matching across different scales, we simply accept any sizes of patches, but restrict the shape of an area to square. Whatever the patch sizes, the same-dimensional EOH features . Detection rate (DR) given #WIN proposals, which is a standard evaluation metric for evaluating objectness [65], [63], [64]. DR shows the percentage of ground-truth objects covered by proposals, which are generated by each method. An object is considered covered only when the PASCAL overlap criteria is satisfied (intersection over union is more than 0.5 [66]). The area under the curve (AUC), which is a single-value summary of performance for each curve, is shown on the legends. We evaluated methods using the dataset used for the localization task, see details on Section VI-B.
are extracted and used for matching. By describing EOF features of candidate areas, a page is represented by a set of EOH features: where P means the page, x i denotes an EOH feature for the ith window, and N is the number of features extracted from the page. Note that integral images are utilized to enable the fast computing of features in the same manner as in [2].
In the comparative study, we show this simple representation achieves better accuracy than previous sketch-based retrieval methods, and we confirm that EOH-based description gives a good solution to the manga image representation problem.
In summary, given a page, candidate areas are detected by selective search, and EOH features are extracted, then the page is represented as a set of EOH features. This window-based representation is simple and efficient at finding a matching area in the page because a feature implicitly contains its position in the page, which is particularly useful for manga pages, and so this approach effectively solves the retrieval-localization problem.

B. Feature compression by product quantization
Given a set of EOH features, we compress them into binary codes using PQ [3], which is a successful ANN method, as shown in Fig. 3(b). Applying PQ greatly reduces the computational cost of matching and reduces memory usage. After the features are compressed to binary codes, the approximate distances between a query vector and dataset codes can be computed efficiently by simple lookup operations (asymmetric distance computation (ADC) [3]). Therefore, the search can be performed efficiently even for large number of dataset vectors.
We now briefly describe the PQ algorithm. We represent x ∈ R D as a concatenation of M subvectors: where each x m ∈ R D/M . We define a subquantizer q m (x m ) for x m as follows: The subcodebook C m consists of K D/M -dimensional centroids learned by k-means [67] in advance. Therefore, q m (x m ) maps a subvector x m to a code word c m ∈ C m . A product quantizer q(x) is defined as a concatenation of subquantizers: Therefore, an input x is mapped by q(x) to a code word The resultant code word c is encoded by a tuple (i 1 , . . . , i M ) of M subcentroid indices. Because each i m is an integer, i.e., i m ∈ {0, . . . , K − 1}, the code c can be represented by M log 2 K bits. Typically, K is made a power of 2 so that log 2 K is an integer. As in other methods, we set K as 256 in this paper (c m is represented by 8 bit). Note that M , which shows the level of quantization, is set as 8 or 16, which yields the length of the code as 64 and 128 bits, respectively.
We now return to our EOH feature description. Recall the page is represented as P = {x i |i ∈ {1, . . . , N }}. Each feature x i is quantized as q(x i ), and the page is represented as where P P Q is a set of quantized EOH features for a page. Because each q(x i ) is recorded as a tuple of M subcentroid indices, which take 8M bits, P P Q is stored by 8M N bits.

C. Search
Let us describe how to retrieve the nearest PQ-encoded feature from many manga pages (Fig. 3(c)). Suppose there are P manga pages, and the quantized EOH features of the pth page are represented as P p P Q = {q(x p i )|i ∈ {1, . . . , N p }}, where N p means the number of EOH features from the pth page, and p ∈ {1, . . . , P }. Given an EOH feature y from a query sketch, the search engine computes the nearest neighbors using: where d AD (·, ·) measures an approximate Euclidean distance between an uncompressed vector and a compressed PQ code [3]. This can be computed efficiently by lookup operations (ADC [3]). By computing d AD from y to each x p i and selecting the smallest one, p * and i * are computed. This is a simple linear search problem for PQ codes, which can be solved efficiently; e.g., 16 ms for searching one million 64-bit codes. Then we can say that the i * th feature from the p * th page is the nearest to the query sketch. The point here is that the problem is separated into a feature description and an ANN search. Therefore, even if the number of features is very large, we can employ the ANN techniques. In our system, searching from 21,142 pages takes 793 ms (without parallel implementation) or 70 ms (with parallel implementation) on a single computer using a simple PQ linear scan, which is fast enough. If much faster searches are required, we can employ more sophisticated ANN data structures [68], [69].

D. Skipping margins
Although PQ computing is fast, effective preprocessing of the manga pages of the dataset is essential (Fig. 3(d)). A manga page comprises a series of frames and the interframe spaces (margins) are not important. For efficient searching, margin exclusion from retrieval candidates should be performed before extracting features. We label the margins as shown in Fig. 6. First, the lines of the manga page image ( Fig. 6(a)) are thickened by applying an erosion [70] to the white areas ( Fig. 6(b)), thereby filling small gaps between black areas. Next, the white-connected areas are labeled by connectedcomponent labeling [71] as shown in Fig. 6(c), where different colors for the labels have been used for visualization. Finally, areas are selected as margins by finding the most frequent label appearing in the outermost peripheral regions (Fig. 6(d)). Because interframe spaces tend to connect to the outer areas, the method succeeds in most cases.
Let us define the patch area as S(x), and the margins as U (x) (e.g., the colored areas shown in Fig. 6(d)). We extract a feature only if its area ratio U/S is less than a threshold, which we set to 0.1. Eq. (4) is therefore rewritten as Intuitively, this means that if an area belongs to the margin, it is skipped in the feature extraction step. An example of the process is shown in Fig. 7.

IV. QUERY INTERACTION
Querying is a difficult issue for manga retrieval. We call this the query modality problem of manga retrieval. We cannot employ textual or tag data because EOH features do not involve such information. For a natural and intuitive interface, we prefer sketch-based queries. Because manga itself comprise sketches drawn by authors, sketching is compatible with manga.
In addition, we can make use of sketching not only for the initial query, but also for additional interaction with the retrieved results. The queries that can be performed using our framework are summarized as follows: (1) sketch querying, the proposed sketch-based retrieval described above; (2) relevance feedback, which reuses the retrieved results; and (3) query retouch, in which the results of relevance feedback are modified and reused.
Relevance feedback: We propose a simple interaction to reuse retrieved results, which is inspired by the relevance feedback techniques proposed in the information retrieval literature [72]. Users can reuse a retrieved result simply by selecting a region in the retrieved manga page, as shown in Ken Akamatsu  Query retouch: We propose a new methodology for modifying and reusing the results. In query retouch, we can modify either the initial sketch or a query taken from the results of a retrieval (Fig. 9). As the query is changed by adding lines or partial erasure, the results will change immediately. As a result, we can intuitively change the retrieval results in the direction that we want.
According to Mei and colleagues [72], these interactions are classified as "interactive reranking," and are especially useful for the visual search problem because "visual data is particularly suited for interaction, as a user can quickly grasp the vivid visual information and thus judge the relevance at a quick glance." [72].

V. MANGA DATASET
In this section, we introduce a new dataset of manga images, namely the Manga109 dataset for evaluation. The Manga109 dataset consists of 109 manga titles, and is made publicly available for academic research purposes with proper copyright notation. Fig. 10 shows example pages from the Manga109 dataset.
A large-scale dataset of manga images is important and useful for manga research. Although several papers related to manga image processing have been published, fair comparisons among the proposed methods have not been conducted because of the lack of a dataset with which the methods can be evaluated. In preparing a dataset, the most serious and intractable problem is copyright. Because manga is artwork and protected by copyright, it is hard to construct a publicly available dataset. Therefore, researchers have collected their own manga images or used manga images drawn by amateurs. These are not appropriate for manga research because: (1) the number of manga images is small; (2) the artistic quality of the manga images is not always high; and (3) they are not publicly available. The Manga109 dataset, on the other hand, clears these three conditions. It contains 21,142 pages in total, and we can say that it is currently the largest manga image dataset. The quality of the images is high because all titles were drawn by professional manga authors.
As is widely known, well-crafted image datasets have played critical roles in evolving image processing technologies, e.g., the PASCAL VOC datasets [66] for image recognition in the 00s, and ImageNet [73] for recent rapid progress in deep architecture. We hope the Manga109 dataset will contribute to the further development of the manga research domain.
Image collection: All manga titles in the Manga109 dataset have been previously published in manga magazines 3 , i.e., they were written by professional manga creators. The manga titles are in an archive "Manga Library Z" run by J-comi. It has more than 4000 titles, most of which are currently out of print. With the help of J-comi, we chose 109 titles from the archive that cover a wide range of genres and publication years. We obtained permission from the creators to use them for academic research purposes. Thus researchers can use them freely with appropriate citation for research challenges, including not only for retrieval and localization, but also for colorization, data mining from manga, and so on. The manga titles were originally published from the 1970s to the 2010s. The Manga109 dataset covers various kinds of categories, including humor, battle, romantic comedy, animal, science fiction, sports, historical drama, fantasy, love romance, suspense, horror, and four-frame cartoons. Please see the details (titles, author names, and so on) in our project page [74].
Dataset statistics: The dataset consists of 109 manga titles. Each title includes 194 pages on average, with a total of 21,142 pages. The average size of images is 833 × 1179, which is bigger than the image sizes usually used for object recognition and retrieval tasks, e.g., 482 × 415 pixels on average for ILSVRC 2013 4 . This is because manga pages contain multiple frames and thus require higher resolutions.  Relation to other datasets: eBDtheque [57] is a publicly available comic dataset. It consists of 100 comic pages with detailed meta-information such as text annotations. Compared with eBDtheque, our Manga109 dataset contains a much larger number of pages. Manga109 is useful for large-scale experiments, whereas eBDtheque is beneficial for small but detailed evaluations such as object boundary detection.

VI. EXPERIMENTAL RESULTS
In this section, we present three evaluations: (1) a comparative study with previous methods for manga description (Section VI-A); (2) a localization evaluation (Section VI-B); and (3) a large-scale qualitative study (Section VI-C). These three experimental results verify that our system presents solutions to the corresponding manga image description problem, the retrieval-localization problem, and the query modality problem. In the comparative study and the localization evaluation, we used a single-thread implementation for a fair comparison, and employed a parallel implementation for the large-scale study.

A. Comparative study
A comparative study was performed to evaluate how well the proposed framework can represent manga images compared with previous methods such as those introduced in Section II. We compared our proposal with a baseline (BoF with large window SIFT [5]), the state-of-the-art of BoF-based methods (FV [5]), and the state-of-the-art of chamfer-based methods (Compact OCM [4]). All experiments were conducted on a PC with a 2.8 GHz Intel Core i7 CPU and 32 GB RAM, using C++ implementations.
Frame image dataset: For evaluation, we cropped frames from 10 representative manga titles from the Manga109 dataset 5 . There were 8889 cropped frames, and the average size was 372 × 341. We used these frames for retrieval. Note that we used frames instead of pages for this comparison because the features of BoF, FV, and Compact OCM are only comparable within a frame. Although the frame is less complex than the page, retrieval is not easy because the size of frames varies greatly, and the localization problem still exists as shown in Fig. 11(c), where the target (a head of a boy) is small and the frame includes other objects and backgrounds. Target images: To make the comparisons, we chose three kinds of targets: Boy-with-glasses (Fig. 11(c)), Chombo (Fig. 11(f)), and Tatoo (Fig. 11(i)), which are from manga titles Lovehina, Mukoukizu no Chombo, and DollGun, respectively. Boy-with-glasses is an easy example, Chombo is much harder because the face might be either to the right or left, and Tatoo is the most difficult because it is so small compared with the frame. These target images are treated as ground truths.
Query images: To prepare query sketches, we invited 10 participants (seven novices and three skilled artists, such as a member of an art club), and asked them to draw sketches. First, we showed them query images for 20 s. Next, they were asked to draw a sketch for the query. Each participant drew all target objects; therefore, we collected 10 × 3 = 30 queries. Examples of queries are shown in Fig. 11. We used a 21-inch pen display (WACOM DTZ-2100) for drawing.
Results of comparative study: Using the queries, we evaluated each method using standard evaluation protocols in image retrieval: recall@k and mean average precision [75]. Note that the ground-truth target images were labelled manually. All frame images were used for the evaluation, and the images of the different targets were regarded as distractors. The statistics of the frame images are shown in Table I. Fig. 12 shows the results for each target. Note that this task is challenging, and all scores tend to be small. The queries from users are not always similar to the target. On the contrary, some novices even drew queries that were dissimilar to the target, as shown in Fig. 11(d) and Fig. 11(f). Still, Tarou Minamoto

Ryousei Deguchi
(i) Fig. 11. Targets for the comparative study. Left to right: query sketches by novice artists, skilled artists, and ground-truth images. Top to bottom: targets, Boy-with-glasses, Chombo, and Tatoo.
in all cases, the proposed method achieved the best scores. In particular, the proposed method outperformed the other methods for Boy-with-glasses. Note that BoF and FV received almost zero scores for the Tatoo case because they are not good at finding a relatively small instance from an image.
From these experiments, we can say that BoF-based methods do not satisfy the purpose in manga retrieval. Note that we did not apply any approximation steps for a fair comparison. Compact OCM measures an original chamfer distance without an approximation (a sparse projection). We did not compress a feature using PQ in the proposed method.
About quantization: When we applied PQ to the features, the score decreased according to the quantization level, as shown in Fig. 13. There is a clear trade-off between the rate of compression and accuracy. From the result, we accepted M = 16 as a reasonable option; i.e., a feature is divided into 16 parts for PQ compression and encoded to a 16-byte code. Note that, interestingly, there is not a clear relation between accuracy and the number of cells (c 2 ). The feature description becomes finer with a large number of cell divisions, but it does not always achieve higher recall. This indicates that some level of abstraction is required for the sketch retrieval task. We accepted c = 8 for all experiments, i.e., a selected area is divided into 8 × 8 areas for feature description.
Parameter settings and implementation details: We show parameter settings and implementation details used for the evaluation. For BoF, SIFT features are densely extracted where the size of a SIFT patch is 64 × 64 pixels, with a 2 × 2 spatial pyramid, and the number of vectors in the dictionary is set to 1024. The final number of dimension is 4096. For FV, a Gaussian Mixture Model with 256 Gaussians was used, with a 2 × 2 spatial pyramid. The dimensions of SIFT are reduced from 128 to 80 by PCA. For BoF and FV, we leveraged the same parameter settings as in Schneider and colleagues [5], with the vlfeat implementation [76]. For selective search, we employed the dlib implementation [77], with little Gaussian blurring before applying selective search.
To train code words for BoF, FV, and PQ, we randomly selected 500 images from the dataset. Note that they were excluded and not used for testing. To eliminate small patches, we set a minimum length of a patch as 100 pixels and discarded patches that were smaller than that.

B. Localization evaluation
Next, we evaluated how well the proposed method can localize a target object in manga pages. The setup is similar to that for image detection evaluation [66].
Images: As query sketches, we used the Boy-with-glasses sketches collected in Section VI-A. The ground-truth windows were manually annotated from Lovehina. A total of 69 windows was annotated. For evaluation, we prepared two datasets. (i) A Lovehina dataset, which is a title of Lovehina vol.1, and consists of 192 pages, including the pages containing ground-truth windows. (ii) The Manga109 dataset, which is the sum of all manga data, consists of 109 titles with a total of 21,142 pages. Note that the Lovehina data is included in the Manga109 dataset, so (i) is a subset of (ii).
In contrast to the previous comparative study, localization is performed on a page. Therefore, this is an object localization task: given a query image, find a target instance in an image. In our case, however, we must find the target from many manga pages (21,142 pages, for Manga109).
Evaluation criteria For evaluation, we employed a standard PASCAL overlap criterion [66]. Given a bounding box (retrieved result) from the method, it is judged to be true or false by measuring the overlap of the bounding box and groundtruth windows. Denote the predicted bounding box as B p , and the ground-truth bounding box as B gt , the overlap is measured by:  We judged the retrieved area is true if r > 0.5. If multiple bounding boxes are produced, at most one among them is counted as correct.
For each query, we find the top 100 areas using the proposed retrieval method from the dataset (Lovehina or Manga109), then the retrieved areas are judged using Eq. (7). Then we can compute the standard mAP@100 from the result (true/positive sequence).
Result of localization evaluation: We show the results in Table II. With our single implementation, searching the Manga109 dataset (14M patches) took 331 ms. This is fast enough, and was further improved (70 ms) using a parallel implementation as discussed in Section VI-C. We also show theoretical values of memory consumption for EOH features (#path×8M ). The whole Manga109 dataset consumes only 204 MB. As can be seen from mAP, this task is difficult. There are possibly hundreds of thousands of candidate areas in the windows (138K for Lovehina, and 14M for Manga109), but only 69 ground-truth areas. Examples of retrieved results are shown in Fig. 14. For the Lovehina data, the first result is a failure but the second is correct. For the Manga109 dataset, the first success can be found at the 35th result. The first result shares similar characteristics to the query (wearing glasses) even though the result is incorrect.

C. Large-scale qualitative study
In this section, we show a qualitative study of retrieval from the Manga109 dataset. The whole system was implemented using a GUI as shown in Fig. 2.
We employed a parallel implementation using the Intel Thread Building Library, and the average computation time was 70 ms for the Manga109 dataset (21,142 images). The parallelization was straightforward. Neighbors are computed for each manga title in parallel. In the implementation, we selected the most similar feature from a page (not keeping all features per page), then merged the results.
Qualitative study using a sketch dataset: We qualitatively evaluated the proposed method using a public sketch dataset as queries. We used representative sketches [39] as queries. The 347 sketches each had a category name, e.g., "panda." Fig. 15(a) and Fig. 15(b) show successful examples. We could retrieve objects from the Manga109 dataset successfully. In particular, the retrieval works well if the target consists of simple geometric shapes such as squares, as shown in Fig. 15(b). This tendency is the same as that for previous sketch-based image retrieval systems [6], [4]. Fig. 15(c) shows a failure example, although the retrieved glass is similar to the query.
As can be seen in Fig. 15(c), text regions are sometimes retrieved and placed at the top of the ranking. Because users usually do not require such results, detecting and eliminating text areas would improve the results, which remains as a future work.
More results by relevance feedback: We show more results from queries of character faces using the proposed relevance feedback in Fig. 16. We see that the top retrieved results were the same as (or similar to) the characters in the query. In this case, all the results were drawn by the same author. Interestingly, our simple edge histogram feature captured the characteristic of authors. Fig. 16(b) shows the results of "blush face." In Japanese manga, such blush faces are represented by hatching. By the relevance feedback, blushed characters were retrieved from various kinds of manga titles. These character-based retrievals are made possible by contentbased search. This suggests that the proposed query interactions are beneficial for manga search.

VII. CONCLUSION
We proposed a sketch-based manga retrieval system and novel query schemes. The retrieval system consists of three steps: labeling of margin areas, EOH feature description, and approximate nearest-neighbor search using product quantization. The query schemes include relevance feedback and query retouch, both of which are new schemes that interactively rerank the retrieved results. We built a new dataset of manga images, Manga109, which consists of 21,142 manga images drawn by professional manga artists. To the best of our knowledge, Manga109 is currently the biggest manga image dataset. It is available to the research community. We conducted a comparative study, localization evaluation, and a large-scale qualitative study. The experiments verified that: (1) the retrieval accuracy of the proposed method is higher than those of existing methods; (2) the proposed method can localize an object instance with reasonable runtime and accuracy; and (3) sketch querying is useful for manga search.
Combining the sketch-and keyword-based searches is a Yuki Kiriga