A data processing method, comprising: receiving data in a data flow from one or more data sources (101, 210), wherein the data flow includes one or more image frames and is configured based on a time sequence; storing the received data into a buffer (302, 402, 606) in a memory (310, 410), wherein the buffer (302, 402, 606) is configured to have a maximum image frame number; receiving, at a first time (214, tg), a control signal (203, 306, 406), which is associated with a first timestamp, wherein the first timestamp indicates the first time (214, tg); dynamically determining, based on features of the dataflow and/or the available memory (310, 410), a time period (205, T) from a starting time to an ending time; determining, via a data processor, a first data segment (211, 311, 411) by applying the first timestamp on the data flow, wherein the first data segment (211, 311, 411) is associated with the time period (205, T) in the time sequence that includes the first time (214, tg), and wherein the first data segment (211, 311, 411) includes a) data stored in the buffer (302, 402) that was received before the first time (214, tg) in a first duration (Tr) which equals to the maximum image frame number divided by an image speed and b) data of the data flow that is received after the first time (214, tg) in a second duration (Tc) that is a difference between the time period (205, T) and the first duration (Tr); and creating a copy in the memory (310, 410) for the first data segment (211, 311, 411) when the control signal (203, 306, 406) is received, before exporting the first data segment (211, 311, 411), wherein the first data segment (211, 311, 411) is exported by saving the first data segment (211, 311, 411) into a storage medium (304, 404) that is physically connected to the memory (310, 410), and/or sending the first data segment (211, 311, 411) to a remote server (305, 405) via a network. receiving data in a data flow from one or more data sources (101, 210), wherein the data flow includes one or more image frames and is configured based on a time sequence; storing the received data into a buffer (302, 402, 606) in a memory (310, 410), wherein the buffer (302, 402, 606) is configured to have a maximum image frame number; receiving, at a first time (214, tg), a control signal (203, 306, 406), which is associated with a first timestamp, wherein the first timestamp indicates the first time (214, tg); dynamically determining, based on features of the dataflow and/or the available memory (310, 410), a time period (205, T) from a starting time to an ending time; determining, via a data processor, a first data segment (211, 311, 411) by applying the first timestamp on the data flow, wherein the first data segment (211, 311, 411) is associated with the time period (205, T) in the time sequence that includes the first time (214, tg), and wherein the first data segment (211, 311, 411) includes a) data stored in the buffer (302, 402) that was received before the first time (214, tg) in a first duration (Tr) which equals to the maximum image frame number divided by an image speed and b) data of the data flow that is received after the first time (214, tg) in a second duration (Tc) that is a difference between the time period (205, T) and the first duration (Tr); and creating a copy in the memory (310, 410) for the first data segment (211, 311, 411) when the control signal (203, 306, 406) is received, before exporting the first data segment (211, 311, 411), wherein the first data segment (211, 311, 411) is exported by saving the first data segment (211, 311, 411) into a storage medium (304, 404) that is physically connected to the memory (310, 410), and/or sending the first data segment (211, 311, 411) to a remote server (305, 405) via a network. saving the first data segment (211, 311, 411) into a storage medium (304, 404) that is physically connected to the memory (310, 410), and/or sending the first data segment (211, 311, 411) to a remote server (305, 405) via a network.