WO2014045556A1 - 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムの記憶媒体 - Google Patents

時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムの記憶媒体 Download PDF

Info

Publication number
WO2014045556A1
WO2014045556A1 PCT/JP2013/005439 JP2013005439W WO2014045556A1 WO 2014045556 A1 WO2014045556 A1 WO 2014045556A1 JP 2013005439 W JP2013005439 W JP 2013005439W WO 2014045556 A1 WO2014045556 A1 WO 2014045556A1
Authority
WO
WIPO (PCT)
Prior art keywords
result data
identification information
processing
result
output
Prior art date
Application number
PCT/JP2013/005439
Other languages
English (en)
French (fr)
Inventor
将通 高木
Original Assignee
日本電気株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 日本電気株式会社 filed Critical 日本電気株式会社
Priority to JP2014536587A priority Critical patent/JP6036835B2/ja
Priority to US14/427,236 priority patent/US20150248441A1/en
Publication of WO2014045556A1 publication Critical patent/WO2014045556A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • G06F16/219Managing data history or versioning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/1873Versioning file systems, temporal file systems, e.g. file system supporting different historic versions of files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/448Execution paradigms, e.g. implementations of programming paradigms

Definitions

  • the present invention relates to a time-series data processing device, a time-series data processing method, and a time-series data processing program for processing time-series data.
  • the present invention relates to a time-series data processing device, a time-series data processing method, and a time-series data processing program in which the content of processing for time-series data changes.
  • data processing for time-series data refers to processing performed on time-series input data, that is, a series of data input one after another. Similarly, the result data of the data processing for the time series data is output one after another. “To be input one after another” means that a plurality of data arrive at the processing device at different timings over a certain period.
  • time series data processing there is a process of taking the sum of the two most recent values of the time series data.
  • the data array is represented as [1, 2, 3, 4], the data set is represented as ⁇ 1, 2, 3, 4 ⁇ , and the data set is represented as ⁇ 10.
  • Degrees are represented by the type of parenthesis, such as degree, January 1>.
  • numerical values of individual data such as 1 and 2 are expressed as “1” and “2”, and are distinguished from codes indicating constituent elements.
  • the cycle of the clock used for the operation of the time-series data processing device is called “cycle”, and this is used as a unit of period.
  • “At the start of the cycle” means the first time of the period
  • “at the end of the cycle” means the last time of the period.
  • the first cycle for a certain reference time is a period between the reference time plus zero seconds and the reference time plus 1 nanosecond
  • the Nth cycle is the reference time plus (N ⁇ 1 ) Means the period from nanoseconds to the reference time plus N nanoseconds.
  • the start of the Mth cycle means a reference time plus (M ⁇ 1) nanoseconds
  • the end of the Mth cycle means a reference time plus M nanoseconds.
  • the input data is a set of one or more values.
  • a pair of temperature and date For example, a pair of temperature and date, a pair of temperature only, and a pair of brand, stock price and time.
  • a set of temperature and date is represented as ⁇ 10 degrees, January 1>.
  • the input data and the value handled by the device are simply referred to as “data” when there is no possibility of confusion between them.
  • Time series data processing is often performed for multiple input data. Furthermore, time-series data processing is often performed on a window of time-series data.
  • a “window” is a set of input data, and there are two types. One is a set of the most recent N input data, where N is a predetermined number (N is an integer equal to or greater than 1). The other is a set of input data that falls within that period, where P is a period of a predetermined time and one element of the set of input data is regarded as a time.
  • a set of temperature and date is input data, and ⁇ 10 degrees, January 1>, ⁇ 11 degrees, January 2>, ⁇ 10 degrees, January 3>, ⁇ 10 degrees, January 4 It is assumed that time series data of> is given.
  • the windows that fit in the period from January 4 to the past three days are ⁇ 11 degrees, January 2>, ⁇ 10 degrees, January 3>, ⁇ 10 degrees, January 4> ⁇ .
  • window data In time series data processing, this window data is often stored.
  • windows or window data are represented as arrays or sets.
  • Partition An area in which the contents of the time series data processing can be defined, specifically, an area in which circuit information or the like for configuring a circuit for executing the processing can be written
  • IC Integrated (Circuit) chip having a plurality of.
  • An example of such an IC chip is a FPGA (Field Programmable Gate Gate Array).
  • time series data processing can be executed using a processor that reads and executes a program from a memory as an IC chip. In this case, a program for designating processing contents, that is, a processing procedure may be written in the memory.
  • first user-defined process referred to as “old process”
  • second user-defined process referred to as “new process”. That is, the first user-defined process (referred to as “old process”) is executed in the first partition on the IC chip. Then, circuit information for executing the second user-defined process (referred to as “new process”) is written in the second partition when the first user-defined process is executed, the new process is executed, and the old process is stopped. In this way, there is a need to change the old process to the new process.
  • an application that calculates an index for determining the timing of buying and selling financial products such as stock certificates.
  • Some devices can calculate only a finite number of indices simultaneously. The brands and strategies to buy and sell change according to the time. Therefore, there is a need to change the index to be calculated according to the brand to be traded at that time and the trading strategy.
  • time-series data 1 is input, and the old process saves the value as window data.
  • time series data 2 is input, and the old process saves the value as window data. Also, since the old process has the latest two values, “3” is output as the result data.
  • an instruction to change to the new process is given. Further, it is assumed that information for executing a new process is written in the apparatus and the operation is started. For example, it is assumed that circuit information for executing a new process is written in a partial area of the FPGA. Here, it is assumed that circuit information for executing the new process is written separately from the circuit information for executing the old process, and the old process and the new process operate in parallel for a while.
  • time series data “3” is input, and the new process saves the value as window data.
  • time series data “4” is input, and the new process saves the value as window data.
  • time series data “5” is input, and the new process saves the value as window data.
  • the new process outputs “12” as result data.
  • the old process is stopped or deleted, and the process change is completed.
  • Patent Documents 1-4 Patent Document 1
  • Non-Patent Document 1 Patent Document 1
  • Patent Document 1 discloses a system using a reconfigurable device.
  • Patent Document 2 discloses a time-series data compression apparatus that performs two types of processing.
  • Patent Documents 3 and 4 disclose a processing apparatus that handles information to which a version number (updated version number) is added.
  • One of the functions required for process update is to identify whether the result of the process is the old process or the new process.
  • FIG. 29 is a block diagram illustrating a configuration of a time-series data processing device configured by combining the techniques of Patent Literature 2, Patent Literature 3, and Patent Literature 4.
  • the time-series data processing apparatus in FIG. 29 includes a processing unit 601 and a version comparison unit 611.
  • the processing unit 601 performs a user-defined process corresponding to the old process and a user-defined process corresponding to the new process, and outputs a process number and a version number that can uniquely identify the process added to the process result.
  • the version comparison unit 611 records the latest version number for each process. When the result data arrives, the version comparison unit 611 compares the latest version number recorded for each process with the version number added to the result data, thereby identifying the result of the old process and the result of the new process. . The version comparison unit 611 discards the result of the old process and externally outputs the result of the new process according to the identification result.
  • the processing result data “2”, the processing number “32767”, and the processing version number (updated version number) “65535” are output from the processing unit that has performed the new processing to the version comparison unit 611. .
  • processing result data “3”, the processing number “32768” that is a number assigned only to this processing, and the processing number from the processing unit that performed other processing not related to the new processing or the old processing is output to the version comparison unit 611.
  • the version comparison unit 611 uses the process number of the result data and retrieves it from the table in which the latest version number corresponding to the process number is recorded. Then, the latest version number is compared with the version number of the result data. The version comparison unit 611 determines that the result data is the result of the old process when the version number of the result data is older, and determines that the result data is the result of the new process when it is not old. With the above process, the result of the old process and the result of the new process are identified. Then, according to the identification result, the result of the old process can be discarded and the result of the new process can be output to the outside.
  • Non-Patent Document 1 discloses a time-series data processing apparatus capable of two types of processing, old processing and new processing.
  • mounting by software is assumed.
  • mounting is performed by hardware, and a configuration diagram thereof is shown in FIG.
  • Non-Patent Document 1 includes a processing unit 501 that performs a user-defined process corresponding to an old process and a user-defined process corresponding to a new process, and a merge unit 511 that connects a result of the processing unit to an output port to the outside.
  • Non-Patent Document 1 operates in two types. The operation according to the first method will be described with reference to FIGS.
  • the old process that takes the sum of the latest two values is changed to the new process that takes the sum of the last three values.
  • Both the old and new processes generate results in the same cycle as the data was entered.
  • the processing result reaches the merging unit 511 from the processing unit 501 in one cycle.
  • the processing result reaches the outside of the apparatus from the merge unit 511 in one cycle.
  • data is input every cycle, and the description will be made using time in units of one cycle.
  • time series data “1” is input at the start of the first cycle and time series data “2” is input at the start of the second cycle. Since the old process has obtained [1, 2] which are the latest binary values, the processing unit 501 calculates and outputs the result “3”. At the end of the second cycle, each part is in a state as shown in FIG.
  • the contents of the new process are specified and the execution starts.
  • the definition of the content of the new process is performed by, for example, a partial reconfiguration function when the apparatus that realizes the process is an FPGA. Further, it is assumed that the time series data 3 is input to the old and new processing. The old process outputs the result “5”. In the new process, the time series data “3” is stored. As a result of the old process, “3” is output to the outside of the apparatus.
  • each part is in a state as shown in FIG.
  • time series data “4” is input to the old and new processing at the start of the fourth cycle.
  • the old process outputs the result “7”.
  • the time series data “4” is stored.
  • “5” is output to the outside of the apparatus.
  • each part is in a state as shown in FIG.
  • time series data “5” is input to the old and new process at the start of the fifth cycle.
  • the old process outputs the result “9”. Since the new process has obtained [3, 4, 5] which are the latest three values, the result “12” which is the sum of the three values is output.
  • the result “7” of the old process is output outside the apparatus.
  • each part is in a state as shown in FIG.
  • time series data “6” is input to the old and new processing at the start of the sixth cycle.
  • the old process outputs the result “11”.
  • the new process outputs the result “15”.
  • the old process result “9” and the new process result “12” are output to the outside of the apparatus.
  • each part is in a state as shown in FIG.
  • the results of both the old and new processes are mixedly output to the outside of the apparatus.
  • time-series data “1” is input at the start of the first cycle. It is assumed that time series data “2” is input at the start of the second cycle. Since the old process has obtained [1, 2] which are the latest binary values, the processing unit 501 calculates and outputs the result “3”. At the end of the second cycle, each part is in a state as shown in FIG.
  • time series data “4” is input to the old and new processing at the start of the fourth cycle.
  • the time series data “4” is stored.
  • each part is in a state as shown in FIG.
  • the result is not output to the outside of the apparatus at this timing.
  • the result is output as shown in FIG.
  • time series data “5” is input to the old and new process at the start of the fifth cycle. Since the new process has obtained [3, 4, 5] which are the latest three values, the result “12” is output. At the end of the fifth cycle, each part is in a state as shown in FIG. As described above, in the second method, the result is not output to the outside of the apparatus even at this timing. On the other hand, in the first method, the result is output as shown in FIG.
  • time series data “6” is input to the old and new processing at the start of the sixth cycle.
  • the new process outputs the result “15”.
  • each part is in a state as shown in FIG.
  • Patent Document 1 discloses a system using a reconfigurable device. However, Patent Document 1 does not mention a problem that occurs when a device configuration file (circuit information for configuring a predetermined circuit) is rewritten. Therefore, such a problem cannot be solved.
  • Patent Document 2 discloses a time-series data compression apparatus that performs two types of processing.
  • the apparatus of Patent Literature 2 applies one of two types of processing based on the result of a predetermined determination on the result of the preprocessing. And, it is not distinguished which process is applied to the final process result. Therefore, the result of each of the two types of processing cannot be determined.
  • Patent Documents 3 and 4 disclose a processing apparatus that handles information to which a version number (updated version number) is added.
  • the version number is used to determine whether the information to which the information is added is new or old, and update the information to new information. Therefore, since the information with the older version number is discarded, it cannot be used even if the information is useful.
  • Patent Document 2 Combining the technology of Patent Document 2 with Patent Document 3 or Patent Document 4, two types of processing, new processing and old processing, are performed on time-series data, and the result data is the one to which any processing is applied It is possible to determine whether or not. However, the determination is to determine whether the process is new or old, and the result data obtained by the old process cannot be used.
  • one of the functions necessary for the process update is to identify the result of the old process and the new process from the results of the processes simultaneously operating on one apparatus.
  • an identification function of the result of the old process and the new process can be realized.
  • the process using the additional information as described above includes a version number search using a process number and a comparison process, there is a problem that the process delay is large.
  • the version comparison unit compares two 16-bit version numbers. Since this comparison processing is an operation using 32-bit data, there is a problem that the delay time until the processing result is known is long.
  • Non-Patent Document 1 the results of both the old and new processing are mixed and output to the outside of the apparatus as shown in FIG.
  • the result data output in a mixed manner cannot be identified as the result of the new process or the old process. Therefore, there is a problem that the result data obtained by the old process before and after the process change cannot be used.
  • the result of the old process cannot be output until the designated timing because the result of the new process and the result of the old process are mixed at the junction.
  • the sum of [2, 3] and the sum of [3,4] cannot be output without being mixed with the result of the new process.
  • the second method of Non-Patent Document 1 has a problem in terms of effective use of the processing apparatus, in which old processing is executed as much as possible and the processing result is used to the maximum.
  • Non-Patent Document 1 mixes and outputs the processing result data without distinguishing whether it is a new process or an old process. Therefore, the technique of Non-Patent Document 1 has a problem that when the process is changed from the new process to the old process at the time of execution, the results of both the old and new processes are mixed and output to the outside of the apparatus.
  • Non-Patent Document 1 when starting a new process, the old process is stopped. For this reason, there is a problem that useful and usable results of the old process are not output to the outside of the apparatus.
  • the present invention has been proposed in view of such circumstances, and in the processing of time-series data, the results of both the old and new processing are mixed when the processing is changed from the first processing to the second processing.
  • the result of the old process before and after the process change can be output to the outside without being output to the outside, reducing the amount of additional information for identifying the result of the old process and the new process, and the old process and the new process
  • the time-series data processing device of the present invention executes first processing and outputs first result data, and first processing means that executes second processing and outputs second result data.
  • first processing means that executes second processing and outputs second result data.
  • the second processing means and an instruction to change the process are received from the outside, it is determined whether or not the first process can be stopped, and the first identification representing the state of the first process in the first result data Control for generating first result data set by adding information, and generating second result data set by adding second identification information indicating the state of the second processing to second result data Means and third identification information for designating the result data to be output to the outside.
  • the first identification information and the third The first result based on the comparison result with the identification information and the comparison result between the second identification information and the third identification information And over another set or the second result by selecting one of the data sets and outputs discard selection means and the other, characterized in that it comprises a.
  • the first processing means executes the first processing, outputs the first result data
  • the second processing means executes the second processing
  • the result data of 2 is output and an instruction to change the process is received from the outside
  • the first result data indicates the state of the first process.
  • the first result data set is generated by adding the identification information
  • the second result data set is generated by adding the second identification information indicating the state of the second processing to the second result data.
  • the third identification information designating the result data to be output to the outside is recorded, and when the first result data set or the second result data set arrives, the first identification information and the third Based on the comparison result with the identification information and the comparison result between the second identification information and the third identification information, the first result Characterized by discarding a set or second result data set while selects and outputs the other over data.
  • the storage medium for the time-series data processing program of the present invention includes a first processing unit for executing the first process and outputting the first result data, and a second process for executing the second process.
  • Control means for generating a set of one result data, adding second identification information representing the state of the second process to the second result data, and generating the second result data set;
  • the third identification information designating the result data to be recorded is recorded, and when the first result data set or the second result data set arrives, the first identification information is compared with the third identification information.
  • Selection means for selecting and outputting one of the first result data set or the second result data set and discarding the other based on the result and the comparison result between the second identification information and the third identification information When, It stores the program for making it function as.
  • both the first and second results are mixed and output to the outside of the apparatus.
  • the result of the old process before and after the process change can be output to the outside.
  • the amount of information added to the result data of the old and new processing can be reduced, and the time required for identifying the result of the old and new processing and selecting the result to be output and discarded can be shortened.
  • FIG. 3 is a block diagram illustrating an example of an internal configuration of a selection unit 121.
  • FIG. It is a figure which shows the example of the data structure of the group of result data.
  • FIG. 1 It is a figure which shows the state of the output data of each part at the time of completion
  • FIG. 1 It is a figure which shows the state of the output data of each part at the time of completion
  • FIG. It is a figure which shows the state of the output data of each part at the time of completion
  • FIG. 10 is a block diagram showing a configuration of a time-series data processing device configured by combining the techniques of Patent Documents 2-4. It is a figure which shows the state of the output data of each part of the time series data processing apparatus of FIG.
  • time-series data processing apparatus that processes time-series data
  • user-defined processing is executed in a plurality of areas on the IC chip, and arbitrary areas are changed to processes that perform different operations at the time of execution.
  • first user definition process the process before the change
  • second user definition process the process after the change
  • the process before the change may be referred to as “old process”
  • the process after the change may be referred to as “new process”.
  • the circuit information for executing the new process is written in an area different from the area of the circuit for executing the old process while the old process is operated, and the operation of the new process is started.
  • the process change is realized while shortening the period during which the result is not output.
  • partitions An example of such an IC chip is an FPGA.
  • FIG. 1 is a block diagram showing a configuration of a time-series data processing apparatus 100 according to an embodiment of the present invention.
  • the time-series data processing apparatus 100 includes a processing unit 101, a control unit 111, and a selection unit 121. 1
  • the processing unit 101 executes the old process and outputs the result data. Alternatively, the processing unit 101 executes the new process replaced when the old process is executed, and outputs the result data. Whether the process executed by the processing unit 101 is an old process or a new process depends on whether or not the process executed by the processing unit 101 is changed.
  • the functions and internal configurations of the plurality of processing units 101 may all be the same, or some or all may be different.
  • the control unit 111 sets “identification information” corresponding to the content of the processing performed by each processing unit 101. Differences in processing performed by the processing unit 101 can be identified based on differences in identification information.
  • the change from the old process to the new process may proceed simultaneously in a plurality of processing units. That is, the change from the first old process to the first new process in the first processing unit and the change from the second old process to the second new process in the second processing unit may proceed simultaneously. is there.
  • the first old process and the first new process are simultaneously operated on the time-series data processing apparatus 100. It can be distinguished from other processes including processes.
  • the timing of the instruction to change the process by the first processing unit from the outside and the timing of the instruction to change the process by the second processing unit are controlled so as not to coincide.
  • the change from the first old process to the first new process and the change from the second old process to the second new process do not proceed simultaneously.
  • the states of the first old process and the first new process can be represented by four types of identification information.
  • the four types of identification information are called “stable”, “transit-0”, “transit-1”, and “transit-2”, respectively.
  • “Stable” means result data when no process change has occurred, that is, result data of a process in which a pair of a new process and an old process has not occurred.
  • the processing unit returns to the initial state, that is, the state in which no change has occurred, so that the identification information of the result data is “stable”.
  • Transit-1 means that a process change is in progress. Since the result data corresponding to “transit-1” is in the middle of changing the process, it is the result data of the old process among the pair of the result data of the new process and the result data of the old process. “transit-1”, when recorded in the selection unit 121, specifies that the result data to be output is the result data of the old process.
  • transit-2 indicates that a process change is in progress, and the result data corresponding to "transit-2" is the result of the new process out of the pair of the new process result data and the old process result data.
  • Data which means result data instructed to be output to the outside of the apparatus.
  • the control unit 111 adds identification information to the result data at the timing when the processing unit 101 outputs the result data, and outputs the result data to the selection unit 121. Since the identification information added to the result data can take all the above four types, it is expressed by 2 bits.
  • the 2-bit identification information can be realized by two wirings whose logic level is controlled by the control unit 111, two flip-flops whose holding value is controlled by the control unit 111, or the like.
  • N and M are 65,536, the number of bits of information added as a whole apparatus by the method combining this embodiment and Patent Literature 2-4 will be 131,072, 2,097,152, respectively.
  • the amount of information to be added is greatly reduced.
  • the selection unit 121 receives a set of result data and identification information added in association with the result data from the plurality of processing units 101 and the control unit 111. Identification information is registered in the selection unit 121 in advance. The selection unit 121 performs switching to the operation using the received identification information and the identification information registered in the selection unit 121. Operation switching is an operation that outputs the result data of the old process to the outside and discards the result data of the new process, to the action of discarding the result data of the old process and outputting the result data of the new process to the outside. It is a switch. When the result data is output, the identification information added to the output result data may also be output to the outside. Then, the selection unit 121 records an event that the result data of the new process is output for the first time after the processing of a certain processing unit 101 is switched to the new process, using the identification information recorded in the selection unit 121. .
  • the identification information recorded and used in the selection unit 121 is only two types of “transit-1” or “transit-2” as will be described later, it can be expressed by one bit.
  • the 1-bit identification information can be realized by one wiring whose logic level is controlled by the control unit 111 or one flip-flop whose holding value is controlled by the control unit 111.
  • 1-bit identification information is recorded in the selection unit 121. Therefore, when N processes operate simultaneously in parallel in the time-series data processing apparatus 100, 1-bit information is stored in the selection unit.
  • N and M are 65,536, the number of bits of information additionally recorded by the method combining this embodiment and Patent Literature 2-4 is 1,1,048,576, respectively.
  • the amount of additional information recorded is greatly reduced.
  • an operation is performed using the identification information added to the result data and the identification information stored in the selection unit.
  • the time-series data processing apparatus 100 when N processes operate simultaneously in parallel, for the purpose of identifying the type of process, that is, for identifying the processing unit 101 that performed the process,
  • the selection unit 121 an operation using the identification information is added.
  • the selection unit 121 performs a process related to the version number and a process related to the process number, that is, an operation with 2 + 1 bits as input.
  • N and M are 65,536, the required number of input bits for the operation is 3 and 32 by the method combining this embodiment and Patent Literature 2-4, respectively.
  • the number of input bits for the operation is greatly reduced, so that the time required for the operation is greatly shortened.
  • the control unit 111 outputs identification information in accordance with the output of the result data of the processing unit 101.
  • the input information to the selection unit 121 is a set of result data output from the processing unit 101 and identification information added by the control unit.
  • the information set may have a configuration as shown in FIG.
  • the above-mentioned information set including the result data and the identification information is handled as an integrated one, it is referred to as “result data set”.
  • FIG. 2 is a block diagram illustrating an example of the internal configuration of the selection unit 121.
  • the selection unit 121 includes an input port, an output port, a waiting data queue 1001, and an arbitration unit 1002.
  • the selection unit 121 uses the arbitration unit 1002 to perform arbitration of output port allocation for a pair of result data received from the two input ports and the waiting data queue 1001.
  • the result data set to which the output port is assigned is output to the output port.
  • a result data set to which no output port is assigned is discarded or inserted into the waiting data queue 1001.
  • the data inserted in the waiting data queue 1001 is input to the selection unit 121 again in the next cycle.
  • FIG. 4 the operation of the time-series data processing apparatus 100 according to this embodiment will be described with reference to FIGS. 4, 5, and 6.
  • FIG. 4 the operation of the time-series data processing apparatus 100 according to this embodiment will be described with reference to FIGS. 4, 5, and 6.
  • a period before a new input arrives and a next input arrives is referred to as “one input period”.
  • a clock cycle that defines a unit time required for the time-series data processing device to complete a predetermined operation is referred to as “one cycle”.
  • a circuit for executing user-defined processing can be created by setting configuration data and setting information called configuration data in the partition.
  • command and “instruct” mean that a part (referred to as “command source part”) operates a signal of a wiring connected to another part (referred to as “command target part”). Or writing a value to a storage device existing in the command destination part.
  • command source part operates a signal of a wiring connected to another part (referred to as “command target part”). Or writing a value to a storage device existing in the command destination part.
  • Register”, “set”, and “record” mean that a part of a registration source writes a value in a storage device that exists in another part of the registration destination.
  • Send information”, “Send data”, “Output result” means the signal of the wiring that is connected to another part of the device where one part of the device that is the source is the destination This means that an operation is performed or a value is written in a storage device existing in the destination part.
  • the result data output from the time-series data processing device 100 is changed from the old process to the new process.
  • This change is permitted by a process change instruction (hereinafter referred to as “process change instruction”) to the time-series data processing apparatus 100 by a host computer or the like (not shown).
  • process change instruction a process change instruction
  • a host computer or the like not shown.
  • control unit 111 sets the identification information of all the processing units 101 to “stable”, and sets the identification information recorded in the selection unit 121 to “transit-1” (step S1001). ).
  • control unit 111 at a timing before writing the circuit information for executing the new process in the area different from the area where the circuit information for executing the old process is written in the processing unit 101.
  • the identification information of the old process is set to “transit-1” (step S1002).
  • control unit 111 sets the identification information of the new process to “transit-0” at the timing of writing the circuit information for executing the new process to the processing unit 101 (step S1003).
  • control unit 111 determines whether or not the old process can be stopped, and sets the identification information of the new process to “transit-2” if applicable (step S1004).
  • the “state where the old process can be stopped” refers to a state where the operation of the processing unit 101 that executes the old process can be stopped and the output of the result data can be stopped.
  • the result data output from the time-series data processing device 100 can be changed from the result data by the old process to the result data by the new process.
  • the result data output from the time-series data processing apparatus 100 is not immediately changed to result data by the new process.
  • the time-series data processing apparatus 100 receives the process change instruction and reaches the state where the old process can be stopped, the result data output from the time-series data processing apparatus 100 is changed to the result data by the new process. .
  • the old processing may be It cannot be stopped. In this case, the output of the result data of the old process is continued from the time-series data processing apparatus 100.
  • the subject that instructs the setting of identification information or gives a value may be a host computer (not shown).
  • the main body may be the control unit 111.
  • control unit 111 stops the old process in the processing unit 101 (step S1005).
  • control unit 111 sets the identification information of the new process to “stable” at the timing when the result data of the old process no longer exists in the time-series data processing apparatus 100 (step S1006).
  • control unit 111 sets the identification information recorded in the selection unit 121 to “transit-1” and returns to step S1002 ( Step S1007).
  • control unit 111 performs the process shown in the flowchart of FIG. That is, the control unit 111 sends the result data set to the selection unit 121 and returns to step S1201 (step S1201).
  • the selection unit 121 performs the processing shown in the flowchart of FIG. That is, the selection unit 121 records the recorded identification information when the set of result data whose identification information is “transit-2” arrives and the recorded identification information is “transit-1”. Is updated to “transit-2” (step S1301).
  • the selection unit 121 discards the set of arrival result data whose identification information is “transit-0”.
  • the selection unit 121 discards the arrived result data set whose identification information is “transit-1” (step S1302).
  • the selection unit 121 arbitrates the right to use the output port to the outside of the apparatus among the arrived result data sets that have not been discarded. Then, what can acquire the right to use the output port is transferred to the output port and output to the outside of the apparatus, and what is not acquired is inserted into the waiting data queue, and the process returns to step S1301 (step S1303).
  • the “waiting data queue” is a queue into which the selection unit 121 inserts a set of result data that has not been discarded and output.
  • the set of result data stored in the waiting data queue is taken out of the waiting data queue in the next cycle and is considered to have arrived at the selection unit 121.
  • “arbitration of the right to use the output port” It means the act of selecting one data that can use the output port. When data is selected in this mediation, it is said that “data has acquired a port”.
  • FIG. 7 shows identification information and output data in each state of the time-series data processing apparatus 100.
  • the identification information of the result data of all processes is set to “stable”, and the identification information recorded in the selection unit 121 is set to “transit-1”. With the above settings, the result data of all processes is output from the selection unit 121 to the outside of the apparatus.
  • the identification information of the result data of the old process is changed to “transit-1”. Also, the identification information of the result data of the new process is changed to “transit-0”. However, the identification information recorded in the selection unit 121 remains “transit-1” and is not changed. With the above settings, the selection unit 121 continues to discard the result data of the new process.
  • the identification information of the result data of the new process is changed to “transit-2”, and the identification information recorded in the selection unit 121 is changed from “transit-1” to “transit-1”. changed to transit-2 ".
  • the result data of the old process is continuously discarded by the selection unit 121.
  • the time-series data processing device 100 of FIGS. 8 to 16 includes four processing units 101.
  • the processing unit in charge of executing the old process is referred to as a processing unit 101-1
  • the processing unit in charge of executing the new process is referred to as a processing unit 101-2.
  • the processing unit 100 is described.
  • the process of calculating the sum of four values (referred to as “old process”) is changed to the process of subtracting “2” from the input value (referred to as “new process”). Think about changing.
  • both new processing and old processing are realized by writing circuit information for executing each processing into a reconfigurable circuit element such as an FPGA and then operating the circuit.
  • a reconfigurable circuit element such as an FPGA
  • the method for realizing the new process and the old process is not limited to the method realized by hardware as described above. That is, as described above, a software method of causing a processor included in the processing unit 101 to execute a program may be used. In the implementation method using software, the following “circuit information” may be replaced with “program”.
  • the process is changed in the following steps.
  • (1) The circuit information for executing the new process is written in an area different from the area where the circuit information for executing the old process is written.
  • the circuit information for executing the old process is deleted.
  • the old process can be stopped, the output of the old process result data is stopped, and the timing to start outputting the new process result data is given from the old process processing unit 101-1 to the control unit 111.
  • the timing is assumed to be several cycles after the writing of the circuit information for executing the new process to the processing unit 101-2 of the new process is completed and the new process starts outputting the result. That is, the result of the old process can be used for several cycles even after the new process starts outputting the result. Therefore, by making it possible to output the result of this available old process, it can be used effectively.
  • the device that executes the new process and the old process may be an FPGA.
  • the destination to which the time-series data processing apparatus 100 outputs the result may be a host computer.
  • the old process may be realized by writing necessary circuit information into the FPGA using the reconfiguration function of the FPGA when the apparatus that executes the process is an FPGA.
  • the cycle of the clock used for the operation of the time-series data processing device is called “cycle”, and this is used as a unit of period.
  • “At the start of the cycle” means the first time of the period
  • “at the end of the cycle” means the last time of the period.
  • the frequency of the clock is 1 GHz
  • the first cycle for a certain reference time is a period between the reference time plus zero seconds and the reference time plus 1 nanosecond
  • the Nth cycle is the reference time plus (N ⁇ 1 ) Means the period from nanoseconds to the reference time plus N nanoseconds.
  • the start of the Mth cycle means a reference time plus (M ⁇ 1) nanoseconds
  • the end of the Mth cycle means a reference time plus M nanoseconds.
  • Input data is given at the start of each cycle.
  • the result data calculated by the processing unit 101 is added with identification information by the control unit 111 and sent to the selection unit 121.
  • control unit sets the identification information of all the processing units to “stable”, and sets the identification information recorded in the selection unit to “transit-1” (step S1001).
  • FIG. 8 shows the output information inside the time-series data processing apparatus 100 at this point, that is, the result data set sent from the processing unit 101-1 to the selection unit 121.
  • the result data set of the old process arrives at the selection unit 121. Since the identification information of the result data set is not “transit-2”, the selection unit 121 does not update the recorded identification information (step S1301).
  • the selection unit 121 does not discard the result data (step S1302).
  • the selection unit 121 arbitrates the output port to the outside of the apparatus for this one result data set. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set to the output port to the outside of the apparatus (step S1303).
  • control unit 111 sets the identification information of the old process to ⁇ transit-1> as preparation for writing circuit information for executing the new process (step S1002).
  • the input data “5” is given to the processing unit 101-1 that executes the old process, and the control unit 111 outputs ⁇ 14, transit-1> to the selection unit 121.
  • FIG. 9 shows output information inside the time-series data processing device 100 at the end of the fifth cycle.
  • the result data set of the old process arrives at the selection unit 121. Since the identification information of the result data set is not “transit-2”, the selection unit 121 does not update the recorded identification information (step S1301).
  • the selection unit 121 does not discard this (step S1302).
  • the selection unit 121 arbitrates the output port to the outside of the apparatus for the result data set that has not been discarded. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the old process to the output port to the outside of the apparatus (step S1303).
  • control unit 111 sets the identification information of the new process to “transit-0” (step S1003).
  • the input data “6” is given to the processing units 101-1 and 101-2.
  • the processing unit 101-1 and the control unit 111 select the result data set ⁇ 18, transit-1>, and the processing unit 101-2 and the control unit 111 select the result data set ⁇ 4, transit-0>. Output to.
  • FIG. 10 shows output information inside the time-series data processing device 100 at the end of the sixth cycle.
  • the selection unit 121 receives two sets of result data, the new process and the old process.
  • the selection unit 121 does not update the recorded identification information because neither of the identification information of the result data set is “transit-2” (step S1301).
  • the selection unit 121 sets the result data set of the old process. Do not discard. On the other hand, since the identification information of the new process result data set is “transit-0”, the selection unit 121 discards the new process result data set (step S1302).
  • the selection unit 121 arbitrates the output port to the outside of the apparatus between the result data sets that are not discarded. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the old process to the output port to the outside of the apparatus (step S1303). This operation avoids the problem that the results of the old process and the new process are mixed and output outside the apparatus. In addition, since the useful result data of the old process is output to the outside of the apparatus without being discarded, the result data can be used effectively.
  • the processing unit 101-1 and the control unit 111 send the result data set ⁇ 22, transit-1> to the selection unit 121, and the processing unit 101-2 and the control unit 111 send the result data set ⁇ 5, transit-0. > Is sent to the selection unit 121.
  • FIG. 11 shows output information inside the time-series data processing device 100 at the end of the seventh cycle.
  • the selection unit 121 does not update the recorded identification information because neither of the identification information of the result data set is “transit-2” (step S1301).
  • the selection unit 121 sets the result data set of the old process. Do not discard. On the other hand, since the identification information of the new process result data set is “transit-0”, the selection unit 121 discards the new process result data set (step S1302).
  • the selection unit 121 arbitrates the output port to the outside of the apparatus for the result data set that has not been discarded. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the old process to the output port outside the apparatus (step S1303).
  • step S1004 the processing unit 101-1 and the control unit 111 output the result ⁇ 26, transit-1>, and the processing unit 101-2 and the control unit 111 output the result ⁇ 6, transit-2>.
  • FIG. 12 shows output information inside the time-series data processing device 100 at the end of the eighth cycle.
  • the selection unit 121 updates the recorded identification information to “transit-2” because the recorded identification information is “transit-1” and the identification information of the result data set of the new process is “transit-2”. (Step S1301).
  • the selection unit 121 since the recorded identification information is “transit-2” and the identification information of the new processing result data set is “transit-2”, the selection unit 121 does not discard the new processing result data. (Step S1302). On the other hand, since the identification information of the result data set of the old process is “transit-1”, the selection unit 121 discards the result data set of the old process. Arbitrate the output port to the outside of the device for the data set. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the new process to the output port to the outside of the apparatus (step S1303). This operation avoids the problem that the results of the old and new processing are mixed and output to the outside of the apparatus.
  • the result of the old process is not output to the output port to the outside of the apparatus, and the result of the new process is output instead.
  • the result data output to the outside of the apparatus can be smoothly switched from the result data of the old process to the result data of the new process.
  • control unit 111 stops the old process by the processing unit 101-1 (step S1005).
  • FIG. 13 shows output information inside the time-series data processing device 100 at the end of the ninth cycle.
  • the selection unit 121 receives a new processing result data set. Since the recorded identification information is not “transit-1”, the selection unit 121 does not update the recorded identification information (step S1301). Furthermore, since the identification information recorded is “transit-2” and the identification information of the result data set of the new process is “transit-2”, the selection unit 121 sets the result data set of the new process. It is not discarded (step S1302). Here, the selection unit 121 arbitrates an output port to the outside of the apparatus for a set of result data that has not been discarded. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the new process to the output port outside the apparatus (step S1303).
  • control unit 111 sets the identification information of the new process to “stable” (step S1006).
  • FIG. 14 shows output information inside the time-series data processing device 100 at the end of the tenth cycle.
  • the selection unit 121 receives a new processing result data set. Since the recorded identification information is not “transit-1”, the selection unit 121 does not update the recorded identification information (step S1301). Furthermore, since the identification information of the result data set of the new process is “stable”, the selection unit 121 does not discard the result data set of the new process (step S1302). Here, the selection unit 121 arbitrates an output port to the outside of the apparatus for a set of result data that has not been discarded. Since the output port is acquired by the arbitration, the selection unit 121 transfers the result data set of the new process to the output port to the outside of the apparatus (step S1303).
  • FIG. 15 shows output information inside the time-series data processing device 100 at the end of the eleventh cycle.
  • the selection unit 121 transfers the result data set of the new process to the output port to the outside of the apparatus, as in the previous cycle.
  • the control unit 111 sets the identification information recorded in the selection unit 121 to “transit-1” (step S1007).
  • FIG. 16 shows output information inside the time-series data processing device 100 at the end of the twelfth cycle.
  • the selection unit 121 continues to output the result data set of the new process to the output port to the outside of the apparatus.
  • a set of result data output from the time-series data processing device 100 is expressed as a column in ascending order of time, ⁇ 10, stable> ⁇ 14, transit-1> ⁇ 18, transit-1> ⁇ 22, transit-1 ⁇ ⁇ 6, transit-2 ⁇ ⁇ 7, transit-2 ⁇ ⁇ 8, stable>.
  • the old and usable old information can be used until the time at which the old process can be stopped in the processing unit 101-1.
  • the processing result data is output outside the apparatus without being discarded.
  • ⁇ 18, transit-1> and ⁇ 22, transit-1> correspond to useful and usable old process result data.
  • Non-Patent Document 1 since the old process is stopped at the time of writing the new process, this useful and usable result is not output. Also, the techniques of Patent Documents 1-4 are not particularly considered to output useful and usable old process result data.
  • the result of the useful and usable old process that was not output by the method of the background art is output to the outside of the apparatus to the maximum extent.
  • the result data of the old process is discarded, and the result data output from the processing unit 101-2 that executes the new process is output to the outside of the apparatus instead. That is, before and after the process change, the results of both the old process and the new process are not mixed and output outside the apparatus.
  • the process is changed from the old process to the new process at the time of execution, the amount of information added to the result data can be suppressed to 2 bits per processing unit 101 as compared with the technology of the background art.
  • the amount of calculation for selecting the result data output from the time series data device can be reduced. That is, the calculation using the identification information of the set of result data and the identification information stored in the selection unit 121 in the selection unit 121 can be suppressed to the calculation using the 2 + 1 bit identification information as an input.
  • the calculation amount may be enormous as described above.
  • the amount of calculation of the selection unit 121 can be reduced, the processing delay time as the time-series data device can be shortened.
  • the time series data processing apparatus of this embodiment can also be realized by software.
  • the flowchart of the program for controlling the time-series data processing apparatus is the same as that shown in FIGS. That is, the processing performed by the control unit 111 and the selection unit 121 may be realized by a processor included in the time-series data processing device executing a program.
  • the above program may be stored in a non-transitory medium such as a ROM (Read Only Memory), a RAM (Random Access Memory), a semiconductor storage device such as a flash memory, an optical disk, a magnetic disk, or a magneto-optical disk.
  • a non-transitory medium such as a ROM (Read Only Memory), a RAM (Random Access Memory), a semiconductor storage device such as a flash memory, an optical disk, a magnetic disk, or a magneto-optical disk.
  • the target period for obtaining the average value is changed in an application for calculating the average value of the numerical values.
  • an application that detects an emergency including a fire by taking the values of temperature sensors distributed over a wide range as input data and taking an average over a certain period.
  • a function of shortening the length of the target period in which the temperature is averaged can be realized in order to increase the speed of following the temperature change.
  • an application for changing parameters or output information used for a certain calculation For example, consider an application that calculates an index for determining the timing of buying and selling financial products such as stock certificates. First, there are a plurality of necessary indicators depending on the brand of the financial product to be traded and the trading strategy, and the set of indicators to be output is different. Some devices can calculate only a finite number of indices simultaneously. The brands and strategies to buy and sell change according to the time. Therefore, it is possible to realize the function of changing the calculated index according to the brand to be traded at that time and the trading strategy.

Abstract

処理の変更時に、新旧処理の両方の結果が混在して外部に出力されず、処理の変更前後の旧処理の結果を外部に出力することができ、またこの実現のための付加情報の量と付加処理の遅延を削減する、時系列データ装置を提供する。 第1の処理を実行して第1の結果データを出力する第1の処理手段と、第2の処理を実行して第2の結果データを出力する第2の処理手段と、処理変更指示を受けたとき、第1の処理が停止可能か否かを判断し、第1、第2の結果データのそれぞれに処理の状態を表す第1、第2の識別情報を付加して第1、第2の結果データの組を生成する制御手段と、外部へ出力すべき結果データを指定する第3の識別情報を記録し、第1又は第2の結果データの組が到着したとき、第1、第2、第3の識別情報との比較結果に基づいて、第1又は第2の結果データの組の一方を選択して出力し他方を破棄する選択手段と、を備える。

Description

時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムの記憶媒体
 本発明は、時系列データを処理する時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムに関する。特に、時系列データに対する処理の内容が変化する時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムに関する。
 まず、「時系列データに対するデータ処理」について説明する。本明細書において、「時系列データに対するデータ処理」とは、時系列入力データ、すなわち、次々と入力される一連のデータに対して行われる処理をいう。時系列データに対するデータ処理の結果データも、同様に次々と出力される。「次々と入力される」とは、複数のデータがある期間にわたってそれぞれ異なるタイミングで処理装置に到着する、という意味である。時系列データに対するデータ処理の例として、時系列データの直近の2つの値の和を取る、といった処理が挙げられる。以降、時系列データに対するデータ処理を、単に、「時系列データ処理」という。
 以下の説明においては、データの配列を、[1,2,3,4]のように表し、データの集合を、{1,2,3,4}のように表し、データの組を<10度,1月1日>のように、括弧の種類によって区別して表す。また、1、2のような、個々のデータの数値は、”1”、”2”のように表記し、構成要素を示す符号と区別する。
 また、時系列データ処理装置の動作に用いられるクロックの周期を「サイクル」といい、これを期間の単位として用いる。「サイクルの開始時」とは、その期間の最初の時点を意味し、「サイクルの終了時」とは、その期間の最後の時点を意味する。例えば、クロックの周波数が1GHzである場合は、ある基準時刻について第1サイクルは、基準時刻プラスゼロ秒から基準時刻プラス1ナノ秒の間の期間を、第Nサイクルは基準時刻プラス(N-1)ナノ秒から基準時刻プラスNナノ秒の期間を意味する。第Mサイクルの開始時は、基準時刻プラス(M-1)ナノ秒を意味し、第Mサイクルの終了時は、基準時刻プラスMナノ秒を意味する。
 ここで、入力データは1つ以上の値からなる組である。例として、温度と日付の組、温度のみの組、銘柄と株価と時刻の組、が挙げられる。例えば、温度と日付の組を<10度,1月1日>のように表す。入力データと、装置で扱われる値を、それらが混同されるおそれがない場合は、単に「データ」という。
 時系列データ処理は、複数の入力データに対して行われることが多い。さらに、時系列データ処理は、時系列データのウィンドウに対して行われることが多い。「ウィンドウ」とは、入力データの集合であり、2種類ある。一つは、予め決められた数をN(Nは1以上の整数)として、直近のN個の入力データの集合である。もう一つは、ある決められた時刻の期間をPとして、入力データの組の1要素を時刻とみなして、その期間に収まる入力データの集合である。
 例えば、温度と日付の組を入力データとし、<10度、1月1日>、<11度、1月2日>、<10度、1月3日>、<10度、1月4日>という時系列データが与えられたとする。1月4日から過去3日間にわたる期間に収まるウィンドウは、{<11度、1月2日>,<10度、1月3日>,<10度、1月4日>}である。
 また、ウィンドウ内の入力データの集合、部分集合、要素を「ウィンドウデータ」という。時系列データ処理では、このウィンドウデータが記憶されることが多い。以下の説明では、ウィンドウあるいはウィンドウデータを配列あるいは集合として表す。
 時系列データ処理を、処理の内容を規定することができる領域(以降、「パーティション」という。)、具体的には、処理を実行する回路を構成するための回路情報等を書き込むことができる領域を複数持つIC(Integrated Circuit)チップを用いて実行するものとする。このようなICチップの例として、FPGA(Field Programmable Gate Array)が挙げられる。あるいは、ICチップとして、メモリからプログラムを読み込んで実行するプロセッサを使用して、時系列データ処理を実行することもできる。この場合は、メモリに処理内容、すなわち、処理の手順を指定するプログラムを書き込めばよい。
 時系列データ処理において、第1のユーザ定義処理(「旧処理」という。)を、第2のユーザ定義処理(「新処理」という。)に変更したいというニーズが存在する。すなわち、ICチップ上の第1のパーティションでは第1のユーザ定義処理(「旧処理」という。)を実行する。そして、第1のユーザ定義処理実行時に第2のパーティションに第2のユーザ定義処理(「新処理」という。)を実行する回路情報を書き込んで新処理を実行して、旧処理を停止する。このようにして、旧処理を新処理に変更したいというニーズが存在する。
 例として、広い範囲に分散配置された温度センサの値を入力データとし、ある期間の平均を取って、火事を含む緊急事態を検知するアプリケーションを考える。温度変化が激しくなってきたときに、温度変化に追従する速度を高めるために、温度の平均を取る対象期間の長さを短縮する、というニーズがある。
 また、株券など金融商品の売買のタイミングを決めるための指標を計算するアプリケーションを考える。売買する金融商品の銘柄と売買戦略に応じて、必要な指標は複数存在し、出力すべき指標の集合は異なる。ある装置は、有限数の指標しか同時に計算できない。時刻に応じて売買する銘柄と戦略は変化する。そのため、そのとき売買する銘柄と売買戦略に応じて、算出する指標を変化させたい、というニーズがある。
 図17を用いて、背景技術における、処理の変更の例を説明する。本例では、直近の2値の和を取る旧処理を、直近の3値の和を取る新処理に変更する。
 また、1サイクルごとにデータが入力されるものとし、1サイクルを単位とする時刻を用いて説明する。
 第1サイクルの開始時に、時系列データ1が入力され、旧処理がその値をウィンドウデータとして保存する。
 第2サイクルの開始時に、時系列データ2が入力され、旧処理がその値をウィンドウデータとして保存する。また、旧処理が、直近の2値が手に入ったため、結果データとして”3”を出力する。
 第3サイクルの開始時に、新処理への変更指示が与えられる。また、新処理を実行するための情報が装置に書き込まれ、動作を開始したとする。例えば、FPGAの一部の領域に新処理を実行する回路情報が書き込まれたとする。ここで、旧処理を実行する回路情報とは別に新処理を実行する回路情報が書き込まれ、旧処理と新処理がしばらくの間並行に動作するものとする。
 第3サイクルの開始時に、時系列データ”3”が入力され、新処理がその値をウィンドウデータとして保存する。
 第4サイクルの開始時に、時系列データ”4”が入力され、新処理がその値をウィンドウデータとして保存する。
 第5サイクルの開始時に、時系列データ”5”が入力され、新処理がその値をウィンドウデータとして保存する。また、新処理が、直近の3値が手に入ったため、結果データとして”12”を出力する。
 ここで、旧処理を停止あるいは削除して、処理の変更が完了する。
 ここで、処理の変更の際に、(1)新処理と旧処理の両方の結果が混在して装置外部への出力されないようにしつつ、両方の処理を行いたい。(2)さらに、処理の変更の前後の旧処理の結果のうち、まだ有用で利用可能なものを装置外部に出しつつ両方の処理を行いたい、というニーズが存在する。
 例として、上記の、ある期間の温度センサの値の平均を取って、火事を含む緊急事態を検知するアプリケーションを考える。このとき、温度変化が激しくなってきたときに、温度変化に追従する速度を高めるために、温度の平均を取る期間の幅を変えることが望ましい。また、旧処理、新処理の結果が混同されないように、両方の結果が混在して装置外部に出力されないように処理を変更することも必要である。さらに、旧処理の結果も依然有用で利用可能であるため、新処理の結果が装置外部に出力されるまでの間、旧処理の結果をなるべく多く装置から受け取ることが望ましい。以上のようなニーズが存在する。
 もう一つの例として、株券など金融商品の売買の指令を行うアプリケーションを考える。売買する銘柄を変えたいため、売買指示の処理を変える必要がある。変更前の銘柄を「旧銘柄」、変更後の銘柄を「新銘柄」という。また、処理の変更の前後で新旧銘柄に関する指示が混在すると、売買を誤る恐れがある。そのため、新旧処理両方の結果が混在して装置外部に出力されないように、処理の変更を行う必要がある。また、旧銘柄に対して、最後のタイミングまで売買指示が行われるかもしれないため、新処理の結果が装置外部に出力されるまでの間、旧処理の結果をなるべく多く装置から受け取ることが望ましい。以上のようなニーズが存在する。
 さらに、このアプリケーションでは、処理の変更の過程で、安全な状態になってから旧処理を停止したいというニーズがある。例えば、売りの指令を出したら、買いの指令を出すまで旧処理の指示を出させるようにしておいて、それから新処理の指示だけを出させるようにしたい場合がある。すなわち、(1)停止可能な状態になっていない旧処理から出力された結果の列は有用で利用可能であるため装置外部に出力させ、(2)その後、停止可能な状態になった旧処理から出力された結果の列は、新処理から出力された結果の列で置き換えて装置外部に出力させる、というニーズが存在する。
 以上のような処理に関連する技術が、特許文献1-4、非特許文献1に記載されている。
 特許文献1には、再構成可能デバイスを用いたシステムが開示されている。
 特許文献2には、2種類の処理を行う時系列データ圧縮装置が開示されている。
 特許文献3、4には、バージョン番号(更新版数)が付加された情報を取り扱う処理装置が開示されている。
 処理の更新に必要な機能の一つは、処理の結果が旧処理と新処理のいずれによるものであるかを識別することである。特許文献2-4の技術を組み合わせることで、時系列データに対して新処理、旧処理の2種類の処理を行い、旧処理の結果と新処理の結果を識別することは可能である。
 特許文献2-4の技術を組み合わせて旧処理の結果と新処理の結果を識別する方法について、詳しく説明する。図29に、特許文献2、特許文献3、特許文献4の技術を組み合わせて構成された時系列データ処理装置の構成を示すブロック図を示す。図29の時系列データ処理装置は、処理部601とバージョン比較部611を備える。
 処理部601は、旧処理に対応するユーザ定義処理及び新処理に対応するユーザ定義処理を行い、処理を一意に識別できる処理番号とバージョン番号を、処理の結果に付加して出力する。
 バージョン比較部611は、処理ごとに最新のバージョン番号を記録する。バージョン比較部611は、結果データが到着すると、記録されている処理ごとの最新のバージョン番号と結果データに付加されたバージョン番号を比較することで、旧処理の結果と新処理の結果を識別する。そして、バージョン比較部611は、識別結果に従って、旧処理の結果の破棄と、新処理の結果の外部出力を行う。
 図30を用いて、図29の時系列データ処理装置の動作を説明する。旧処理を行った処理部から、処理の結果データ“1”、旧処理と新処理に共通の番号で、旧処理と新処理の結果を他の処理の結果から一意に識別できる番号である処理番号“32767”、及び処理のバージョン番号(更新版数)“65534”が、バージョン比較部611に出力される。これを、〈結果、処理番号、バージョン番号〉という形式で表す。
 また、新処理を行った処理部から、処理の結果データ“2”、上記の処理番号“32767”、及び処理のバージョン番号(更新版数)“65535”が、バージョン比較部611に出力される。
 また、新処理にも旧処理にも関係しないその他の処理を行った処理部から、処理の結果データ“3”、この処理にのみ割り当てられている番号である処理番号“32768”、及び処理のバージョン番号(更新版数)“65535”が、バージョン比較部611に出力される。
 バージョン比較部611は、結果データの処理番号を用いて、その処理番号に対応する最新のバージョン番号を記録している表から取り出す。そして、その最新バージョン番号と結果データのバージョン番号を比較する。バージョン比較部611は、結果データのバージョン番号の方が古い場合には結果データは旧処理の結果であると判断し、古くない場合には結果データは新処理の結果であると判断する。以上の処理によって、旧処理の結果と新処理の結果が識別される。そして、識別結果に従って、旧処理の結果を破棄し、新処理の結果を外部に出力することができる。
 非特許文献1には、旧処理と新処理の2種類の処理が可能な時系列データ処理装置が開示されている。非特許文献1では、ソフトウェアによる実装が想定されているが、便宜上、ハードウェアによって実装したと想定し、その構成図を図18に示す。
 非特許文献1の技術は、旧処理に対応するユーザ定義処理及び新処理に対応するユーザ定義処理を行う処理部501、処理部の結果を外部への出力ポートへ接続する合流部511を備える。
 非特許文献1の技術は大きく分けて2種類の方法で動作する。図19から図23を用いて、第1の方法による動作を説明する。
 本例では、直近の2値の和を取る旧処理を、直近の3値の和を取る新処理に変更する。新旧処理の両方とも、データを入力したのと同じサイクルに結果を生成する、とする。また、処理の結果は処理部501から合流部511へ1サイクルで到達するものとする。また、処理の結果は合流部511から装置外部へ1サイクルで到達するものとする。また1サイクルごとにデータが入力されるものとし、1サイクルを単位とする時刻を用いて説明する。
 第1サイクルの開始時に時系列データ”1”、第2サイクルの開始時に時系列データ”2”が入力されたとする。旧処理は直近の2値である[1,2]を得たため、処理部501が結果”3”を計算し出力する。第2サイクルの終了時に、各部分は図19のような状態になる。
 第3サイクルの開始時に、新処理の内容が規定され、実行を開始するものとする。新処理の内容の規定は、処理を実現する装置がFPGAの場合は、例えば、部分再構成機能によって行われる。また、時系列データ3が新旧処理に入力されたとする。旧処理は結果”5”を出力する。新処理は、時系列データ”3”を保存しておく。装置外部へは旧処理の結果”3”が出力される。第3サイクルの終了時に、各部分は図20のような状態になる。
 第4サイクルの開始時に、時系列データ”4”が新旧処理に入力されたとする。旧処理は結果”7”を出力する。新処理は、時系列データ”4”を保存しておく。装置外部へは旧処理の結果”5”が出力される。第4サイクルの終了時に、各部分は図21のような状態になる。
 第5サイクルの開始時に、時系列データ”5”が新旧処理に入力されたとする。旧処理は結果”9”を出力する。新処理は直近の3値である[3,4,5]を得たため、3つの値の合計である結果”12”を出力する。装置外部へは旧処理の結果”7”が出力される。第5サイクルの終了時に、各部分は図22のような状態になる。
 第6サイクルの開始時に、時系列データ”6”が新旧処理に入力されたとする。旧処理は結果”11”を出力する。新処理は結果”15”を出力する。装置外部へは旧処理の結果”9”と新処理の結果”12”が出力される。第6サイクルの終了時に、各部分は図23のような状態になる。このように、非特許文献1の第1の方法では、装置外部へ新旧処理両方の結果が混在して出力される。
 次に、図24から図28を用いて、非特許文献1の第2の方法による動作を説明する。
 ここでも、直近2値の和を取る旧処理を、直近3値の和を取る新処理に変更する。新旧処理両方とも、データを入力したのと同じサイクルに結果を出力する、とする。また、処理の結果は処理部から合流部へ1サイクルで到達するものとする。また、処理の結果は合流部から装置外部へ1サイクルで到達するものとする。また1サイクルごとにデータが入力されるものとし、1サイクルを単位とする時刻を用いて説明する。
 第1サイクルの開始時に、時系列データ”1”が入力されたとする。第2サイクルの開始時に、時系列データ”2”が入力されたとする。旧処理は直近2値である[1,2]を得たため、処理部501が結果”3”を計算し出力する。第2サイクルの終了時に、各部分は図24のような状態になる。
 第3サイクルの開始時に、新処理を実行するための情報が書き込まれ、実行を開始するものとする。第2の方法では、旧処理は、このタイミングで停止する。また、時系列データ”3”が新旧処理に入力されたとする。新処理は、時系列データ”3”を保存しておく。第3サイクルの終了時に、各部分は図25のような状態になる。
 第4サイクルの開始時に、時系列データ”4”が新旧処理に入力されたとする。新処理は、時系列データ”4”を保存しておく。第4サイクルの終了時に、各部分は図26のような状態になる。このように、第2の方法では、このタイミングで装置外部へ結果は出力されない。これに対して、第1の方法では、図21のように、結果が出力される。
 第5サイクルの開始時に、時系列データ”5”が新旧処理に入力されたとする。新処理は直近の3値である[3,4,5]を得たため、結果”12”を出力する。第5サイクルの終了時に、各部分は図27のような状態になる。このように、第2の方法では、このタイミングでも、装置外部へ結果が出力されない。これに対して、第1の方法では、図22のように、結果が出力される。
 第6サイクルの開始時に、時系列データ”6”が新旧処理に入力されたとする。新処理は結果”15”を出力する。第6サイクルの終了時に、各部分は図28のような状態になる。
 以上のように、非特許文献1の第2の方法では、新旧処理両方の結果が混在して装置外部に出力されることはない。
特表2004-508617号公報 特開2001-049747号公報 特開2001-075908号公報 特開2005-049102号公報
Kyumars Sheykh Esmail et al., Changing Flights in Mid-air: A model for Safely Modifying Continuous Queries, In Proc. Of SIGMOD’11, June 2011
 特許文献1には、再構成可能デバイスを用いたシステムが開示されている。しかし、特許文献1には、デバイスの構成ファイル(所定の回路を構成するための回路情報)の書き換え時に発生する問題には言及されていない。従って、そのような問題を解決することができない。
 特許文献2には、2種類の処理を行う時系列データ圧縮装置が開示されている。しかし、特許文献2の装置では、前処理の結果に対する所定の判断の結果に基づいて、2種類の処理のうちの1つを適用する。そして、最終の処理結果がいずれの処理が適用されたものであるかの区別はされない。従って、2種類の処理のそれぞれによる結果を判別することができない。
 特許文献3、4には、バージョン番号(更新版数)が付加された情報を取り扱う処理装置が開示されている。しかし、特許文献3の技術、特許文献4の技術共に、バージョン番号は、それが付加された情報の新旧を判断し、新しい情報に更新するために用いられる。従って、バージョン番号が古い方の情報は、破棄されるため、その情報が有用であっても、活用することはできない。
 特許文献2の技術と、特許文献3又は特許文献4を組み合わせると、時系列データに対して新処理、旧処理の2種類の処理を行い、その結果データが、いずれの処理が適用されたものであるかの判別は可能である。しかし、その判別は、処理の新旧を判別するものとなり、旧処理による結果データを活用することはできない。
 前述のように、処理の更新に必要な機能の一つは、一つの装置で同時動作する複数の処理の複数の結果の中から、旧処理と新処理の結果を識別することである。そして、特許文献2-4を組み合わせると、旧処理と新処理の結果の識別機能を実現することはできる。しかし、その機能の実現のためには、処理番号に対応付けてバージョン番号を記憶する必要がある。そのため、処理の種類が多くなると、記憶が必要となる追加情報のデータサイズが大きくなるという課題が生じる。また、上記のような追加情報を用いた処理は、処理番号を用いたバージョン番号の検索と比較処理を含むため、処理の遅延が大きいという課題が存在する。
 上記の2つの課題が発生する理由について、具体例を用いて詳しく説明する。前述のように、特許文献2-4を組み合わせた技術では、図29に示すように、旧処理と新処理の結果を一意に識別できる処理番号と、処理のバージョン番号を結果に付加することで、旧処理の結果と新処理の結果を識別する。この二つの情報、すなわち処理番号と処理のバージョン番号は、装置で同時に動作する処理の数が多い、又はバージョン番号の範囲が広いときには、そのデータ量が大きいという課題がある。
 また、これらの情報を用いて、旧処理と新処理を識別するようにした場合、装置で同時に動作する処理の数が多い、又はバージョン番号の範囲が広いときには、識別のための処理の遅延が大きいという課題がある。
 例えば、同時に65,536(=2^16)種の処理が一つの装置で動作し、それぞれの処理にバージョン番号が65,536種ある場合、処理番号とバージョン番号のそれぞれに16ビットの情報が必要である。従って、旧処理と新処理の結果には、合計で32ビットの情報を付加する必要がある。そして、旧処理と新処理の識別のためには、全体で2,097,152(=65,536×32)ビットという、膨大な量の情報を格納する必要があるという課題がある。
 また、バージョン比較部が記録する表は、65,536種類の処理ごとに16ビットのバージョン番号を記録する必要があるので、全体で1,048,576(=65,536×16)ビットという、膨大な量の情報を格納する必要があるという課題がある。
 さらに、バージョン比較部は、2つの16ビットのバージョン番号を比較する。これの比較処理は、32ビットのデータを用いた演算となるため、処理結果が判明するまでの遅延時間が大きいという課題がある。
 非特許文献1の第1の方法では、図23のように、新旧処理両方の結果が混在して装置外部に出力される。混在して出力された結果データは、新処理によるものか旧処理によるものかの識別ができない。そのため、処理の変更前後の旧処理による結果データを利用することができないという課題がある。
 非特許文献1の第2の方法では、新旧処理両方の結果が混在して装置外部に出力されことはない。そのため、結果データを利用することは可能である。
 ところが、旧処理による結果データで、有用で利用可能な結果があるときも、装置外部に出力されない。すなわち、旧処理は、動作させることが可能であるにもかかわらず、停止させられているために、旧処理によって得られるデータを外部に出力することができない。例えば、上記の例では、[2,3]の和、[3,4]の和は、利用可能であるにもかかわらず出力されない。
 さらに、旧処理を継続して動作させたとしても、合流部で新処理の結果と旧処理の結果が混合されるために、旧処理の結果を指定したタイミングまで出力させることはできない。上記の例では、新処理の結果と混合されることなく、[2,3]の和、[3,4]の和を出力することはできない。
 このように、非特許文献1の第2の方法には、旧処理を極力実行させ、その処理結果を最大限に利用するといった、処理装置の有効利用の観点で課題がある。
 以上の説明を整理すると、非特許文献1の技術では、処理の結果データについて、新処理によるものであるか旧処理によるものであるかを区別せず、混合して出力する。そのため、非特許文献1の技術では、処理を新処理から旧処理に実行時に変更する際に、新旧処理両方の結果が混在して装置外部に出力されるという課題がある。
 さらに、非特許文献1の技術では、新処理を開始するときは、旧処理は停止させる。そのため、旧処理の有用で利用可能な結果が装置外部に出力されないという課題もある。
(発明の目的)
 本発明はこのような事情に鑑みて提案されたものであり、時系列データの処理において、第1の処理から第2の処理への処理の変更時に、新旧処理の両方の結果が混在して外部に出力されず、処理の変更前後の旧処理の結果を外部に出力することができ、旧処理と新処理の結果を識別するための付加情報の量を削減し、さらに、旧処理と新処理の結果の識別、並びに出力及び破棄の対象とする結果の選択の判断に要する時間を短縮できる、時系列データ装置、時系列データ方法及び時系列データ処理プログラムの記憶媒体を提供することにある。
 本発明の時系列データ処理装置は、第1の処理を実行して第1の結果データを出力する第1の処理手段と、第2の処理を実行して第2の結果データを出力する第2の処理手段と、外部から処理の変更の指示を受けたとき、第1の処理が停止可能か否かを判断し、第1の結果データに第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、第2の結果データに第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成する制御手段と、外部へ出力すべき結果データを指定する第3の識別情報を記録し、第1の結果データの組又は第2の結果データの組が到着したとき、第1の識別情報と第3の識別情報との比較結果及び第2の識別情報と第3の識別情報との比較結果に基づいて、第1の結果データの組又は第2の結果データの組の一方を選択して出力し他方を破棄する選択手段と、を備えることを特徴とする。
 本発明の時系列データ処理方法は、第1の処理手段において第1の処理を実行して、第1の結果データを出力し、第2の処理手段において第2の処理を実行して、第2の結果データを出力し、外部から処理の変更の指示を受けたとき、第1の処理が停止可能か否かを判断し、第1の結果データに第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、第2の結果データに第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成し、外部へ出力すべき結果データを指定する第3の識別情報を記録し、第1の結果データの組又は第2の結果データの組が到着したとき、第1の識別情報と第3の識別情報との比較結果及び第2の識別情報と第3の識別情報との比較結果に基づいて、第1の結果データの組又は第2の結果データの組の一方を選択して出力し他方を破棄することを特徴とする。
 本発明の時系列データ処理プログラムの記憶媒体は、第1の処理を実行して第1の結果データを出力する第1の処理手段、及び第2の処理を実行して第2の結果データを出力する第2の処理手段を備える時系列データ処理装置が備えるコンピュータを、
 外部から処理の変更の指示を受けたとき、第1の処理が停止可能か否かを判断し、第1の結果データに第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、第2の結果データに第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成する制御手段、及び外部へ出力すべき結果データを指定する第3の識別情報を記録し、第1の結果データの組又は第2の結果データの組が到着したとき、第1の識別情報と第3の識別情報との比較結果及び第2の識別情報と第3の識別情報との比較結果に基づいて、第1の結果データの組又は第2の結果データの組の一方を選択して出力し他方を破棄する選択手段と、
として機能させるためのプログラムを格納することを特徴とする。
 本発明によれば、時系列データの処理において、実行する処理を、第1の処理から第2の処理へ変更したときも、第1、第2の両方の結果が混在して装置外部に出力されない。さらに、処理の変更前後の旧処理の結果を外部に出力することができる。さらに、新旧処理の結果データに付加される情報の量を削減し、新旧処理の結果の識別、並びに出力及び破棄の対象とする結果の選択の判断に要する時間を短縮することができる。
本発明の実施形態の時系列データ処理装置の構成を示すブロック図である。 選択部121の内部構成の例を示すブロック図である。 結果データの組のデータ構造の例を示す図である。 本発明の実施形態の時系列データ処理装置における処理例を示すフローチャートである。 本発明の実施形態の時系列データ処理装置における処理例を示すフローチャートである。 本発明の実施形態の時系列データ処理装置における処理例を示すフローチャートである。 本発明の実施形態の時系列データ処理装置の各状態における、識別情報及び出力データを示す表である。 本発明の実施形態の動作の具体例の、第4サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第5サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第6サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第7各サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第8サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第9サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第10サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第11サイクル終了時の各部の出力データの状態を示す図である。 本発明の実施形態の動作の具体例の、第12サイクル終了時の各部の出力データの状態を示す図である。 背景技術の動作例の旧処理と新処理の状態の時間遷移図である。 非特許文献1の時系列データ処理装置の構成を示すブロック図である。 非特許文献1の時系列データ処理装置の、第1の方法による、第2サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第1の方法による、第3サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第1の方法による、第4サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第1の方法による、第5サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第1の方法による、第6サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第2の方法による、第2サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第2の方法による、第3サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第2の方法による、第4サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第2の方法による、第5サイクルの終了時の各部の出力データの状態を示す図である。 非特許文献1の時系列データ処理装置の、第2の方法による、第6サイクルの終了時の各部の出力データの状態を示す図である。 特許文献2-4の技術を組み合わせて構成された時系列データ処理装置の構成を示すブロック図である。 図29の時系列データ処理装置の、各部の出力データの状態を示す図である。
(第1の実施形態)
 次に、本発明の実施の形態について図面を参照して詳細に説明する。
 時系列データに対して処理を行う時系列データ処理装置において、ICチップ上の複数領域でユーザ定義処理を実行し、実行時に任意の領域を異なる動作をする処理に変更する。前述のように、変更前の処理を「第1のユーザ定義処理」、変更後の処理を「第2のユーザ定義処理」という。あるいは、変更前の処理を「旧処理」、変更後の処理を「新処理」ということもある。
 ICチップにおいて、旧処理を動作させたまま、新処理を実行する回路情報を、旧処理を実行する回路の領域とは別の領域に書き込み、新処理の動作を開始させ、その後、旧処理を停止させ、旧処理を実行する回路情報を削除する形で処理の変更を行うことにより、結果が出力されない期間を短縮しながら処理の変更を実現する。なお、上記の処理の変更は、時系列データデータ処理を実行する回路情報を書き込める領域(「パーティション」という。)を、複数持つICチップを用いて実現してもよい。このようなICチップの例として、FPGAが挙げられる。 
 図1は、本発明の実施形態に係る時系列データ処理装置100の構成を示すブロック図である。
 時系列データ処理装置100は、処理部101、制御部111、選択部121を備える。1
 処理部101は、旧処理を実行し結果データを出力する。あるいは、処理部101は、旧処理の実行時に置き換えられた新処理を実行し、結果データを出力する。処理部101が実行する処理が、旧処理であるか、あるいは新処理であるかは、処理部101が実行する処理の変更の有無により決まる。複数の処理部101の機能や内部の構成は、全て同じであっても、一部又は全部が異なっていてもよい。
 制御部111は、各処理部101が行った処理の内容に対応する「識別情報」を設定する。識別情報の違いにより、処理部101が行った処理の違いを識別することができる。
 識別情報を設定する目的について、詳しく説明する。時系列データ処理装置100では、複数の処理部において、旧処理から新処理への変更が同時に進行することがある。すなわち、第1の処理部における第1の旧処理から第1の新処理への変更と、第2の処理部における第2の旧処理から第2の新処理への変更が同時に進行することがある。このような場合に、所定の識別情報を用いることによって、第1の旧処理と第1の新処理を、時系列データ処理装置100上で同時に動作する、第2の旧処理及び第2の新処理を含む他の処理から識別することができる。
 外部からの、第1の処理部による処理の変更の指示のタイミングと第2の処理部による処理の変更の指示のタイミングは、一致しないように制御される。この制御によって、第1の旧処理から第1の新処理への変更と、第2の旧処理から第2の新処理への変更が同時に進行することはない。この制御により、第1の旧処理及び第1の新処理の状態は、4種類の識別情報で表すことができる。4種類の識別情報を、それぞれ、"stable"、"transit-0"、"transit-1"、"transit-2"と呼ぶ。
 "stable"は、処理の変更が起きていない場合の結果データ、すなわち新処理と旧処理のペアが生じていない処理の結果データを意味する。なお、旧処理から新処理への変更が完了したときには、処理部は初期状態、すなわち変更が起きていない状態に戻るので、結果データの識別情報は、"stable"となる。
 "transit-0"は、処理の変更が進行中であること、及び"transit-0"に対応する結果データは、新処理の結果データと旧処理の結果データのペアのうち、新処理の結果データであり、現時点ではまだ装置外部に出力しないように指示された結果データであることを意味する。
 "transit-1"は、処理の変更が進行中であることを意味する。なお、"transit-1"に対応する結果データは、処理の変更途中のものであるから、新処理の結果データと旧処理の結果データのペアのうち、旧処理の結果データである。"transit-1"は、選択部121に記録されたときは、出力すべき結果データが旧処理の結果データであることを指定する。
 "transit-2"は、処理の変更が進行中であること、及び"transit-2"に対応する結果データは、新処理の結果データと旧処理の結果データのペアのうち、新処理の結果データであり、装置外部に出力するように指示された結果データであることを意味する。"transit-2"は、選択部121に記録されたときは、出力すべき結果データが新処理の結果データであることを指定する。
 そして、制御部111は、処理部101が結果データを出力したタイミングで、結果データに識別情報を付加し、選択部121へ出力する。結果データに付加される識別情報は、上記の4種類の全てを取りうるので、2ビットで表現される。2ビットの識別情報は、制御部111によって論理レベルが制御される2本の配線、あるいは制御部111によって保持値が制御される2個のフリップフロップ等で実現することができる。
 以上のように、本実施形態では、旧処理から新処理へ変更される際に、それぞれの処理部101の出力において2ビットの識別情報が追加される。従って、時系列データ処理装置100でN個の処理が同時に動作する場合には、装置全体として2*Nビットの情報が追加される。
 これに対して、特許文献2-4を組み合わせた方法では、バージョン番号がM種の値を取るとし、2を底とするNの自然対数をlog2(N)と表すとすると、処理部の出力に、装置全体として(log2(M)+log2(N))*Nビットの情報が追加される。
 ここで、例えば、NとMを65,536とすると、本実施形態と、特許文献2-4を組み合わせた方法で、装置全体として追加される情報のビット数は、それぞれ、131,072、2,097,152となる。このように、本実施形態の方法では、追加される情報の量が大幅に削減される。
 選択部121は、複数の処理部101と制御部111から、結果データとそれに対応付けて付加された識別情報の組を受け取る。選択部121には予め識別情報が登録されている。選択部121は、受け取った識別情報と、選択部121に登録されている識別情報を用いて、動作への切り替えを行う。動作の切り替えとは、旧処理の結果データを外部へ出力し新処理の結果データを破棄するという動作から、旧処理の結果データを破棄し新処理の結果データを外部へ出力するという動作への切り替えである。結果データが出力される際に、出力される結果データに付加されていた識別情報も外部へ出力されてもよい。そして、選択部121は、ある処理部101の処理が新処理に切り替えられた後、新処理の結果データを初めて出力したというイベントを、選択部121に記録されている識別情報を用いて記録する。
 なお、選択部121に記録して用いられる識別情報は、後に説明するように、"transit-1"又は"transit-2"の2種のみなので、1ビットで表現することができる。1ビットの識別情報は、制御部111によって論理レベルが制御される1本の配線あるいは制御部111によって保持値が制御される1個のフリップフロップ等で実現することができる。
 以上のように、本実施形態では、選択部121に1ビットの識別情報が記録される。従って、時系列データ処理装置100でN個の処理が同時に平行して動作する場合には、選択部には、1ビットの情報が格納される。
 これに対して、特許文献2-4を組み合わせた方法では、バージョン番号がM種の値を取るとすると、log2(M)*Nビットの情報が格納される。
 ここで、例えば、NとMを65,536とすると、本実施形態と、特許文献2-4を組み合わせた方法で、追加して記録される情報のビット数は、それぞれ、1、1,048,576となる。このように、本実施形態の方法では、追加して記録される情報の量が大幅に削減される。
 また、本実施形態では、旧処理の結果と新処理の結果の識別のために、結果データに付加された識別情報と、選択部に格納されている識別情報を用いた演算が行われる。さらに、時系列データ処理装置100で、N個の処理が同時に平行して動作する場合には、処理の種類の識別、すなわちその処理を行った処理部101の識別のために、のために、選択部121において、識別情報を用いた演算が追加される。このように、本実施形態では、選択部121において、バージョン番号に関する処理と処理番号に関する処理、すなわち2+1ビットを入力とする演算が行われる。
 これに対して、特許文献2-4を組み合わせた方法では、二つのバージョン番号を用いた演算が追加される。すなわち、バージョン番号がM種の値を取るとすると、2*log2(M)を入力とする演算が追加される。
 ここで、例えば、NとMを65,536とすると、本実施形態と、特許文献2-4を組み合わせた方法で、必要となる演算の入力ビット数は、それぞれ、3、32となる。このように、本実施形態では、演算の入力ビット数が大幅に減少するので、演算に要する時間が大幅に短縮される。
 あるいは、特許文献2-4を組み合わせた方法では、選択部121の演算時間を短縮するために、検索及び比較の処理を並列に行う等、ハードウェアの規模を大きくする方法も考えられる。これに対して、本実施形態では、入力ビット数を削減することができるので、並列処理を行う場合であっても、ハードウェアを大幅に削減することができる。
 制御部111は、処理部101の結果データの出力に合わせて、識別情報を出力する。この結果、選択部121への入力情報は、処理部101が出力した結果データと制御部が付加した識別情報の組である。上記の情報の組は、例えば、図3に示すような構成をとってもよい。以降、結果データ、識別情報からなる上記情報の組を、一体のものとして取り扱うときは、「結果データの組」という。
 図2は、選択部121の内部構成の例を示すブロック図である。選択部121は、入力ポート、出力ポート、待ちデータキュー1001、調停部1002を備える。選択部121は、調停部1002を用いて、2つの入力ポートと待ちデータキュー1001から受け取った結果データの組について、出力ポートの割り当ての調停を行う。出力ポートが割り当てられた結果データの組は出力ポートに出力される。出力ポートが割り当てられなかった結果データの組は、破棄されるか、待ちデータキュー1001に挿入される。待ちデータキュー1001に挿入されたデータは、次のサイクルに再び選択部121への入力となる。
 次に、本実施の形態に係る時系列データ処理装置100の動作について、図4、図5、図6を参照して説明する。
 まず初めに、いくつかの用語を定義する。新たな入力が到着して、次の入力が来る前の期間を、「1入力期間」という。時系列データ処理装置が、所定の動作を完了させるために要する単位時間を規定するクロックの周期を、「1サイクル」という。
 前述のように、ICチップ上に処理を実行させることのできる回路の領域を複数分けて設け、これを「パーティション」という。パーティションには、構成データ、コンフィギュレーションデータと呼ばれる設定情報を設定することで、ユーザ定義の処理を実行する回路を作成することができる。
 また、「指令する」、「指示する」とは、ある部分(「指令元部分」という。)が、別の部分(「指令先部分」という。)に接続されている配線の信号を操作したり、指令先部分に存在する記憶装置に値を書き込んだりすることを意味する。「登録する」、「設定する」、「記録する」とは、登録元のある部分が、登録先の別の部分に存在する記憶装置に値を書き込むことを意味する。「情報を送る」、「データを送る」、「結果を出力する」とは、送り元である、装置のある部分が、送り先である、装置の別の部分に接続されている配線の信号を操作したり、送り先の部分に存在する記憶装置に値を書き込んだりすることを意味する。
 ところで、本実施形態では、時系列データ処理装置100から出力される結果データが、旧処理によるものから新処理によるものへ変更される。この変更は、図示されないホストコンピュータ等による、時系列データ処理装置100に対する、処理の変更指示(以降、「処理変更指示」という。)によって許可される。以下の説明では、時系列データ処理装置100は、既に処理変更指示を受けていることを前提とする。
 図4のフローチャートにおいて、まず、制御部111は、全ての処理部101の識別情報を"stable"に設定し、選択部121に記録されている識別情報を"transit-1"にする(ステップS1001)。
 次に、制御部111は、新処理を実行するための回路情報を、処理部101における、旧処理を実行するための回路情報が書き込まれた領域とは別の領域に書き込む前のタイミングで、旧処理の識別情報を"transit-1"にする(ステップS1002)。
 次に、制御部111は、処理部101への新処理を実行するための回路情報の書き込みのタイミングで、新処理の識別情報を"transit-0"に設定する(ステップS1003)。
 次に、制御部111は、旧処理が停止可能な状態に至ったか判断し、該当する場合は新処理の識別情報を"transit-2"に設定する(ステップS1004)。
 ここで、「旧処理が停止可能な状態」とは、旧処理を実行する処理部101の動作を停止させ、結果データの出力を停止することができる状態をいう。旧処理が停止可能な状態では、時系列データ処理装置100から出力される結果データを、旧処理による結果データから新処理による結果データへ変更することができる。
 すなわち、処理変更指示を受けると、時系列データ処理装置100から出力される結果データが、直ちに、新処理による結果データに変更されるのではない。時系列データ処理装置100が処理変更指示を受け、さらに、旧処理が停止可能な状態に至った後、時系列データ処理装置100から出力される結果データが、新処理による結果データに変更される。
 例えば、旧処理が進行中である等の旧処理を実行する処理部101の処理状況、あるいは、旧処理による一連のデータの出力中である等の処理部101の出力状況によっては、旧処理が停止可能な状態にはならない。この場合は、時系列データ処理装置100からは、旧処理の結果データの出力が継続される。
 識別情報の設定を指示したり、値を与えたりする主体は、図示されないホストコンピュータでもよい。あるいは、その主体は制御部111でもよい。
 次に、制御部111は、処理部101における旧処理を停止させる(ステップS1005)。
 次に、制御部111は、旧処理の結果データが時系列データ処理装置100中に存在しなくなったタイミングで、新処理の識別情報を"stable"にする(ステップS1006)。
 次に、制御部111は、"transit-2"であるデータが装置中に存在しなくなったタイミングで、選択部121に記録されている識別情報を"transit-1"にし、ステップS1002に戻る(ステップS1007)。
 図4のフローチャートに示す動作の処理と並行して、制御部111では、図5のフローチャートに示す処理が行われる。すなわち、制御部111は、結果データの組を選択部121に送り、ステップS1201に戻る(ステップS1201)。
 さらに、図4のフローチャートに示す動作の処理と並行して、選択部121では、図6のフローチャートに示す処理が行われる。すなわち、選択部121は、識別情報が"transit-2"である結果データの組が到着し、かつ、記録されている識別情報が"transit-1"である場合は、記録されている識別情報を"transit-2"に更新する(ステップS1301)。
 次に、選択部121は、記録されている識別情報が"transit-1"の場合は、到着した結果データの組のうち、識別情報が"transit-0"のものを破棄する。選択部121は、記録されている識別情報が"transit-2"の場合は、到着した結果データの組のうち、識別情報が"transit-1"のものを破棄する(ステップS1302)。
 次に、選択部121は、到着した結果データの組のうちで、破棄されていないものの間で、装置外部への出力ポートの使用権の調停を行う。そして、出力ポートの使用権を獲得できたものを、出力ポートへ転送して装置の外部へ出力し、獲得できなかったものを待ちデータキューに挿入し、ステップS1301に戻る(ステップS1303)。
 「待ちデータキュー」とは、選択部121において、破棄されず、かつ出力されなかった結果データの組が挿入されるキューである。待ちデータキューに格納された結果データの組は、次のサイクルに待ちデータキューから取り出され、選択部121に到着したとみなされる 「出力ポートの使用権の調停」とは、具体的には、出力ポートを使用できるデータを一つ選ぶ行為を意味する。この調停においてデータが選ばれたとき、「データがポートを獲得した」という。
 図7に、時系列データ処理装置100の各状態における、識別情報及び出力データを示す。
 処理の変更のない初期状態では、全ての処理の結果データの識別情報は"stable"に設定され、選択部121に記録される識別情報は"transit-1"に設定される。以上の設定により、選択部121からは、全ての処理の結果データが装置外部に出力される。
 次に、処理部101における処理の変更が開始された後で、かつ旧処理が停止可能な状態にないときは、旧処理の結果データの識別情報は"transit-1"に変更される。また、新処理の結果データの識別情報は"transit-0"に変更される。ただし、選択部121に記録される識別情報は"transit-1"のまま変更されない。以上の設定により、選択部121によって、新処理の結果データは、破棄され続ける。
 そして、旧処理が停止可能な状態になったときは、新処理の結果データの識別情報は"transit-2"に変更され、選択部121に記録される識別情報が"transit-1"から"transit-2"に変更される。以上の設定により、選択部121によって、旧処理の結果データは、破棄され続ける。
 処理の変更が完了した後は、新処理の結果データの識別情報は"stable"に、選択部121に記録される識別情報は"transit-1"に変更される。以上の設定によって、識別情報の状態は、初期状態に戻る。
(実施形態の動作の具体例)
 図4から図6のフローチャートと、図8から図16のブロック図を参照して、実施形態に係る時系列データ処理装置100の動作の具体例を説明する。
 図8から図16の時系列データ処理装置100は、4つの処理部101を備える。以降、旧処理の実行を担当する処理部は処理部101-1と表記し、新処理の実行を担当する処理部は処理部101-2と表記する。実行する処理が旧処理であるか新処理であるかを区別する必要がなく、処理部101-1、処理部101-2の両方に当てはまるとき、あるいは、旧処理、新処理以外の処理を行うときは、処理部100と表記する。
 本具体例では、株価の時系列データについて、4つの値の和を計算する処理(「旧処理」という。)を、入力値から”2”を減算する処理(「新処理」という。)に変更することを考える。
 なお、以下の説明では、新処理、旧処理とも、FPGAのように再構成可能な回路素子に、それぞれの処理を実行するための回路情報を書き込んだ後、回路を動作させることによって実現することを想定している。しかし、新処理、旧処理の実現方法は、上記のようにハードウェアによって実現する方法には限定されない。すなわち、前述のように、処理部101が備えるプロセッサにプログラムを実行させるという、ソフトウェアによる方法を用いてもよい。ソフトウェアによる実現方法では、以下の「回路情報」を「プログラム」に置き換えて考えればよい。
 本具体例では、処理を以下のステップで変更する。
(1)新処理を実行するための回路情報を、旧処理を実行するための回路情報が書き込まれた領域とは別の領域に書き込む。
(2)新処理の動作を開始する。
(3)新処理の出力を開始する。
(4)旧処理の動作を停止する。
(5)旧処理を実行するための回路情報を削除する。
 初期状態では、旧処理を実行する処理部101-1のみが、時系列データ処理装置100上で動作している。
 ここで、旧処理が停止可能になって、旧処理の結果データを出力停止し、新処理の結果データを出力開始させたいタイミングが、旧処理の処理部101-1から制御部111に与えられるとする。そのタイミングは、新処理を実行するための回路情報の、新処理の処理部101-2への書き込みが完了し、新処理が結果を出力し始めてから、数サイクルの後であるとする。つまり、新処理が結果出力を開始した以降も、数サイクルの間は、旧処理の結果は利用可能である。そこで、この利用可能な旧処理の結果を出力可能にすることによって、有効に利用することができる。
 新処理及び旧処理を実行する装置はFPGAでもよい。時系列データ処理装置100が結果を出力する先は、ホストコンピュータでもよい。旧処理は、処理を実行する装置がFPGAの場合は、FPGAが持つ再構成機能を使って、必要な回路情報をFPGAに書き込むことによって、実現してもよい。
 また、入力データは整数であるものとする。前述のように、時系列データ処理装置の動作に用いられるクロックの周期を「サイクル」といい、これを期間の単位として用いる。「サイクルの開始時」とは、その期間の最初の時点を意味し、「サイクルの終了時」とは、その期間の最後の時点を意味する。例えば、クロックの周波数が1GHzである場合は、ある基準時刻について第1サイクルは、基準時刻プラスゼロ秒から基準時刻プラス1ナノ秒の間の期間を、第Nサイクルは基準時刻プラス(N-1)ナノ秒から基準時刻プラスNナノ秒の期間を意味する。第Mサイクルの開始時は、基準時刻プラス(M-1)ナノ秒を意味し、第Mサイクルの終了時は、基準時刻プラスMナノ秒を意味する。入力データは、毎サイクルの開始時に与えられるものとする。
 また、「処理部101が結果を出力する」とは、処理部101が算出した結果データを文字通り出力することを意味する。処理部101が算出した結果データは、制御部111によって、識別情報が付加され、選択部121へ送られる。
 まず、制御部は、全ての処理部の識別情報を"stable"にし、選択部に記録されている識別情報を"transit-1"に設定する(ステップS1001)。
 次に、第1、第2、第3、第4サイクルの開始時に、入力データとして、1,2,3,4が旧処理を実行する処理部101-1に与えられると、処理部101-1は、それらの入力データの和を計算し出力する。処理部101-1は、結果データを出力し、制御部111が結果データに識別情報"stable"を付加して選択部121に送る(ステップS1201)。結果データと、識別情報とを合わせて<10,stable>のように表す。以降は、この値の組を、混同のない限り「結果」あるいは「結果データの組」という。この時点での、時系列データ処理装置100の内部の出力情報、すなわち、処理部101-1から選択部121に送られた結果データの組を図8に示す。
 第5サイクルの開始時に、選択部121には、旧処理の結果データの組が到着する。選択部121は、結果データの組の識別情報は"transit-2"ではないので、記録している識別情報を更新しない(ステップS1301)。
 さらに、選択部121は、記録されている識別情報が"transit-1"であり、到着した結果データの組の識別情報は"stable"なので、結果データを破棄しない(ステップS1302)。
 さらに、到着した結果データの組は一つであり、またそれが破棄されなかったため、選択部121は、この一つの結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、結果データの組を装置外部への出力ポートへ転送する(ステップS1303)。
 また、制御部111は、新処理を実行するための回路情報の書き込みの準備として、旧処理の識別情報を<transit-1>に設定する(ステップS1002)。入力データ”5”が旧処理を実行する処理部101-1に与えられ、制御部111は、<14,transit-1>を選択部121に出力する。
 第5サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図9に示す。
 第6サイクルの開始時に、選択部121には、旧処理の結果データの組が到着する。選択部121は、結果データの組の識別情報は"transit-2"ではないので、記録している識別情報を更新しない(ステップS1301)。
 さらに、選択部121は、記録されている識別情報が"transit-1"であり、結果データの組の識別情報は"transit-1"であるため、これを破棄しない(ステップS1302)。
 さらに、選択部121は、破棄されなかった結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、旧処理の結果データの組を装置外部への出力ポートへ転送する(ステップS1303)。
 このタイミングで、処理部101-2に新処理を実行するための回路情報が書き込まれ、さらに、処理部101-2が新処理の実行を開始したとする。制御部111は、新処理の識別情報を"transit-0"に設定する(ステップS1003)。
 さらに、入力データ”6”が、処理部101-1、101-2に与えられたとする。そして、処理部101-1と制御部111が結果データの組〈18,transit-1〉を、処理部101-2と制御部111が結果データの組〈4,transit-0〉を選択部121に出力する。
 第6サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図10に示す。
 第7サイクルの開始時に、選択部121には、新処理と旧処理の2つの結果データの組が到着する。選択部121は、結果データの組の識別情報は2つとも"transit-2"ではないので、記録している識別情報を更新しない(ステップS1301)。
 さらに、選択部121は、記録されている識別情報が"transit-1"であり、旧処理の結果データの組の識別情報は"transit-1"であるため、旧処理の結果データの組を破棄しない。一方で、選択部121は、新処理の結果データの組の識別情報は"transit-0"であるため、新処理の結果データの組を破棄する(ステップS1302)。
 さらに、選択部121は、破棄されなかった結果データの組の間の、装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、旧処理の結果データの組を装置外部への出力ポートへ転送する(ステップS1303)。この動作により、旧処理と新処理の結果が混在して装置外部に出力されるという問題が回避される。また、有用である旧処理の結果データが破棄されることなく、装置外部に出力されるので、結果データを有効に利用することができる。
 また、入力データ“7”が処理部101-1、101-2に与えられたとする。そして、処理部101-1と制御部111が結果データの組<22,transit-1>を選択部121に送り、処理部101-2と制御部111が結果データの組<5,transit-0>を選択部121に送る。
 第7サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図11に示す。
 第8サイクルの開始時に、選択部121には、新処理と旧処理の2つの結果データの組が到着する。選択部121は、結果データの組の識別情報は2つとも"transit-2"ではないので、記録している識別情報を更新しない(ステップS1301)。
 さらに、選択部121は、記録されている識別情報が"transit-1"であり、旧処理の結果データの組の識別情報は"transit-1"であるため、旧処理の結果データの組を破棄しない。一方で、選択部121は、新処理の結果データの組の識別情報は"transit-0"であるため、新処理の結果データの組を破棄する(ステップS1302)。
 さらに、選択部121は、破棄されなかった結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、旧処理の結果データの組を装置外部の出力ポートへ転送する(ステップS1303)。
 このサイクルで、旧処理が停止可能な状態に至り、制御部111が新処理の識別情報を"transit-2"に設定したとする(ステップS1004)。同じサイクルに、処理部101-1と制御部111が結果〈26,transit-1〉を、処理部101-2と制御部111が結果〈6,transit-2〉を出力したとする。
 第8サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図12に示す。
 第9サイクルの開始時に、選択部121には、新処理と旧処理の2つの結果データの組が到着する。選択部121は、記録されている識別情報が"transit-1"かつ新処理の結果データの組の識別情報は"transit-2"なので、記録している識別情報を"transit-2"に更新する(ステップS1301)。
 さらに、選択部121は、記録されている識別情報が"transit-2"であり、新処理の結果データの組の識別情報は"transit-2"であるため、新処理の結果データを破棄しない(ステップS1302)。一方で、選択部121は、旧処理の結果データの組の識別情報は"transit-1"であるため、旧処理の結果データの組を破棄する
 さらに、選択部121は、破棄されなかった結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、新処理の結果データの組を装置外部への出力ポートへ転送する(ステップS1303)。この動作によって、新旧処理の結果が混在して装置外部に出力されるという問題が回避される。そして、旧処理の結果は装置外部への出力ポートへ出力されなくなり、代わりに新処理の結果が出力される。このように、装置外部に出力される結果データを、旧処理の結果データから新処理の結果データへと、円滑に切り替えることができる。
 このサイクルに、制御部111は、処理部101-1による旧処理を停止する(ステップS1005)。
 同じサイクルに、処理部101-2と制御部111が結果〈7,transit-2〉を出力したとする。
 第9サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図13に示す。
 第10サイクルの開始時に、選択部121には、新処理の結果データの組が到着する。選択部121は、記録されている識別情報が"transit-1"でないので、記録している識別情報を更新しない(ステップS1301)。さらに、選択部121は、記録されている識別情報が"transit-2"であり、新処理の結果データの組の識別情報は"transit-2"であるため、新処理の結果データの組を破棄しない(ステップS1302)。ここで、選択部121は、破棄されなかった結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、新処理の結果データの組を装置外部の出力ポートへ転送する(ステップS1303)。
 旧処理の結果データは装置上にないため、旧処理の結果データと新処理の結果データを識別して、一方を破棄する必要はない。そこで、このサイクルに、制御部111は、新処理の識別情報を"stable"に設定する(ステップS1006)。
 同じサイクルに、処理部101-2と制御部111が結果〈8,stable〉を出力したとする。
 第10サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図14に示す。
 第11サイクルの開始時に、選択部121には、新処理の結果データの組が到着する。選択部121は、記録されている識別情報が"transit-1"でないので、記録している識別情報を更新しない(ステップS1301)。さらに、選択部121は、新処理の結果データの組の識別情報が"stable"であるため、新処理の結果データの組を破棄しない(ステップS1302)。ここで、選択部121は、破棄されなかった結果データの組について装置外部への出力ポートの調停を行う。調停によって出力ポートが獲得されるので、選択部121は、新処理の結果データの組を装置外部への出力ポートへ転送する(ステップS1303)。
 同じサイクルに、処理部101-2と制御部111が結果〈9,stable〉を出力したとする。
 第11サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図15に示す。
 第12サイクルの開始時に、選択部121は、前のサイクルと同様に、新処理の結果データの組を装置外部への出力ポートへ転送する。
 識別情報が"transit-2"である結果データは装置上にないため、選択部121で結果データの組の破棄を行う必要はない。そこで、このサイクルに、制御部111は、選択部121に記録されている識別情報を"transit-1"に設定する(ステップS1007)。
 同じサイクルに、処理部101-2と制御部111が結果〈10, stable〉を出力したとする。
 第12サイクルの終了時の、時系列データ処理装置100の内部の出力情報を図16に示す。
 これ以降のサイクルでは、選択部121が新処理の結果データの組を装置外部への出力ポートに出力し続ける。
 以上の時系列データ処理装置100の動作と、出力される結果データから、本実施形態の効果を説明する。
 時系列データ処理装置100から出力される結果データの組は、時刻の若い順に列で表すと、〈10, stable〉〈14, transit-1〉〈18, transit-1〉〈22, transit-1〉〈6, transit-2〉〈7, transit-2〉〈8, stable〉となる。
 まず、本実施形態では、新処理を実行するための回路情報の処理部101-2への書き込み以降も、処理部101-1において旧処理が停止可能になる時刻まで、有用で利用可能な旧処理の結果データが、破棄されずに装置外部に出力される。本実施形態の場合は、〈18, transit-1〉と〈22, transit-1〉が有用で利用可能な旧処理の結果データに該当する。
 これに対して、例えば非特許文献1の技術では、新処理の書き込み時点で旧処理が停止されるため、この有用で利用可能な結果の出力がなされない。また、特許文献1-4の技術についても、有用で利用可能な旧処理の結果データを出力することは特に考慮されていない。
 このように、本実施形態の手法により、背景技術の方法では出力されなかった、有用で利用可能な旧処理の結果が、最大限、装置外部に出力される。
 そして、旧処理が停止可能になった時刻以降では、旧処理の結果データは破棄され、代わりに新処理を実行する処理部101-2から出力された結果データが装置外部へ出力される。すなわち、処理の変更の前後において、旧処理、新処理の両方の結果が混在して装置外部に出力されることがない。
 また、処理を旧処理から新処理に実行時に変更するために、結果データに付加される情報の量は、背景技術の技術に比べて、処理部101あたり2ビットに抑えることができる。
 さらに、時系列データ装置として実行する処理を、旧処理から新処理に変更する際に、時系列データ装置から出力する結果データを選択するための演算量も削減することができる。すなわち、選択部121における、結果データの組の識別情報と選択部121に格納されている識別情報を用いた演算が、2+1ビットの識別情報を入力とした演算に抑えられる。背景技術のように、処理の新旧の識別のための演算を、識別情報をそのまま使用して行うと、前述のように、演算量が膨大になる可能性がある。このように、本実施形態では、選択部121の演算量を削減できるので、時系列データ装置としての、処理の遅延時間を短縮することができる。
 本実施形態の時系列データ処理装置は、ソフトウェアによって実現することも可能である。時系列データ処理装置を制御するプログラムのフローチャートは、図6から図8と同じである。すなわち、制御部111、選択部121が行う処理を、時系列データ処理装置が備えるプロセッサがプログラムを実行することによって実現してもよい。
 上記のプログラムは、ROM(Read Only Memory)、RAM(Random Access Memory)、フラッシュメモリ等の半導体記憶装置、光ディスク、磁気ディスク、光磁気ディスク等、非一時的な媒体に格納されてもよい。
 以上、実施形態を参照して本願発明を説明したが、本願発明は上記実施形態に限定されるものではない。本願発明の構成や詳細には、本願発明のスコープ内で当業者が理解し得る様々な変更をすることができる。
 この出願は、2012年9月18日に出願された日本出願特願2012-204425を基礎とする優先権を主張し、その開示の全てをここに取り込む。
 本発明の活用例として、数値の平均値を計算するアプリケーションにおいて、平均値を求める対象期間を変更する場合がある。例えば、広い範囲に分散配置された温度センサの値を入力データとし、ある期間の平均を取って、火事を含む緊急事態を検知するアプリケーションが挙げられる。この例では、温度変化が激しくなってきたときに、温度変化に追従する速度を高めるために、温度の平均を取る対象期間の長さを短縮する、という機能を実現することができる。
 また、本発明の他の活用例として、ある演算に用いるパラメータ又は出力情報を変更するアプリケーションがある。例えば、株券など金融商品の売買のタイミングを決めるための指標を計算するアプリケーションを考える。まず、売買する金融商品の銘柄と売買戦略に応じて、必要な指標は複数存在し、出力すべき指標の集合は異なる。ある装置は有限数の指標しか同時に計算できない。時刻に応じて売買する銘柄と戦略は変化する。そのため、そのとき売買する銘柄と売買戦略に応じて、算出する指標を変化させる、という機能を実現することができる。
 100  時系列データ処理装置
 101、101-1、101-2  処理部
 111  制御部
 121  選択部
 1001  待ちデータキュー
 1002  調停部
 500  時系列データ処理装置
 501  処理部
 511  合流部
 600  時系列データ処理装置
 601  処理部
 611  バージョン比較部

Claims (8)

  1.  第1の処理を実行して第1の結果データを出力する第1の処理手段と、
     第2の処理を実行して第2の結果データを出力する第2の処理手段と、
     外部から処理の変更の指示を受けたとき、前記第1の処理が停止可能か否かを判断し、前記第1の結果データに前記第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、前記第2の結果データに前記第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成する制御手段と、
     外部へ出力すべき結果データを指定する第3の識別情報を記録し、前記第1の結果データの組又は前記第2の結果データの組が到着したとき、前記第1の識別情報と前記第3の識別情報との比較結果及び前記第2の識別情報と前記第3の識別情報との比較結果に基づいて、前記第1の結果データの組又は前記第2の結果データの組の一方を選択して出力し他方を破棄する選択手段と、
    を備えることを特徴とする時系列データ処理装置。
  2.  前記制御手段は、前記第1の処理手段の処理状況又は前記第1の処理手段による前記第1の結果データの出力状況に基づいて、前記第1の処理が停止可能か否かを判断する
    ことを特徴とする請求項1に記載の時系列データ処理装置。
  3.  前記第1の識別情報は、前記変更の有無又は進行状況を示し、
     前記第2の識別情報は、前記第2の結果データの外部への出力の可否、及び前記変更の有無又は進行状況を示し、
     前記第3の識別情報は、前記第1の結果データ又は前記第2の結果データのいずれを出力すべきかを指定する
    ことを特徴とする請求項1又は2に記載の時系列データ処理装置。
  4.  前記選択手段は、前記第2の識別情報が前記第2の結果データの外部への出力が可能であることを示し、前記第3の識別情報が前記第1の結果データを出力すべきことを指定するときは、前記第3の識別情報を前記第2の結果データを出力すべき旨を指定するように更新する
    ことを特徴とする請求項3に記載の時系列データ処理装置。
  5.  前記選択手段は、
     前記第3の識別情報が前記第1の結果データを出力すべき旨を指定し、前記第2の識別情報が前記第2の結果データの外部への出力が不可である旨を示すときは、前記第2の結果データを破棄し、
     前記第3の識別情報が前記第2の結果データを出力すべき旨を指定し、前記第1の識別情報が前記処理の変更が進行中である旨を示すときは、前記第1の結果データを破棄する、
    ことを特徴とする請求項3又は4に記載の時系列データ処理装置。
  6.  前記制御手段は、
     前記第1の処理が停止可能な状態に至る前は、前記変更が進行中である旨を示す前記第1の識別情報、及び前記第2の結果データの外部への出力が不可である旨を示す前記第2の識別情報を付加し、
     前記第1の処理が停止可能な状態に至ったときに、前記第2の結果データの外部への出力が可能である旨を示す前記第2の識別情報を付加し、
     全ての前記第1の結果データが外部に出力又は破棄されたタイミングで、前記変更が完了した旨を示す前記第2の識別情報を付加し、
     前記選択手段は、
     前記第2の結果データの外部への出力が可能である旨を示す前記第2の識別情報が付加された全ての前記第2の結果データが外部に出力又は破棄されたタイミングで、前記第1の結果データを出力すべき旨を指定する前記第3の識別情報を記録する、
    ことを特徴とする請求項3乃至5に記載の時系列データ処理装置。
  7.  第1の処理手段において第1の処理を実行して、第1の結果データを出力し、
     第2の処理手段において第2の処理を実行して、第2の結果データを出力し、
     外部から処理の変更の指示を受けたとき、前記第1の処理が停止可能か否かを判断し、
     前記第1の結果データに前記第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、
     前記第2の結果データに前記第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成し、
     外部へ出力すべき結果データを指定する第3の識別情報を記録し、
     前記第1の結果データの組又は前記第2の結果データの組が到着したとき、前記第1の識別情報と前記第3の識別情報との比較結果及び前記第2の識別情報と前記第3の識別情報との比較結果に基づいて、前記第1の結果データの組又は前記第2の結果データの組の一方を選択して出力し他方を破棄する
    ことを特徴とする時系列データ処理方法。
  8.  第1の処理を実行して第1の結果データを出力する第1の処理手段、及び第2の処理を実行して第2の結果データを出力する第2の処理手段を備える時系列データ処理装置が備えるコンピュータを、
     外部から処理の変更の指示を受けたとき、前記第1の処理が停止可能か否かを判断し、前記第1の結果データに前記第1の処理の状態を表す第1の識別情報を付加して第1の結果データの組を生成し、前記第2の結果データに前記第2の処理の状態を表す第2の識別情報を付加して第2の結果データの組を生成する制御手段、及び
     外部へ出力すべき結果データを指定する第3の識別情報を記録し、前記第1の結果データの組又は前記第2の結果データの組が到着したとき、前記第1の識別情報と前記第3の識別情報との比較結果及び前記第2の識別情報と前記第3の識別情報との比較結果に基づいて、前記第1の結果データの組又は前記第2の結果データの組の一方を選択して出力し他方を破棄する選択手段と、
    として機能させるための時系列データ処理プログラムを格納した非一時的な記憶媒体。
PCT/JP2013/005439 2012-09-18 2013-09-13 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムの記憶媒体 WO2014045556A1 (ja)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2014536587A JP6036835B2 (ja) 2012-09-18 2013-09-13 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラム
US14/427,236 US20150248441A1 (en) 2012-09-18 2013-09-13 Time-series data processing device, time-series data processing method and medium for storing time-series data processing program

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2012204425 2012-09-18
JP2012-204425 2012-09-18

Publications (1)

Publication Number Publication Date
WO2014045556A1 true WO2014045556A1 (ja) 2014-03-27

Family

ID=50340898

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2013/005439 WO2014045556A1 (ja) 2012-09-18 2013-09-13 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラムの記憶媒体

Country Status (3)

Country Link
US (1) US20150248441A1 (ja)
JP (1) JP6036835B2 (ja)
WO (1) WO2014045556A1 (ja)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6130859B2 (ja) 2012-01-17 2017-05-17 コーニンクレッカ フィリップス エヌ ヴェKoninklijke Philips N.V. 調節可能な分注ノズル
US11086815B1 (en) * 2019-04-15 2021-08-10 Xilinx, Inc. Supporting access to accelerators on a programmable integrated circuit by multiple host processes

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000137620A (ja) * 1998-08-24 2000-05-16 Hitachi Ltd トランザクション処理システムのプログラム変更方法、システム及び記憶媒体
JP2004078550A (ja) * 2002-08-19 2004-03-11 Nec Engineering Ltd ソフトウェア更新システム
JP2006053873A (ja) * 2004-08-16 2006-02-23 Fujitsu Ltd 機能装置、機能維持方法及び機能維持プログラム
JP2006085574A (ja) * 2004-09-17 2006-03-30 Ip Flex Kk データ処理システムおよびその制御方法
JP2006522416A (ja) * 2003-04-02 2006-09-28 ビーチ・アンリミテッド・エルエルシー ディジタル・メディア・サーバのアップグレード
JP2012146020A (ja) * 2011-01-07 2012-08-02 Olympus Corp 信号処理回路

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1530761A4 (en) * 2001-09-19 2008-01-23 Bay Microsystems Inc VERTICAL INSTRUCTION AND DATA PROCESSING IN A NETWORK PROCESSOR ARCHITECTURE
JP2003223236A (ja) * 2002-01-30 2003-08-08 Matsushita Electric Ind Co Ltd データ処理システム
US20050076020A1 (en) * 2003-08-15 2005-04-07 Jason Huntley Digital data vending system and method of selling digital data files
US8037056B2 (en) * 2005-02-18 2011-10-11 International Business Machines Corporation Online repair of a replicated table
US20070022135A1 (en) * 2005-07-25 2007-01-25 Dale Malik Systems and methods for organizing and annotating an information search
US8151323B2 (en) * 2006-04-12 2012-04-03 Citrix Systems, Inc. Systems and methods for providing levels of access and action control via an SSL VPN appliance
JP4101283B1 (ja) * 2006-11-29 2008-06-18 デュアキシズ株式会社 試験装置
US8301593B2 (en) * 2008-06-12 2012-10-30 Gravic, Inc. Mixed mode synchronous and asynchronous replication system
US8161195B2 (en) * 2009-03-25 2012-04-17 Microsoft Corporation Adaptable management in sync engines
US8543539B2 (en) * 2009-09-16 2013-09-24 Business Objects Software Limited Method and system for capturing change of data
US8819042B2 (en) * 2010-04-23 2014-08-26 Bank Of America Corporation Enhanced data comparison tool
US9075860B2 (en) * 2012-10-18 2015-07-07 Oracle International Corporation Data lineage system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000137620A (ja) * 1998-08-24 2000-05-16 Hitachi Ltd トランザクション処理システムのプログラム変更方法、システム及び記憶媒体
JP2004078550A (ja) * 2002-08-19 2004-03-11 Nec Engineering Ltd ソフトウェア更新システム
JP2006522416A (ja) * 2003-04-02 2006-09-28 ビーチ・アンリミテッド・エルエルシー ディジタル・メディア・サーバのアップグレード
JP2006053873A (ja) * 2004-08-16 2006-02-23 Fujitsu Ltd 機能装置、機能維持方法及び機能維持プログラム
JP2006085574A (ja) * 2004-09-17 2006-03-30 Ip Flex Kk データ処理システムおよびその制御方法
JP2012146020A (ja) * 2011-01-07 2012-08-02 Olympus Corp 信号処理回路

Also Published As

Publication number Publication date
JP6036835B2 (ja) 2016-11-30
JPWO2014045556A1 (ja) 2016-08-18
US20150248441A1 (en) 2015-09-03

Similar Documents

Publication Publication Date Title
TWI515669B (zh) 用於狀態機中資料分析之系統與方法
JP5688432B2 (ja) プログラマブル回路、関連計算マシン、並びに、方法
JP5568502B2 (ja) プログラマブル回路、関連計算マシン、並びに、方法
EP1861786B1 (en) Enforcing strongly-ordered requests in a weakly-ordered processing system
JP5131188B2 (ja) データ処理装置
CN105637524B (zh) 硬件平台中的资产管理设备和方法
JP2018514867A (ja) Dspエンジンおよび改良されたコンテキストスイッチ能力を有する中央処理ユニット
EP2442231A1 (en) Reordering arrangement
WO2024001024A1 (zh) 在区块链系统中执行交易的方法、区块链系统和节点
JP2006338538A (ja) ストリームプロセッサ
JP6127409B2 (ja) クロック・ネットワーク・メタ合成のためのシステムおよび方法
WO2013187191A1 (ja) I/oデバイス、プログラマブルロジックコントローラ及び演算方法
KR102539571B1 (ko) 네트워크 온칩 데이터 처리 방법 및 장치
KR102539572B1 (ko) 네트워크 온칩 데이터 처리 방법 및 장치
JP2007034392A (ja) 情報処理装置及びデータ処理方法
JP6036835B2 (ja) 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラム
CN107204922B (zh) 用于过滤事务的装置和方法
JP3693013B2 (ja) データ処理システム、アレイ型プロセッサ、データ処理装置、コンピュータプログラム、情報記憶媒体
JP6040980B2 (ja) 時系列データ処理装置、時系列データ処理方法及び時系列データ処理プログラム
US7774529B2 (en) Bus communication apparatus that uses shared memory
US20170090756A1 (en) Computer and computer system
KR102539574B1 (ko) 네트워크 온칩 데이터 처리 방법 및 장치
KR102539573B1 (ko) 네트워크 온칩 데이터 처리 방법 및 장치
JP6394599B2 (ja) 時系列データ処理装置、時系列データ処理方法、および、プログラム
JP2003015968A (ja) バスシミュレータ

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13839987

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2014536587

Country of ref document: JP

Kind code of ref document: A

WWE Wipo information: entry into national phase

Ref document number: 14427236

Country of ref document: US

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 13839987

Country of ref document: EP

Kind code of ref document: A1