Method, system, and computer program product for efficient content-based time series retrieval
By using residual networks to process the feature vectors of time series, generating and analyzing pairwise distance matrices, and utilizing an improved template to learn the residual network 2D (RN2Dw/T) model, the inefficiency of existing CTSR systems is solved, achieving efficient time series similarity calculation and information recovery.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- VISA INTERNATIONAL SERVICE ASSOCIATION
- Filing Date
- 2024-05-31
- Publication Date
- 2026-04-24
AI Technical Summary
Existing content-based time series retrieval systems are inefficient when processing multi-domain time series data and struggle to efficiently calculate similarity scores during real-time user interaction.
The feature vectors of time series are processed using residual networks. By calculating the pairwise distance matrix between the known and unknown time series and the learned template, tensors are generated and features are extracted. An improved template learning residual network 2D (RN2Dw/T) model is used for efficient feature extraction and similarity analysis.
It achieves efficient similarity calculation during real-time user interaction, with an average query time of less than 0.04 seconds, improving the efficiency of the CTSR system and effectively recovering information from unknown time series.
Smart Images

Figure CN120112902B_ABST
Abstract
Description
[0001] Cross-referencing related applications
[0002] This application claims the benefit of U.S. Provisional Application No. 63 / 505,570, filed June 1, 2023, the disclosure of which is incorporated herein by reference in its entirety. Technical Field
[0003] This disclosure generally relates to time series data, and in some non-limiting embodiments or aspects, to methods, systems, and computer program products for efficient content-based time series retrieval. Background Technology
[0004] Content-based Time Series Retrieval (CTSR) systems are information retrieval systems that allow users to interact with time series data from multiple domains, such as finance, healthcare, and manufacturing. For example, a user seeking further information about the origin of a time series can submit the time series as a query to the CTSR system and retrieve a list of related time series with associated metadata. By analyzing the retrieved metadata, the user can gather more information about the time series' origin. Because CTSR systems can handle time series data from different domains, they can use high-capacity models to efficiently measure the similarity between different time series. Furthermore, when users interact with the system in real time, they may require models within the CTSR system to efficiently calculate similarity scores. Summary of the Invention
[0005] Therefore, improved methods, systems, and computer program products for content-based time series retrieval are provided.
[0006] According to some non-limiting embodiments or aspects, a method is provided, comprising: obtaining a plurality of known time series from a database using at least one processor; for each of the plurality of known time series: calculating a pairwise distance matrix between the known time series and each of a plurality of learned templates using the at least one processor to generate a plurality of pairwise distance matrices; stacking the plurality of pairwise distance matrices together using the at least one processor to generate a tensor; processing the tensor with a residual network using the at least one processor, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and providing the feature vector of each of the plurality of known time series using the at least one processor.
[0007] In some non-limiting embodiments or aspects, the method further includes: using the at least one processor to store the feature vector of each of the plurality of known time series in the at least one database.
[0008] In some non-limiting embodiments or aspects, the method further includes: obtaining an unknown time series using the at least one processor; calculating pairwise distance matrices between the unknown time series and each of the plurality of learned templates using the at least one processor to generate a plurality of additional pairwise distance matrices; stacking the plurality of additional pairwise distance matrices together using the at least one processor to generate another tensor; processing the other tensor with the residual network using the at least one processor, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determining the distance between the known time series and the unknown time series using the at least one processor based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identifying at least one known time series similar to the unknown time series using the at least one processor based on the distance between each known time series and the unknown time series.
[0009] In some non-limiting embodiments or aspects, the residual network is trained using a loss function defined according to the following equation:
[0010]
[0011] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0012] In some non-limiting embodiments or aspects, the plurality of known time series includes a plurality of known transaction time series associated with a plurality of merchants, wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0013] In some non-limiting embodiments or aspects, the plurality of learned templates includes thirty-two learned templates, the plurality of pairwise distance matrices includes thirty-two pairwise distance matrices, the tensor includes thirty-two input dimensions, and the feature vector of each of the plurality of known time series includes a vector of size sixty-four.
[0014] In some non-limiting embodiments or aspects, the residual network includes a two-dimensional residual network.
[0015] According to some non-limiting embodiments or aspects, a system is provided, comprising: at least one processor coupled to a memory and configured to: obtain a plurality of known time series from at least one database; for each of the plurality of known time series: compute pairwise distance matrices between the known time series and each of a plurality of learned templates to generate a plurality of pairwise distance matrices; stack the plurality of pairwise distance matrices together to generate a tensor; process the tensor with a residual network, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and provide the feature vector of each of the plurality of known time series.
[0016] In some non-limiting embodiments or aspects, the at least one processor is further configured to store the feature vector of each of the plurality of known time series in the at least one database.
[0017] In some non-limiting embodiments or aspects, the at least one processor is further configured to: obtain an unknown time series; calculate pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; stack the plurality of additional pairwise distance matrices together to generate another tensor; process the other tensor with the residual network, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determine the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identify at least one known time series that is similar to the unknown time series based on the distance between each known time series and the unknown time series.
[0018] In some non-limiting embodiments or aspects, the residual network is trained using a loss function defined according to the following equation:
[0019]
[0020] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0021] In some non-limiting embodiments or aspects, the plurality of known time series includes a plurality of known transaction time series associated with a plurality of merchants, wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0022] In some non-limiting embodiments or aspects, the plurality of learned templates includes thirty-two learned templates, the plurality of pairwise distance matrices includes thirty-two pairwise distance matrices, the tensor includes thirty-two input dimensions, and the feature vector of each of the plurality of known time series includes a vector of size sixty-four.
[0023] In some non-limiting embodiments or aspects, the residual network includes a two-dimensional residual network.
[0024] According to some non-limiting embodiments or aspects, a computer program product is provided, comprising a non-transient computer-readable medium including program instructions that, when executed by at least one processor, cause the at least one processor to: obtain a plurality of known time series from at least one database; for each of the plurality of known time series: compute pairwise distance matrices between the known time series and each of a plurality of learned templates to generate a plurality of pairwise distance matrices; stack the plurality of pairwise distance matrices together to generate a tensor; process the tensor with a residual network, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and provide the feature vector of each of the plurality of known time series.
[0025] In some non-limiting embodiments or aspects, the program instructions, when executed by the at least one processor, further cause the at least one processor to: store the feature vector of each of the plurality of known time series in the at least one database.
[0026] In some non-limiting embodiments or aspects, the program instructions, when executed by the at least one processor, further cause the at least one processor to: obtain an unknown time series; calculate pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; stack the plurality of additional pairwise distance matrices together to generate another tensor; process the other tensor with the residual network, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determine the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identify at least one known time series identified as similar to the unknown time series based on the distance between each known time series and the unknown time series.
[0027] In some non-limiting embodiments or aspects, the residual network is trained using a loss function defined according to the following equation:
[0028]
[0029] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0030] In some non-limiting embodiments or aspects, the plurality of known time series includes a plurality of known transaction time series associated with a plurality of merchants, wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0031] In some non-limiting embodiments or aspects, the plurality of learned templates includes thirty-two learned templates, the plurality of pairwise distance matrices includes thirty-two pairwise distance matrices, the tensor includes thirty-two input dimensions, and the feature vector of each of the plurality of known time series includes a vector of size sixty-four, and the residual network includes a two-dimensional residual network.
[0032] Other non-restrictive embodiments or aspects are described in the following numbered items:
[0033] Clause 1: A method comprising: obtaining a plurality of known time series from a plurality of databases using at least one processor; for each of the plurality of known time series: calculating a pairwise distance matrix between the known time series and each of a plurality of learned templates using the at least one processor to generate a plurality of pairwise distance matrices; stacking the plurality of pairwise distance matrices together using the at least one processor to generate a tensor; processing the tensor with a residual network using the at least one processor, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and providing the feature vector of each of the plurality of known time series using the at least one processor.
[0034] Clause 2: The method according to Clause 1 further includes: using the at least one processor to store the feature vector of each of the plurality of known time series in the at least one database.
[0035] Clause 3: The method according to Clause 1 or 2 further comprises: obtaining an unknown time series using the at least one processor; calculating a pairwise distance matrix between the unknown time series and each of the plurality of learned templates using the at least one processor to generate a plurality of additional pairwise distance matrices; stacking the plurality of additional pairwise distance matrices together using the at least one processor to generate another tensor; processing the other tensor with the residual network using the at least one processor, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determining a distance between the known time series and the unknown time series using the at least one processor based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identifying at least one known time series similar to the unknown time series using the at least one processor based on the distance between each known time series and the unknown time series.
[0036] Clause 4: The method according to any one of Clauses 1 to 3, wherein the residual network is trained using a loss function defined according to the following equation:
[0037]
[0038] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0039] Clause 5: The method according to any one of Clauses 1 to 4, wherein the plurality of known time series includes a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0040] Clause 6: The method according to any one of Clauses 1 to 5, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the tensor comprises thirty-two input dimensions, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four.
[0041] Clause 7: The method according to any one of Clauses 1 to 6, wherein the residual network comprises a two-dimensional residual network.
[0042] Clause 8: A system comprising: at least one processor coupled to a memory and configured to: obtain a plurality of known time series from at least one database; for each of the plurality of known time series: compute pairwise distance matrices between the known time series and each of a plurality of learned templates to generate a plurality of pairwise distance matrices; stack the plurality of pairwise distance matrices together to generate a tensor; process the tensor with a residual network, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and provide the feature vector of each of the plurality of known time series.
[0043] Clause 9: The system according to Clause 8, wherein the at least one processor is further configured to store the feature vector of each of the plurality of known time series in the at least one database.
[0044] Clause 10: The system according to Clause 8 or 9, wherein the at least one processor is further configured to: obtain an unknown time series; compute pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; stack the plurality of additional pairwise distance matrices together to generate another tensor; process the other tensor with the residual network, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determine the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identify at least one known time series identified as similar to the unknown time series based on the distance between each known time series and the unknown time series.
[0045] Clause 11: A system according to any one of Clauses 8 to 10, wherein the residual network is trained using a loss function defined according to the following equation:
[0046]
[0047] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0048] Clause 12: A system according to any one of Clauses 8 to 11, wherein the plurality of known time series comprises a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0049] Clause 13: The system according to any one of Clauses 8 to 12, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the tensor comprises thirty-two input dimensions, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four.
[0050] Clause 14: The system according to any one of Clauses 8 to 13, wherein the residual network comprises a two-dimensional residual network.
[0051] Clause 15: A computer program product comprising a non-transient computer-readable medium, the non-transient computer-readable medium comprising program instructions that, when executed by at least one processor, cause the at least one processor to: obtain a plurality of known time series from at least one database; for each of the plurality of known time series: compute pairwise distance matrices between the known time series and each of a plurality of learned templates to generate a plurality of pairwise distance matrices; stack the plurality of pairwise distance matrices together to generate a tensor; process the tensor with a residual network, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and provide the feature vector of each of the plurality of known time series.
[0052] Clause 16: The computer program product according to Clause 15, wherein the program instructions, when executed by the at least one processor, further cause the at least one processor to: store the feature vector of each of the plurality of known time series in the at least one database.
[0053] Clause 17: A computer program product according to Clause 15 or 16, wherein the program instructions, when executed by the at least one processor, further cause the at least one processor to: obtain an unknown time series; compute pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; stack the plurality of additional pairwise distance matrices together to generate another tensor; process the other tensor with the residual network, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each of the plurality of known time series stored in the database, determine the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identify at least one known time series identified as similar to the unknown time series based on the distance between each known time series and the unknown time series.
[0054] Clause 18: A computer program product according to any one of Clauses 15 to 17, wherein the residual network is trained using a loss function defined according to the following equation:
[0055]
[0056] in For training data batches , The batch size is defined as follows: each sample in the batch contains a query time series. Positive time series and negative time series tuple , It is an sigmoid function, and This refers to the residual network.
[0057] Clause 19: A computer program product according to any one of Clauses 15 to 18, wherein the plurality of known time series comprises a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
[0058] Clause 20: A computer program product according to any one of Clauses 15 to 19, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the tensor comprises thirty-two input dimensions, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four, and wherein the residual network comprises a two-dimensional residual network.
[0059] These and other features and characteristics of this disclosure, as well as the operational methods and manufacturing economies of combinations of related structural elements and parts, will become more apparent when considered in conjunction with the accompanying drawings, all of which form part of this specification, wherein similar reference numerals denote corresponding parts in the figures. However, it should be clearly understood that the drawings are for illustrative and descriptive purposes only and are not intended to be a definition of limitation on the disclosed subject matter. Attached Figure Description
[0060] Additional advantages and details are explained in more detail below with reference to the non-limiting exemplary embodiments shown in the illustrative accompanying drawings, in which:
[0061] Figure 1 This is a schematic diagram of an electronic payment processing network based on some non-restrictive implementation schemes or aspects;
[0062] Figure 2 It is based on some non-restrictive implementation schemes or aspects Figure 1 A schematic diagram of example components of one or more devices;
[0063] Figure 3A and Figure 3BThis is a flowchart of a method for efficient content-based time-series retrieval, according to some non-limiting embodiments or aspects;
[0064] Figure 4 This demonstrates an electronic payment network use case that includes content-based time series retrieval (CTSR) and a database containing transaction time series.
[0065] Figure 5 This illustrates CTSR and multi-domain use cases, including databases containing time series data from multiple domains.
[0066] Figure 6 Examples of feature extractors and distance functions are shown;
[0067] Figure 7 An algorithm for calculating the dynamic time warp (DTW) distance is shown;
[0068] Figure 8 It is a building block and network graph of a residual network 2D (RN2D) model based on some non-limiting embodiments or aspects;
[0069] Figure 9 It is a network diagram of a residual network 2DRN2Dw / T with a template learning model according to some non-limiting embodiments or aspects;
[0070] Figure 10 It is a performance measurement table for the experiment;
[0071] Figure 11 This is a critical difference (CD) plot comparing experimental performance;
[0072] Figure 12 It is a graph showing the performance measurement results of the experiment;
[0073] Figure 13 The time series of the first eight samples taken in the experiment are shown;
[0074] Figure 14 This is a table of further performance measurements of the experiment;
[0075] Figure 15 This is a CD plot showing the further performance of the comparative experiment;
[0076] Figure 16 It is a graph showing the results of other performance measurements of the experiment; and
[0077] Figure 17 This is the timeline for querying the experiment. Detailed Implementation
[0078] For the purposes of the following description, the terms “end,” “upper,” “lower,” “right,” “left,” “vertical,” “horizontal,” “top,” “bottom,” “lateral,” “longitudinal,” and their derivatives should be associated with the orientation of the embodiments in the accompanying drawings. However, it should be understood that this disclosure may employ various alternative variations and sequences of steps, except where explicitly specified otherwise. It should also be understood that the specific devices and processes shown in the accompanying drawings and described in the following specification are merely exemplary and non-limiting embodiments or aspects of the disclosed subject matter. Therefore, specific dimensions and other physical characteristics relating to the embodiments or aspects disclosed herein should not be considered limiting.
[0079] This document may describe some non-limiting embodiments or aspects in conjunction with thresholds. As used herein, satisfying a threshold may refer to a value greater than a threshold, more than a threshold, higher than a threshold, greater than or equal to a threshold, less than a threshold, less than a threshold, lower than a threshold, less than or equal to a threshold, equal to a threshold, etc.
[0080] The aspects, components, elements, structures, actions, steps, functions, instructions, and / or their analogues used herein should not be construed as critical or essential unless explicitly stated otherwise. Furthermore, as used herein, the article “a” is intended to include one or more items and is interchangeable with “one or more” and “at least one.” Additionally, as used herein, the term “set” is intended to include one or more items (e.g., related items, unrelated items, combinations of related and unrelated items, etc.) and is interchangeable with “one or more” or “at least one.” Where only one item is desired, the term “a” or similar language is used. Moreover, as used herein, the term “having” and / or its analogues are intended to be open-ended terms. Additionally, unless explicitly stated otherwise, the phrase “based on” is intended to mean “at least partially based on.” Furthermore, a reference to an action “based on” a condition may mean that the action is “in response to” that condition. For example, in some non-limiting embodiments or aspects, the phrases “based on” and “in response to” may refer to conditions that automatically trigger an action (e.g., specific operations of electronic devices such as computing devices, processors, etc.).
[0081] As used herein, the term "communication" can refer to the receiving, accepting, sending, transmitting, or providing of data (e.g., information, signals, messages, instructions, commands, etc.). For one unit (e.g., apparatus, system, component of an apparatus or system, combination thereof, etc.) to communicate with another unit means that the first unit is able to receive information from and / or transmit information to the other unit, directly or indirectly. This can refer to a direct or indirect connection that is inherently wired and / or wireless (e.g., a direct communication connection, an indirect communication connection, and / or the like). Furthermore, the two units can communicate with each other even though the transmitted information may be modified, processed, relayed, and / or routed between them. For example, the first unit can communicate with the second unit even if it passively receives information and does not actively send information to the second unit. As another example, the first unit can communicate with the second unit if at least one intermediate unit processes information received from the first unit and transmits the processed information to the second unit. In some non-limiting embodiments or aspects, a message can refer to a network packet (e.g., a data packet and / or the like) that includes data. It should be understood that there may be many other arrangements.
[0082] As used herein, the term "computing device" can refer to one or more electronic devices configured to process data. In some examples, a computing device may include essential components for receiving, processing, and outputting data, such as a processor, display, memory, input device, network interface, and / or the like. A computing device may be a mobile device. As examples, a mobile device may include a cellular phone (e.g., a smartphone or standard cellular phone), a portable computer, a wearable device (e.g., a watch, glasses, lenses, clothing, and / or the like), a personal digital assistant (PDA), and / or other similar devices. A computing device may also be a desktop computer or other form of non-mobile computer.
[0083] As used herein, the term "server" may refer to or include one or more computing devices operated by or facilitating communication and processing by multiple parties in a network environment such as the Internet, but it should be understood that communication may be facilitated through one or more public or private network environments, and various other arrangements may be possible. Furthermore, multiple computing devices (e.g., servers, point-of-sale (POS) devices, mobile devices, etc.) communicating directly or indirectly in a network environment may constitute a "system".
[0084] As used herein, the term "system" may refer to one or more computing devices or a combination of computing devices (e.g., processors, servers, client devices, software applications, components of such devices, and / or their likenesses). As used herein, references to "device," "server," "processor," and / or their likenesses may refer to a previously described device, server, or processor, a different device, server, or processor, and / or a combination of devices, servers, and / or processors, described as performing a preceding step or function. For example, as used in the specification and claims, a first device, first server, or first processor described as performing a first step or a first function may refer to the same or different device, server, or processor described as performing a second step or a second function.
[0085] As used herein, the term "real-time" refers to performing one or more tasks during or before another process is completed. For example, real-time inference could be inference obtained from a model before a payment transaction is authorized, completed, etc.
[0086] Time series data is a common data type used in various application analyses. For example, engineers can examine time series from different sensors on manufacturing machines to identify ways to improve factory efficiency, doctors can study various biometric time series for medical research, and multiple time series streams from operational payment networks can be monitored to detect anomalous activity. With the availability of vast amounts of time series data from various sources, there is a need for effective content-based time series retrieval (CTSR) systems to help users navigate time series databases.
[0087] Figure 4 This illustrates the use case of CTSR and an electronic payment network that includes a database of transaction time series. To understand what a CTSR system is and how it can help users, consider... Figure 4 The example shown is an electronic payment network use case. Here, one of the merchants using the electronic payment network failed to provide accurate business type information. When a merchant uses an electronic payment network, the payment processing company obtains a time-series identification signature of the merchant. Investigators from the company can then use a CTSR system with time-series identification signatures from various merchants to identify the correct business type of the relevant merchant. The CTSR system helps investigators correct the information in a timely manner.
[0088] exist Figure 4 In the examples shown above, the CTSR system only includes transaction time series. However, it is also possible to construct CTSR systems with time series from various domains, such as... Figure 5The diagram illustrates a multi-domain use case for CTSR and a database containing time series from multiple domains. Suppose a user encounters a time series without any associated metadata. The time series could be a power consumption time series or data records from other sensors. The user might want to identify the possible source of the time series and recover lost information. To solve this problem, the user can query the CTSR system that has the time series (which may or may not exist in the CTSR system's database), and the system can return a sorted list of similar time series with associated metadata. In this example, five of the first six returned time series are power consumption identification markers for microwave ovens. Therefore, the user can infer that the unknown time series is most likely a power consumption identification marker for a microwave oven. Thus, the CTSR system can help the user recover lost information about the time series.
[0089] Design goals when building a CTSR system may include: 1) effectively capturing various concepts from time series from different domains, and 2) maintaining efficiency during inference while the user interacts with the system in real time. Differences in inference time between CTSR systems may be due to differences in the role of neural network models. Figure 6 Examples of feature extractors and distance functions are shown. In faster methods, the neural network acts only as a feature extractor, and the Euclidean distance function is used to calculate the distance, such as... Figure 6 As illustrated in example (a). Therefore, before inference, a neural network can be used to project each time series in the database only once into the Euclidean space. During the query period, the neural network model may only need to project the query time series into the same Euclidean space, and distance calculation can be performed efficiently in this space. On the other hand, existing Residual Network 2D (RN2D) models act as both feature extractors and distance functions, such as Figure 6 As shown in example (b), the RN2D model is called each time distance is calculated. With time series data in the database, the faster method only requires calling the neural network model once for the query. In contrast, the RN2D model is called multiple times, which significantly increases runtime.
[0090] Non-limiting embodiments or aspects of this disclosure provide methods, systems, and computer program products for content-based time series retrieval, which perform the following operations: obtaining a plurality of known time series from at least one database; for each of the plurality of known time series: calculating pairwise distance matrices between the known time series and each of the plurality of learned templates to generate a plurality of pairwise distance matrices; stacking the plurality of pairwise distance matrices together to generate a tensor; processing the tensor with a residual network, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output; and providing a feature vector of each of the plurality of known time series. Therefore, non-limiting embodiments or aspects of this disclosure provide methods, systems, and computer program products for content-based time series retrieval, which perform the following operations: obtaining an unknown time series; calculating pairwise distance matrices between the unknown time series and each of a plurality of learned templates to generate a plurality of additional pairwise distance matrices; stacking the additional pairwise distance matrices together to generate another tensor; processing the other tensor with a residual network, wherein the residual network receives the other tensor as input and provides a feature vector of the unknown time series as output; for each known time series stored in a database, determining the Euclidean distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series; and identifying at least one known time series corresponding to the unknown time series based on the Euclidean distance between each known time series and the unknown time series.
[0091] In this way, non-limiting embodiments or aspects of this disclosure can provide improved model architectures based on RND2D models with improved efficiency, which may herein be referred to as Residual Network 2D with Template Learning (RN2Dw / T). Figure 6 As shown in example (c), according to the non-limiting embodiment or aspect of the RN2Dw / T model, a template (landmark) learning mechanism can be incorporated into the input of the RN2D model ( Figure 6 In example (b) shown), the model is modified to output feature vectors instead of distance values. The RN2Dw / T model according to a non-limiting embodiment or aspect can use learned landmarks as references to generate feature vectors for the input time series. Unlike the Residual Network 2D (RN2D) method introduced below, the RN2Dw / T model according to a non-limiting embodiment or aspect can simply act as a feature extractor. Non-limiting embodiments or aspects of the RN2Dw / T model can achieve efficiency comparable to the RN2D method while achieving an average query time of less than 0.04 seconds (see, for example, Figure 10(See the table in the table). Therefore, the non-limiting embodiments or aspects of this disclosure can realize an effective and efficient CTSR system, which can be a valuable tool for businesses in various industries.
[0092] For reference Figure 1 , Figure 1 An electronic payment processing network 100 is illustrated according to a non-limiting embodiment or aspect. This payment processing network can be used in conjunction with the systems and methods described herein. It should be understood that the specific arrangement of the illustrated electronic payment processing network 100 is for illustrative purposes only, and various arrangements are possible. A transaction processing system 101 (e.g., a transaction processor) is shown communicating with one or more issuing systems (e.g., such as issuing system 106) and one or more acquiring systems (e.g., such as acquiring system 108). Although only a single issuing system 106 and a single acquiring system 108 are shown, it should be understood that the transaction processing system 101 may communicate with multiple issuing systems and / or acquiring systems. In some embodiments, the transaction processing system 101 may also operate as an issuing system, such that both the transaction processing system 101 and the issuing system 106 are single systems and / or controlled by a single entity.
[0093] In some non-limiting embodiments or aspects, transaction processing system 101 may communicate directly with merchant system 104 via a public or private network connection. Alternatively, transaction processing system 101 may communicate with merchant system 104 via payment gateway 102 and / or acquiring system 108. In some non-limiting embodiments or aspects, acquiring system 108 associated with merchant system 104 may operate as payment gateway 102 to facilitate the transmission of transaction requests from merchant system 104 to transaction processing system 101. Merchant system 104 may communicate with payment gateway 102 via a public or private network connection. For example, merchant system 104, including a physical POS device, may communicate with payment gateway 102 via a public or private network for card transactions. As another example, merchant system 104, including a server (e.g., a web server), may communicate with payment gateway 102 via a public or private network, such as a public internet connection, for cardless transactions.
[0094] In some non-limiting embodiments or aspects, after receiving a transaction request from merchant system 104 that identifies an account identifier associated with the payer (e.g., an account holder) of the issued consumer device 110, transaction processing system 101 may generate an authorization request message to be transmitted to issuer system 106, which issued the consumer device 110 and / or the account identifier. Issuer system 106 may then approve or reject the authorization request and, based on the approval or rejection, generate an authorization response message transmitted to transaction processing system 101. Transaction processing system 101 may transmit the approval or rejection to merchant system 104. When issuer system 106 approves the authorization request message, it may then clear and settle the payment transaction between issuer system 106 and acquiring system 108.
[0095] Figure 1 The number and arrangement of systems and / or equipment shown are provided as examples. Figure 1 Compared to the systems and / or devices shown, there may be additional systems and / or devices, fewer systems and / or devices, different systems and / or devices, and / or systems and / or devices arranged in a different manner. Furthermore, implementation may be within a single system and / or device. Figure 1 Two or more systems or devices shown in the document, or Figure 1 The single system or device shown may be implemented as multiple distributed systems or devices. Alternatively, a group of systems (e.g., one or more systems) and / or a group of devices (e.g., one or more devices) of the electronic payment processing network 100 may perform one or more functions described as being performed by another group of systems or another group of devices of the electronic payment processing network 100.
[0096] For reference Figure 2 The diagram illustrates example components of device 200 according to a non-limiting embodiment. As an example, device 200 may correspond to transaction processing system 101, payment gateway 102, merchant system 104, issuer system 106, acquirer system 108, and / or consumer device 110. In some non-limiting embodiments, such a system or device may include at least one device 200 and / or at least one component of device 200. The number and arrangement of components shown are provided as examples. In some non-limiting embodiments, device 200 may include additional components, fewer components, different components, or components arranged differently compared to those shown. Additionally or alternatively, a set of components (e.g., one or more components) of device 200 may perform one or more functions described as being performed by another set of components of device 200.
[0097] like Figure 2As shown, device 200 may include bus 202, processor 204, memory 206, storage unit 208, input unit 210, output unit 212, and communication interface 214. Bus 202 may include components that allow communication between components of device 200. In some non-limiting embodiments, processor 204 may be implemented in hardware, firmware, or a combination of hardware and software. For example, processor 204 may include a processor (e.g., a central processing unit (CPU), graphics processing unit (GPU), accelerated processing unit (APU), etc.), microprocessor, digital signal processor (DSP), and / or any processing unit that can be programmed to perform functions (e.g., field-programmable gate array (FPGA), application-specific integrated circuit (ASIC), etc.). Memory 206 may include random access memory (RAM), read-only memory (ROM), and / or another type of dynamic or static storage device (e.g., flash memory, magnetic memory, optical memory, etc.) that stores information and / or instructions for use by processor 204.
[0098] Continue to refer to Figure 2 Storage component 208 may store information and / or software related to the operation and use of device 200. For example, storage component 208 may include a hard disk (e.g., magnetic disk, optical disk, magneto-optical disk, solid-state disk, etc.) and / or another type of computer-readable medium. Input component 210 may include components that allow device 200 to receive information, such as via user input (e.g., touch screen display, keyboard, keypad, mouse, buttons, switches, microphone, etc.). Alternatively or additionally, input component 210 may include sensors for sensing information (e.g., Global Positioning System (GPS) components, accelerometers, gyroscopes, actuators, etc.). Output component 212 may include components that provide output information from device 200 (e.g., display, speaker, one or more light-emitting diodes (LEDs), etc.). Communication interface 214 may include transceiver components (e.g., transceivers, separate receivers and transmitters, etc.) that enable device 200 to communicate with other devices, for example, via wired connections, wireless connections, or a combination of wired and wireless connections. Communication interface 214 allows device 200 to receive information from another device and / or provide information to another device. For example, communication interface 214 may include an Ethernet interface, an optical interface, a coaxial interface, an infrared interface, a radio frequency (RF) interface, a universal serial bus (USB) interface, a Wi-Fi® interface, a cellular network interface, etc.
[0099] Device 200 can perform one or more processes described herein. Device 200 can perform these processes based on processor 204 executing software instructions stored in a computer-readable medium, such as memory 206 and / or storage unit 208. The computer-readable medium may include any non-transient memory device. Memory devices include memory space located within a single physical storage device or memory space extended across multiple physical storage devices. Software instructions may be read into memory 206 and / or storage unit 208 via communication interface 214 from another computer-readable medium or from another device. When executed, the software instructions stored in memory 206 and / or storage unit 208 may cause processor 204 to perform one or more processes described herein. Additionally or alternatively, hard-wired circuitry may be used in place of or in conjunction with the software instructions to perform one or more processes described herein. Therefore, the embodiments described herein are not limited to any particular combination of hardware circuitry and software. As used herein, the term “configured to” may refer to an arrangement of software, devices, and / or hardware for performing and / or implementing one or more functions (e.g., actions, processes, steps of processes, and / or the like). For example, "a processor configured to..." can refer to a processor that executes software instructions (such as program code) that cause the processor to perform one or more functions.
[0100] The following conventions may be used for annotations in this document: lowercase letters (e.g., x) represent scalars, bold lowercase letters (e.g., x) represent vectors, uppercase letters (e.g., X) represent matrices, bold uppercase letters (e.g., X) represent tensors, and calligraphic letters (e.g., ...) represent tensors. () can represent a set.
[0101] Content-based time series retrieval (CTSR) can be formulated as follows: Given a set of time series... = [x1,···,x n Given any query time series q, obtain the relevance score function (·,·), which satisfies if x i Compared to x j If it is more relevant to q, then f (x i ,q)> f (x j The properties of ,q). The scoring function can be a predefined similarity / distance function, or it can use the properties of ,q). A trainable function that optimizes the metadata associated with each time series.
[0102] The time series retrieval problem can be formulated in two ways. The first, also known as the time series similarity search problem, aims to find the preceding time series most similar to a given query based on a fixed distance function. Because the distance function is fixed, this type of research focuses on efficiency, accelerating the process through techniques such as lowering the bounds, early rejection, and / or indexing. Comparing this problem to the problem statement above reveals that the technical objectives for solving the time series similarity search problem differ from those for solving the problem statement above.
[0103] The second type of problem statement is more consistent with the problem statements used to solve the above-mentioned problem statements, where the goal is to develop a model or scoring function to help users retrieve relevant time series from a database based on the submitted query time series. However, existing models used to solve this second type of problem statement are designed to solve multivariate time series, which, if applied to the above-mentioned problem statement, would simply be reduced to a standard Long Short-Term Memory (LSTM) network.
[0104] Euclidean distance and dynamic time-warped distance are popular and simple tools for analyzing time series data. They are widely used in various tasks such as similarity search, classification, and anomaly detection, and both distance functions can be easily applied to these problems. Another class of methods applicable to these problems are neural networks, especially those capable of modeling sequential data. For example, Long Short-Term Memory networks, gated recurrent unit networks, transformers, and convolutional neural networks have shown effectiveness in tasks such as time series classification, prediction, and anomaly detection.
[0105] Six existing baseline methods are presented. Then, the previously mentioned RN2D method is introduced, and its benefits are compared with those of the other baseline methods. Following the introduction of the RN2D method, further details are provided regarding a Residual Network 2D (RN2Dw / T) method with template learning according to a non-limiting embodiment or aspect, which addresses the efficiency issues associated with the design of RN2D.
[0106] The six existing baseline methods considered include Euclidean distance (ED), dynamic time warp (DTW), long short-term memory network (LSTM), gated recurrent unit network (GRU), transformer (TF), and residual network 1D (RN1D).
[0107] The Euclidean distance between the query time series and the time series in the set can be calculated. The set can then be classified based on this distance. This is perhaps the simplest method for solving the CTSR problem.
[0108] DTW is similar to the ED baseline, but instead uses the DTW distance. The DTW distance is considered a simple yet effective baseline for time series classification problems.
[0109] LSTM is one of the most popular recurrent neural networks (RNNs) for modeling sequential data. LSTM models can be optimized using Siamese network architectures (see, for example, Figure 4 Example (a)). The Siamese network takes two input time series, and each input is first processed with a 1D convolutional layer to extract local features. The output is then fed into a bidirectional LSTM model to obtain a hidden representation. Next, the hidden representation of the last time step is passed through a linear layer to obtain the final representation of the input time series. The Euclidean distance between the final representations is used to calculate the correlation score between the two inputs.
[0110] GRU is another popular RNN architecture widely used for modeling sequence data. To optimize the GRU model, a similar approach to the LSTM model can be applied, where the LSTM units in the RNN architecture are replaced with GRU units.
[0111] TF is an alternative to RNNs for sequence modeling. To learn hidden representations of input time series, a transformer encoder can be used, proposed by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan NGomez, Lukasz Kaiser, and Illia Polosukhin in their 2017 paper, "Attention is all you need. Advances in neural information processing systems." The RNNs used in the previous two approaches (i.e., LSTM and GRU) can be replaced with transformer encoders, resulting in transformer-based Siamese network architectures instead of RNN-based architectures.
[0112] RN1D is a time series classification model inspired by the success of residual networks in computer vision. RN1D uses 1D convolutional layers instead of 2D convolutional layers. Extensive evaluation has demonstrated that the RN1D design is one of the strongest models for time series classification. The RN1D model can also be optimized in Siamese networks (see, for example, Figure 4 Example (a)).
[0113] Neither the ED nor DTW methods require a training phase because neither method has parameters to optimize. The DTW method is more efficient for time series data than the ED method because it considers all alignments between the input time series. The calculation of the DTW distance can be abstracted into a two-stage process, such as... Figure 7 The diagram illustrates the algorithm used to calculate the DTW distance. In the first stage (lines 2-5), the input time series a = [a1, ..., a...] is processed. w [where w is the length of a] and b = [b1, ..., b] h Calculate the pairwise distance matrix (where h is the length of b). ,because D [ i , j ] = |a i b i |. In the second stage (lines 6 to 8), for D For each element in the list, apply a fixed loop function. D (Right now, D [ i , j ] ← D [ i , j ]+min( D [ i 1, j ], D [ i , j 1], D [ i 1, j Therefore, the DTW method can be viewed as running a predefined function on the pairwise distance matrix between the input time series.
[0114] The other four baseline methods use a Siamese network distance learning framework (see, for example, Figure 4The example (a) uses a high-capacity (e.g., highly expressive) neural network model (i.e., LSTM, GRU, TF, and RN1D) to learn hidden representations of the input time series. These representations are used to compute the distance between two time series, and the model is learned using the optimization procedure described in this paper. Once the model is optimized, the hidden representation of each time series in the database is extracted before deployment. When a user submits a query, the model can be applied only to the query time series to extract its hidden representation, since the hidden representation of each time series in the database may have been extracted before the query time. Euclidean distance can then be used to compute the distance between the query and each item in the database.
[0115] For reference Figure 8 , Figure 8 These are building blocks and network graphs of an RN2D model based on some non-limiting embodiments or aspects. The RN2D model utilizes rich alignment information from pairwise distance matrices, similar to the DTW method. However, instead of using a fixed function, the RN2D model can use a high-capacity neural network as the function, thus employing a representational model similar to four neural network baselines.
[0116] The design of RN2D is driven by a deep residual network used in computer vision. For example... Figure 8 As shown, non-limiting embodiments or aspects of the RN2D model can employ bottleneck building block designs as described in the paper "Deep residual learning for image recognition" entitled "Deep residual learning for image recognition" published by Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun in the Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 770-778, 2016, the entire disclosure of which is incorporated herein by reference in its entirety. Given an input dimension Bottleneck dimension and output dimensions In the case of input tensor You can first project a 1×1 convolutional layer onto... Space. Subsequently, the tensor is passed through a ReLU layer, and then further transformed using a 3×3 convolutional layer with a stride of two. Space. After another ReLU layer, the intermediate representation can be projected onto a 1×1 convolutional layer. Space, where the output of a 1×1 convolutional layer is called X. out Because of X in and X outThe sizes do not match, therefore X in With X out It might not be added directly for skipping connections, and X in It can be added to X out Previously, a 1×1 convolutional layer was used for processing. After adding this layer, the merged representation can be processed using ReLU and exits the building block. If the input is in In space, the output will be In space.
[0117] Still referencing Figure 8 The overall network design of RN2D can also be similar to the network design described in the paper entitled "Deep residual learning for image recognition" published by Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun in the Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 770-778, 2016, the entire contents of which are incorporated herein by reference in full. Given two input time series a = [a1, ..., a...] w ] and b = [b1, ..., b h In the case of [ ], the pairwise distance matrix can be calculated similarly to the DTW method. D's i and the j Location available [ i , j ] = |a i b j |Calculation. Before applying the convolutional layer, the shape of D can be transformed into w × h × 1 by adding an extra dimension. Next, D can be projected onto R using a 7×7 convolutional layer with a stride of 2. w / 2×h / 2×64 Spatial dimension. After the ReLU layer, the intermediate representation can be passed through eight building blocks with a 64→16→64 setting. A global average pooling layer can then be applied to reduce the spatial dimension, and the output of the global average pooling layer can include a vector of size sixty-four. Finally, a linear layer can project the vector onto a scalar number, which can include a correlation score between two input time series. In some non-limiting embodiments or aspects, the plurality of learned templates includes thirty-two learned templates, wherein the plurality of pairwise distance matrices include thirty-two pairwise distance matrices, wherein the tensor includes an input dimension of thirty-two, and wherein the feature vector of each of the plurality of known time series includes a vector of size sixty-four.
[0118] like Figure 6 As shown in Example (b), unlike methods using a Siamese network framework, when using RN2D, it is not necessary to extract the hidden representation of each time series in the database before deployment. If there are n time series in the database, RN2D can run n times during query time to calculate the distance between the query time series and each time series in the database. In contrast, methods using a Siamese network framework only need to run the model once during query time, making the RN2D method an order of magnitude slower. To address the efficiency problem of RN2D, non-limiting embodiments or aspects of this disclosure provide Residual Network 2D with RN2Dw / T.
[0119] For reference Figure 9 , Figure 9 This is a network diagram based on some non-limiting embodiments or aspects of the RN2Dw / T model. The RN2Dw / T model based on some non-limiting embodiments or aspects can solve the efficiency problem of RN2D. The RN2Dw / T method based on some non-limiting embodiments or aspects can be designed to be as efficient as the RN2D method, while being an order of magnitude faster.
[0120] like Figure 9 As shown, the RN2Dw / T model may differ from the RN2D model in four ways according to some non-limiting embodiments or aspects: (1) the last linear layer of the RN2Dw / T model may output a vector instead of a scalar as in the RN2D model; (2) the RN2Dw / T model may take a single time series as input, while the RN2D model takes a pair of time series as input; (3) for the RN2Dw / T model, multiple pairwise distance matrices (e.g., 32 pairwise distance matrices) between the input time series and multiple templates (e.g., 32 templates, etc.) may be computed, while for the RN2D model, only one pairwise distance matrix between two input time series is computed; and (4) the input dimension of the first 2D convolutional layer in the RN2Dw / T model may include multiple dimensions (e.g., 32 dimensions, etc.), while in the RN2D model, the input dimension is only one.
[0121] Here, the first two differences may exist between the models because the RN2Dw / T model aims to extract the feature vector of the input time series, while the RN2D model calculates the correlation score between two input time series.
[0122] The third difference lies in the pairwise distance matrix calculation step, which is also why, according to some non-limiting embodiments or aspects, the RN2Dw / T model is much faster than the RN2D model. The pairwise distance matrix can be calculated as follows: given an input time series a = [a1, ..., a...] wGiven the k-th template t = [tk, 1, ..., tk, w], the k-th pairwise distance matrix... Available The pairwise distance matrix of each of multiple templates (e.g., 32 templates, etc.) can be computed, resulting in multiple w × h matrices (e.g., 32 w × h matrices, etc.). The multiple templates (e.g., 32 templates, etc.) can be learned during the training phase and may include a reference time series that helps the model project the input time series into Euclidean space using a 2D convolutional design. The multiple w × h matrices (e.g., 32 w × h matrices, etc.) can then be stacked together to form a w × h × 32 tensor for the first 2D convolutional layer. The w × h × 32 tensor may be the output of the pairwise distance matrix computation step of the RN2Dw / T model.
[0123] The fourth difference between the two models can be attributed to the fact that the input tensor of the first convolutional layer in the RN2Dw / T model can be w × h × 32, while the input tensor of the first convolutional layer in the RN2D model is w × h × 1.
[0124] like Figure 6 As shown in example (c), the feature vector for each time series in the database can be extracted using the RN2Dw / T model before the query time. In this way, when a user submits a query for a time series, the non-limiting embodiments or aspects of this disclosure may only need to run the model on the time series once. Although each of the RN2Dw / T and RN2D models has similar capacity, the RN2Dw / T model enables a more efficient query mechanism, which is advantageous when designing real-world CTSR systems.
[0125] In some non-limiting embodiments or aspects, the Bayesian personalized ranking loss, as described in the paper entitled “BPR: Bayesian personalized ranking from implicit feedback” by Steffen Rendle, Christoph Freudenthaler, Zeno Gantner, and Lars Schmidt-Thieme in the 2009 Proceedings of the Twenty-Fifth Conference on Uncertainty in Artificial Intelligence, pages 452–461, can be used to train or optimize RN2Dw / T models, the entire contents of which are incorporated herein by reference in their entirety. The Bayesian personalized ranking loss is suitable for the CTSR problem, as the CTSR problem is a “Learning to Rank” problem. Given a batch of training data… In this case, the loss function can be defined according to the following equation (1):
[0126] (1)
[0127] in For training data batches , The batch size is specified, and each sample in the batch is a time series containing the query (or anchor). Positive time series and negative time series tuple , It is an sigmoid function, and This refers to a residual network or model. In some non-limiting embodiments or aspects, the AdamW optimizer, as described by Ilya Loshchilov and Frank Hutter in their 2018 paper entitled “Decoupled Weight Decay Regularization” at the International Conference on Learning Representations, can be used to train RN2Dw / T using a Bayesian personalized ranking loss, the entire contents of which are incorporated herein by reference in their entirety.
[0128] For reference Figure 3A and Figure 3BThe flowchart illustrates a method 300 for efficient content-based time series retrieval, based on some non-limiting embodiments or aspects. Figure 3A and Figure 3B The steps shown are for illustrative purposes only. It will be understood that additional, fewer, different, and / or different orders of steps may be used in some non-limiting embodiments or aspects. In some non-limiting embodiments or aspects, steps may be performed automatically in response to the execution and / or completion of previous steps.
[0129] like Figure 3A As shown, in step 302, method 300 includes obtaining multiple known time series from at least one database. For example, transaction processing system 101 may obtain multiple known time series from at least one database. The multiple known time series may be associated with or originate from multiple different data domains.
[0130] In some non-limiting embodiments or aspects, multiple known time series include multiple known transaction time series associated with multiple merchants, and each known time series is associated with metadata associated with the merchant associated with the known time series. For example, a known time series may include a time series identification flag indicating that merchant system 104 uses electronic payment processing network 100. As an example, a known (or unknown) time series may include transaction data associated with multiple transactions and / or multiple points in time. As an example, a payment transaction may include transaction parameters and / or features associated with the payment transaction. Transaction parameters and / or features associated with a payment transaction (e.g., categorical features, numerical features, local features, graphical features, or embeddings, etc.) may include transaction parameters of the transaction, features determined based on the transaction parameters (e.g., using feature engineering, etc.), such as account identifiers (e.g., PAN, etc.), transaction amount, transaction date and / or time, type of product and / or service associated with the transaction, currency exchange rate, currency type, merchant type, merchant name, merchant location, etc. However, the non-limiting implementation or aspect is not limited thereto, and the transaction parameters and / or characteristics of the transaction may include any data, including any type of parameter associated with any type of transaction.
[0131] like Figure 3AAs shown, in step 304, method 300 includes: for each known time series in a plurality of known time series, calculating a pairwise distance matrix between the known time series and each learned template in a plurality of learned templates to generate a plurality of pairwise distance matrices. For example, for each known time series in a plurality of known time series, transaction processing system 101 may calculate a pairwise distance matrix between the known time series and each learned template in a plurality of learned templates to generate a plurality of pairwise distance matrices. As an example, transaction processing system 101 may calculate the pairwise distance matrix as follows: given an input time series a = [a1, ..., a...] w Given the k-th template t = [tk, 1, ..., tk, w], the k-th pairwise distance matrix... Available The pairwise distance matrix of each of multiple templates (e.g., 32 templates, etc.) can be computed, resulting in multiple w × h matrices (e.g., 32 w × h matrices, etc.). The multiple templates (e.g., 32 templates, etc.) can be learned during the training phase and may include a reference time series that helps the model project the input time series into Euclidean space using a 2D convolutional design.
[0132] like Figure 3A As shown, in step 306, method 300 includes: for each of the multiple known time series, stacking multiple pairwise distance matrices together to generate a tensor. For example, for each of the multiple known time series, transaction processing system 101 may stack multiple pairwise distance matrices together to generate a tensor. As an example, transaction processing system 101 may stack multiple w × h matrices (e.g., 32 w × h matrices, etc.) together to form a w × h × 32 tensor of a first 2D convolutional layer. The w × h × 32 tensor may be the output of the pairwise distance matrix calculation step of the RN2Dw / T model.
[0133] like Figure 3A As shown, in step 308, method 300 includes: processing a tensor with a residual network for each of a plurality of known time series. For example, for each of the plurality of known time series, transaction processing system 101 may use a residual network to process the tensor, wherein the residual network receives the tensor as input and provides a feature vector of the known time series as output. As an example, a residual network may receive a tensor as input and provide a feature vector of the known time series as output. In such instances, and again referring to... Figure 9 The residual network may include methods for projecting D onto Space (e.g., projecting D onto) The residual network uses convolutional layers (e.g., 7×7 convolutional layers with a stride of 2) and rectified linear unit (ReLU) layers. Following the ReLU layers, intermediate representations can be passed through multiple building blocks (e.g., eight building blocks with a 64→16→64 setting), and global average pooling layers can be applied to reduce spatial dimensionality. The output of the global average pooling layer can be multidimensional (e.g., a vector of size 64), and the last linear layer of the residual network can output a vector instead of a scalar as in the RN2D model.
[0134] like Figure 3A As shown, in step 310, method 300 includes providing and / or storing feature vectors for each of a plurality of known time series. For example, transaction processing system 101 may provide and / or store feature vectors for each of a plurality of known time series. As an example, transaction processing system 101 may provide feature vectors for each of a plurality of known time series. In such instances, transaction processing system 101 may store the feature vectors for each of a plurality of known time series in at least one database.
[0135] like Figure 3A As shown, in step 312, method 300 includes obtaining an unknown time series. For example, transaction processing system 101 may obtain an unknown time series.
[0136] In some non-limiting embodiments or aspects, the unknown time series includes an unknown transaction time series associated with the merchant and / or includes metadata associated with the merchant. For example, the unknown time series may include a time series identification flag indicating that the merchant system 104 uses the electronic payment processing network 100. As an example, the unknown (or known) time series may include transaction data associated with multiple transactions and / or multiple points in time. As an example, a payment transaction may include transaction parameters and / or features associated with the payment transaction. Transaction parameters and / or features associated with the payment transaction (e.g., categorical features, numerical features, local features, graphical features, or embeddings, etc.) may include transaction parameters that may include the transaction, features determined based on them (e.g., using feature engineering, etc.), and / or similar elements such as account identifiers (e.g., PAN, etc.), transaction amount, transaction date and / or time, type of product and / or service associated with the transaction, currency exchange rate, currency type, merchant type, merchant name, merchant location, and / or similar elements. However, non-limiting embodiments or aspects are not limited to this, and transaction parameters and / or features of a transaction may include any data, including any type of parameter associated with any type of transaction.
[0137] like Figure 3BAs shown, in step 314, method 300 includes calculating pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate additional pairwise distance matrices. For example, transaction processing system 101 may calculate pairwise distance matrices between the unknown time series and each of the plurality of learned templates to generate additional pairwise distance matrices. As an example, transaction processing system 101 may calculate additional pairwise distance matrices between the unknown time series and each learned template as follows: given an input time series a = [a1, ..., a...] w Given an unknown time series and the k-th template t = [tk, 1, ..., tk, w], the k-th pairwise distance matrix... Available To calculate. Another pairwise distance matrix can be calculated for each template in multiple templates (e.g., 32 templates, etc.), thus producing multiple additional w × h matrices (e.g., 32 w × h matrices, etc.).
[0138] like Figure 3B As shown, in step 316, method 300 includes stacking multiple additional pairwise distance matrices together to generate another tensor. For example, transaction processing system 101 may stack multiple additional pairwise distance matrices together to generate another tensor. As an example, transaction processing system 101 may stack multiple additional w × h matrices (e.g., 32 w × h matrices, etc.) together to form another w × h × 32 tensor of the first 2D convolutional layer. The other w × h × 32 tensor may be the output of the pairwise distance matrix calculation step of the RN2Dw / T model.
[0139] like Figure 3B As shown, in step 318, method 300 includes processing another tensor with a residual network, wherein the residual network receives another tensor as input and provides a feature vector of the unknown time series as output. For example, transaction processing system 101 may use a residual network to process another tensor. As an example, a residual network may receive another tensor as input and provide a feature vector of the unknown time series as output. In such instances, and again referring to... Figure 9 The residual network may include methods for projecting D onto Space (e.g., projecting D onto) The residual network uses convolutional layers (e.g., a 7×7 convolutional layer with a stride of 2) and ReLU layers. After the ReLU layers, the intermediate representation can be passed through multiple building blocks (e.g., eight building blocks with a 64→16→64 setting) and a global average pooling layer can be applied to reduce the spatial dimensionality. The output of the global average pooling layer can be multidimensional (e.g., a vector of size 64), and the last linear layer of the residual network can output a vector instead of a scalar as in the RN2D model.
[0140] like Figure 3B As shown, in step 320, method 300 includes: for each known time series stored in a database, determining the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series. For example, for each known time series stored in a database, transaction processing system 101 may determine the distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series. As another example, for each known time series stored in a database, transaction processing system 101 may determine the Euclidean distance between the known time series and the unknown time series based on the stored feature vector of the known time series and the feature vector of the unknown time series.
[0141] like Figure 3B As shown, in step 322, method 300 includes identifying at least one known time series determined to correspond to the unknown time series based on the distance between each known time series and the unknown time series. For example, transaction processing system 101 may identify at least one known time series determined to correspond to the unknown time series based on the distance between each known time series and the unknown time series. As an example, transaction processing system 101 may identify a predetermined or desired number of known time series closest to the unknown time series based on the distance between each known time series and the unknown time series (e.g., Euclidean distance, etc.). As an example, transaction processing system 101 may identify one or more known time series within a threshold distance from the unknown time series based on the distance between each known time series and the unknown time series (e.g., Euclidean distance, etc.). In such instances, transaction processing system 101 may identify the type of business (e.g., restaurant, grocery store, etc.) associated with the unknown time series based on at least one known time series determined to correspond to the unknown time series, for example, if the business fails to provide accurate business type information.
[0142] experiment
[0143] This section presents experimental results on the CTSR benchmark dataset created from the UCR archive and on transaction datasets based on real business problems (see, for example...). Figure 4 (etc.). A neural network-based approach was implemented using PyTorch, and the model with the best average NDCG@10 score on the validation data was selected for testing. SciPy was used to compute ED, and Tslearn was used to compute DTW.
[0144] The CTSR benchmark dataset was created from the UCR archive, which is a collection of 128 time-series classification datasets from various domains such as motion, electricity demand, and transportation. The UCR archive is widely used as a benchmark for time-series classification algorithms. To convert the UCR archive into the CTSR benchmark dataset, please use the following steps.
[0145] (1) Extract all time series data from each dataset and merge any identical time series that appear in multiple datasets. This step is performed because identical time series may exist in multiple datasets. For example, the DodgerLoopDay, DodgerLoopGame, and DodgerLoopWeekend datasets contain identical time series because these datasets were created from the same set of time series.
[0146] (2) To ensure consistency in length, the length of each time series is normalized to 512. For time series longer than 512 time steps, a resampling function from the SciPy library is used to shorten the longer time series. Conversely, for shorter time series, the shorter time series is zero-padded to 512 time steps.
[0147] (3) Apply z-normalization to all time series. During normalization, zero-padding is ignored. The z-normalization step is a standard procedure for preparing time series data.
[0148] (4) The ground truth labels for each pair of time series are generated by determining whether the pair of time series are related or unrelated. If two time series belong to the same dataset and share the same class label in the original UCR archive, the two time series are considered related. Otherwise, the two time series are considered unrelated.
[0149] (5) The data was split into three groups: training, testing, and validation. Specifically, 10% of the time series were randomly selected as test queries, another 10% as validation queries, and the remaining time series were used as training data. To ensure that each test / validation query had a sufficient number of relevant time series in the training set, any query time series with fewer than two relevant time series was transferred to the training set. After this data splitting procedure, 136,377 training time series, 17,005 test queries, and 17,005 validation queries were obtained.
[0150] (6) To facilitate efficient evaluation, 1,000 time series are sampled from the training set for each test / validation query. Given a query, if the number of relevant time series is less than 100, all relevant time series are selected. If the number of relevant time series exceeds 100, 100 relevant time series are randomly selected. It is ensured that the number of relevant time series in each sample set is less than or equal to 100 (i.e., 10% of 1,000). For the remaining time series, the remaining time series are randomly sampled from the irrelevant time series in the training set.
[0151] (7) To measure the performance of different retrieval methods, common information retrieval metrics for each query are calculated, including precision at k (Prec@k), average precision at k (AP@k), and normalized discount cumulative gain at k (NDCG@k).
[0152] Figure 10 This is the performance measurement table for the experiment. The performance measurement at k = 10 for each of the 17,005 test queries is averaged and presented in... Figure 10 The table shows the results. When comparing performance, a two-sample t-test using non-aggregate performance measures (where α = 0.05) is performed to test statistical significance. The reported query time is the average time spent calculating the correlation scores between the query and 136,377 time series in the training dataset. The average query time was calculated using 1,000 distinct time series from the test data as queries. Figure 10 The table allows for easy comparison of different methods based on different performance measurements.
[0153] First, we discuss the following three performance metrics: PREC@10, AP@10, and NDCG@10. When comparing the performance of two non-neural network baselines (ED and DTW), DTW significantly outperformed ED in all three performance metrics. This suggests that using alignment information helps solve the CTSR problem, and similar conclusions have been reached for time series classification problems.
[0154] When considering the top four neural network baselines (i.e., LSTM, GRU, TF, and RN1D), each significantly outperforms the DTW method, suggesting that using high-capacity models is beneficial for solving the CTSR problem. One possible reason for this is that the CTSR dataset consists of time series data from many different domains, requiring high-capacity models to learn the diverse patterns within the data. Of the four methods, LSTM significantly outperforms the second-best in all three performance metrics.
[0155] according to t The test results show that the RN2D method—a high-capacity model utilizing alignment information—significantly outperforms all other methods. When comparing the RN2Dw / T method according to the non-limiting embodiments or aspects with the RN2D method, the former achieves higher performance in all three performance measures, but the difference is not significant. Therefore, each of the RN2Dw / T method and the RN2D method according to the non-limiting embodiments or aspects can be considered a better performing method for the CTSR dataset across the three performance measures.
[0156] When considering query time, the eight test methods can be divided into two categories: slower methods with query times exceeding 30 seconds (i.e., DTW and RN2D), and faster methods with each query taking less than 100 milliseconds (i.e., ED, LSTM, GRU, TF, RN1D, and RN2Dw / T). The main difference between the faster and slower groups is that all fast methods compute relevance scores in Euclidean space, while slower methods compute scores in other spaces. Overall, the RN2Dw / T method according to the non-limiting embodiment or aspect is the best method because it is efficient in retrieving relevant time series and also efficient in terms of query time.
[0157] Figure 11 This is a critical difference (CD) plot comparing experimental performance. The CD plot was constructed to compare the performance of different methods and follows much previous work on time series classification. The CD plot displays the average rank of each method based on performance measures and indicates whether two methods exhibit significant performance differences based on the Wilcoxon signed-rank test (α = 0.05). The results show that, except for the RN2Dw / T and RN2D methods according to non-limiting embodiments or aspects (which do not show significant performance differences), almost all methods exhibit significant differences in performance from each other. This conclusion is consistent with... Figure 10 The findings presented in the table are consistent.
[0158] Figure 12 This is a graph showing the performance measurement results of the experiment. The graph uses various values of k ranging from 5 to 15 to present the performance measurement results. This is to ensure that... Figure 10 The table and Figure 11The conclusions drawn from the CD diagram are not limited to a specific choice of k. For readability, ED and DTW are omitted from the diagram because their performance is significantly worse than other methods.
[0159] like Figure 12 As shown, the RN2Dw / T method according to the non-limiting embodiments or aspects achieves the best performance at different values of all three performance measures. The remaining methods, in order from best to worst, are: RN2D, LSTM, GRU, RN1D, and TF. These results are consistent with... Figure 10 The table and Figure 11 The findings are consistent with those presented in the CD diagram.
[0160] Figure 13 The time series of the first eight retrieved items in the experiment are shown. Two queries with different levels of complexity were selected from the test dataset. The simpler queries consist of a single cycle of patterns, while the more complex queries contain periodic signals. Periodic signals in complex queries typically require shift-invariant distance measurements to correctly retrieve relevant items. Figure 13 This demonstrates the challenge of the CTSR problem because even irrelevant time series can visually resemble queries. Retrieved time series are plotted in light gray if they are relevant, and in black if they are irrelevant.
[0161] Can be checked Figure 13 The following observations are drawn from the different time series retrieved by the methods shown. The ED method struggles with more complex queries because it cannot align the query with the relevant time series. The DTW method outperforms the ED method on complex queries, but the alignment freedom of the DTW method negatively impacts its performance on simple queries. When considering two queries, the four neural network baselines (i.e., LSTM, GRU, TF, and RN1D) outperform both the ED and DTW methods. However, none of these baselines outperform the RN2Dw / T and RN2D methods, which reliably retrieve relevant items according to non-limiting embodiments or aspects.
[0162] To evaluate the effectiveness of different CTSR system designs in solving Figure 4 To assess the effectiveness and efficiency of these CTSR solutions in addressing the business problems presented, a transaction time-series dataset was constructed to test them. The dataset includes 160,014 training time series, 19,993 test queries, and 19,992 validation queries, each representing a merchant's time-series identification marker, with a length of 168. For a given query time series, if the retrieved time series belongs to a merchant with the same business type as the query time series, it is considered a relevant item from the database. If the retrieved time series belongs to a different business type than the query time series, it is considered an irrelevant item. Figure 14 This is a table of additional performance measurements for the experiment. For Figure 14 The table calculates the performance measurement at k = 10 for each of the 19,993 test queries and presents the average. Faster deep learning methods (i.e., LSTM, GRU, TF, RN1D, and RN2Dw / T according to non-limiting embodiments or aspects) are tested only for transaction time series, as these methods are the clear winners from experiments conducted on the UCR archived CTSR dataset, considering both effectiveness and efficiency.
[0163] like Figure 14 As shown, the RN2Dw / T method according to the non-limiting embodiments or aspects is the best performing method, where the performance difference between the RN2Dw / T method according to the non-limiting embodiments or aspects and the second best RN1D method appears to be small. However, based on a two-sample t-test (where α = 0.05), the difference is statistically significant. Figure 15 This is a CD plot showing further performance of the comparative experiment. The CD plot (which is similar to the CD plot of the UCR archive experiment) confirms these findings and is consistent with... Figure 14 The performance results presented in the table are consistent.
[0164] The performance differences between test methods were examined under different settings of k, and the results are presented in... Figure 16 The graph in the image shows the results of other performance measurements from the experiment. (Example:) Figure 16 As shown, the RN2Dw / T method according to the non-limiting embodiments or aspects consistently outperforms other methods for different values of k.
[0165] Figure 17 This is the timeline for querying the experiment. Figure 17 The table shows the average query time measured for each method. The query time for each test query is measured in milliseconds. Each of the exact and approximate nearest neighbor searches was used in the experiments.
[0166] To perform approximate nearest neighbor search, a k-nearest neighbor graph is constructed using the nearest neighbor descent method. The PyNNDescent library is used to implement this method. By replacing the exact nearest neighbor search with an approximate nearest neighbor search method, query time is significantly reduced. Furthermore, performance (i.e., PREC@10, AP@10, and NDCG@10) remains consistent with... Figure 14 The numbers presented in the table are exactly the same. A similar structure can be constructed based on the results of the approximate nearest neighbor search. Figure 15 CD diagrams and similar Figure 16 The performance in the graph is the same as that in the k-graph, and the conclusions remain the same.
[0167] Therefore, the non-limiting embodiments or aspects of this disclosure can provide efficient and effective CTSR models that are superior to alternative models, while still providing reasonable inference runtime. For example, the non-limiting embodiments or aspects of this disclosure can outperform existing methods for time series retrieval in terms of efficiency and effectiveness. The non-limiting embodiments or aspects of this disclosure can be used to identify transaction types in electronic payment networks, and / or to improve the efficiency of the non-limiting embodiments or aspects of this disclosure by incorporating low-bit representation techniques.
[0168] The described aspects include artificial intelligence or other operations, whereby the system utilizes apparent intelligence to process inputs and generate outputs. Artificial intelligence can be implemented wholly or partially by a model. The model can be implemented as a machine learning model. Learning can be supervised learning, unsupervised learning, reinforcement learning, or a hybrid learning approach, whereby various learning techniques are employed to generate the model. Learning can be performed as part of training. Training the model can include obtaining a set of training data and adjusting the characteristics of the model to obtain the desired model output. For example, three characteristics can be associated with a desired item location. In this case, training can include receiving three characteristics as input to the model and adjusting the characteristics of the model such that, for each set of three characteristics, the output device state matches the desired device state associated with historical data.
[0169] In some implementations, training can be dynamic. For example, the system can use a set of events to update the model. The detectable properties from the events can be used to adjust the model.
[0170] The model can be an equation, an artificial neural network, a recurrent neural network, a convolutional neural network, a decision tree, or other machine-readable artificial intelligence architecture. The properties of the architecture that can be adjusted during training can vary based on the chosen model. For example, if the chosen model is a neural network, properties could include input elements, network layers, node density, node activation thresholds, weights between nodes, input or output value weights, etc. If the model is implemented as an equation (e.g., regression), properties could include weights for input parameters, thresholds or limits for evaluating output values, or criteria for selection from a set of equations.
[0171] Once the model is trained, retraining can be included to refine or update the model to reflect additional data or specific operating conditions. Retraining can be based on one or more signals detected by the device described herein or as part of the method described herein. Upon detection of the indicated signal, the system can activate the training process to adjust the model as described.
[0172] Further examples of machine learning and modeling features that can be included in the implementation schemes discussed above are described in “A survey of machine learning for big data processing” by Qiu et al. in the EURASIP Journal on Advances in Signal Processing (2016), which is hereby incorporated in its entirety by reference.
[0173] Although embodiments have been described in detail for illustrative purposes, it should be understood that such details are for that purpose only, and this disclosure is not limited to the disclosed embodiments or aspects, but rather is intended to cover modifications and equivalent arrangements within the spirit and scope of the appended claims. For example, it should be understood that this disclosure contemplates, as far as possible, that one or more features of any embodiment or aspect may be combined with one or more features of any other embodiment or aspect. In fact, any of these features may be combined in a manner not specifically stated in the claims and / or disclosed in the specification. Although each dependent claim listed below may depend directly on only one claim, the disclosure of possible embodiments includes each dependent claim in combination with each other claim in the claim set.
Claims
1. A method for time series extraction, comprising: Using at least one processor, obtain multiple known time series from at least one database; For each of the plurality of known time series: The at least one processor is used to calculate the pairwise distance matrix between the known time series and each of the plurality of learned templates to generate a plurality of pairwise distance matrices; The plurality of pairwise distance matrices are stacked together using the at least one processor to generate a multidimensional tensor; as well as The multidimensional tensor is processed using a residual network with at least one processor in the following manner: The multidimensional tensor is projected into Euclidean space using 2D convolutional layers that include the input dimension, where the input dimension includes multiple dimensions. An intermediate representation of the known time series is generated using a rectified linear unit (ReLU) layer based on a multidimensional tensor projected into Euclidean space. Based on the intermediate representation, a merged representation of the known time series is generated using multiple bottleneck building blocks. Using a global pooling layer, a multidimensional vector of the known time series is generated based on the merged representation. Using a linear layer, feature vectors of the known time series are generated based on the multidimensional vectors; and The feature vector of each of the plurality of known time series is provided using the at least one processor; The residual network is trained using a loss function that depends on a batch of training data, where each sample in the batch is a tuple that includes the query time series, the positive time series, and the negative time series. The residual network is trained using a loss function defined according to the following equation: in For the training data of a batch , For batch size, It is a tuple for each sample in the batch, which includes the query time series. Positive time series and negative time series , It is the Sigmoid function, and This refers to the residual network.
2. The method according to claim 1, further comprising: The feature vector of each of the plurality of known time series is stored in the at least one database using the at least one processor.
3. The method according to claim 2, further comprising: The unknown time series is obtained using the at least one processor; The at least one processor is used to calculate the pairwise distance matrix between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; The additional pairwise distance matrices are stacked together using the at least one processor to generate another multidimensional tensor; Based on the other multidimensional tensor, the feature vector of the unknown time series is generated using the residual network through the at least one processor; For each known time series among the plurality of known time series stored in the database, the distance between the known time series and the unknown time series is determined by the at least one processor based on the stored feature vector of the known time series and the feature vector of the unknown time series; as well as The at least one processor identifies at least one known time series corresponding to the unknown time series based on the distance between each known time series and the unknown time series.
4. The method of claim 1, wherein the plurality of known time series comprises a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
5. The method of claim 1, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the multidimensional tensor comprises thirty-two input dimensions, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four.
6. A system for time series extraction, comprising: At least one processor, said at least one processor being coupled to memory and configured to: Obtain multiple known time series from at least one database; For each of the plurality of known time series: Calculate the pairwise distance matrix between the known time series and each of the multiple learned templates to generate multiple pairwise distance matrices; The multiple pairwise distance matrices are stacked together to generate a multidimensional tensor; as well as The multidimensional tensor is processed using a residual network in the following manner: The multidimensional tensor is projected into Euclidean space using 2D convolutional layers that include the input dimension, where the input dimension includes multiple dimensions. An intermediate representation of the known time series is generated using a rectified linear unit (ReLU) layer based on a multidimensional tensor projected into Euclidean space. Based on the intermediate representation, a merged representation of the known time series is generated using multiple bottleneck building blocks. Using a global pooling layer, a multidimensional vector of the known time series is generated based on the merged representation. Using a linear layer, feature vectors of the known time series are generated based on the multidimensional vectors; and Provide the feature vector for each of the plurality of known time series; The residual network is trained using a loss function that depends on a batch of training data, where each sample in the batch is a tuple that includes the query time series, the positive time series, and the negative time series. The residual network is trained using a loss function defined according to the following equation: in For the training data of a batch , For batch size, It is a tuple for each sample in the batch, which includes the query time series. Positive time series and negative time series , It is the Sigmoid function, and This refers to the residual network.
7. The system of claim 6, wherein the at least one processor is further configured to: The feature vector of each of the plurality of known time series is stored in the at least one database.
8. The system of claim 7, wherein the at least one processor is further configured to: Obtaining unknown time series; Calculate the pairwise distance matrix between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; The other pairwise distance matrices are stacked together to generate another multidimensional tensor; Based on the other multidimensional tensor and the residual network, the feature vector of the unknown time series is generated; for each known time series stored in the database, the distance between the known time series and the unknown time series is determined based on the stored feature vector of the known time series and the feature vector of the unknown time series. as well as Based on the distance between each known time series and the unknown time series, at least one known time series is identified as corresponding to the unknown time series.
9. The system of claim 6, wherein the plurality of known time series comprises a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
10. The system of claim 6, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the multidimensional tensor comprises thirty-two input dimensions, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four.
11. A computer program product for time series retrieval, comprising a non-transient computer-readable medium, the non-transient computer-readable medium including program instructions that, when executed by at least one processor, cause the at least one processor to: Obtain multiple known time series from at least one database; For each of the plurality of known time series: Calculate the pairwise distance matrix between the known time series and each of the multiple learned templates to generate multiple pairwise distance matrices; The multiple pairwise distance matrices are stacked together to generate a multidimensional tensor; as well as The multidimensional tensor is processed using a residual network in the following manner: The multidimensional tensor is projected into Euclidean space using 2D convolutional layers that include the input dimension, where the input dimension includes multiple dimensions. An intermediate representation of the known time series is generated using a rectified linear unit (ReLU) layer based on a multidimensional tensor projected into Euclidean space. Based on the intermediate representation, a merged representation of the known time series is generated using multiple bottleneck building blocks. Using a global pooling layer, a multidimensional vector of the known time series is generated based on the merged representation. Using a linear layer, feature vectors of the known time series are generated based on the multidimensional vectors; and Provide the feature vector for each of the plurality of known time series; The residual network is trained using a loss function that depends on a batch of training data, where each sample in the batch is a tuple that includes the query time series, the positive time series, and the negative time series. The residual network is trained using a loss function defined according to the following equation: in For the training data of the batch mentioned above , For batch size, It is a tuple for each sample in the batch, which includes the query time series. Positive time series and negative time series , It is the Sigmoid function, and This refers to the residual network.
12. The computer program product of claim 11, wherein the program instructions, when executed by the at least one processor, further cause the at least one processor to: The feature vector of each of the plurality of known time series is stored in the at least one database.
13. The computer program product of claim 12, wherein the program instructions, when executed by the at least one processor, further cause the at least one processor to: Obtaining unknown time series; Calculate the pairwise distance matrix between the unknown time series and each of the plurality of learned templates to generate a plurality of additional pairwise distance matrices; The other pairwise distance matrices are stacked together to generate another multidimensional tensor; Based on the other multidimensional tensor, and using the residual network, the feature vector of the unknown time series is generated; For each known time series stored in the database, the distance between the known time series and the unknown time series is determined based on the stored feature vector of the known time series and the feature vector of the unknown time series. as well as Based on the distance between each known time series and the unknown time series, at least one known time series is identified as corresponding to the unknown time series.
14. The computer program product of claim 11, wherein the plurality of known time series comprises a plurality of known transaction time series associated with a plurality of merchants, and wherein each known time series is associated with metadata associated with the merchant associated with the known time series.
15. The computer program product of claim 11, wherein the plurality of learned templates comprises thirty-two learned templates, wherein the plurality of pairwise distance matrices comprises thirty-two pairwise distance matrices, wherein the tensor comprises an input dimension of thirty-two, and wherein the feature vector of each of the plurality of known time series comprises a vector of size sixty-four, and wherein the residual network comprises a two-dimensional residual network.