[go: up one dir, main page]

CN112463746B - File storage and generation method and device and electronic equipment - Google Patents

File storage and generation method and device and electronic equipment Download PDF

Info

Publication number
CN112463746B
CN112463746B CN202011459859.0A CN202011459859A CN112463746B CN 112463746 B CN112463746 B CN 112463746B CN 202011459859 A CN202011459859 A CN 202011459859A CN 112463746 B CN112463746 B CN 112463746B
Authority
CN
China
Prior art keywords
file
target
stored
operation sequence
determining
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN202011459859.0A
Other languages
Chinese (zh)
Other versions
CN112463746A (en
Inventor
胡钊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou Haikang Auto Software Co ltd
Original Assignee
Hangzhou Haikang Auto Software Co ltd
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 Hangzhou Haikang Auto Software Co ltd filed Critical Hangzhou Haikang Auto Software Co ltd
Priority to CN202011459859.0A priority Critical patent/CN112463746B/en
Publication of CN112463746A publication Critical patent/CN112463746A/en
Application granted granted Critical
Publication of CN112463746B publication Critical patent/CN112463746B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/17Details of further file system functions
    • G06F16/172Caching, prefetching or hoarding of files
    • 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/14Details of searching files based on file metadata
    • G06F16/148File search processing
    • 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/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Library & Information Science (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the invention provides a file storage and generation method, a device, electronic equipment and a storage medium, wherein the method comprises the following steps: acquiring a file to be stored; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not affected even if the system time is abnormal because the operation sequence has no dependency on the system time, so that the cyclic coverage storage of the files can be successfully completed, and the problem of the files can be avoided.

Description

File storage and generation method and device and electronic equipment
Technical Field
The present invention relates to the field of file cycle overlay storage technologies, and in particular, to a method and an apparatus for storing and generating a file, and an electronic device.
Background
The file cycle overlay storage is a storage mode of cycle overlay for the case that the storage space is limited, the space occupied by the stored file is large, and the new file is difficult to store again. Namely deleting the stored file and storing the new file into the storage space, thereby achieving the effect that the stored file is covered by the new file.
The current cyclic coverage technology performs cyclic coverage based on the sequence of the generation time, specifically, the generation time of the file is recorded when the file is generated, when the cyclic coverage is needed, the file with the earliest generation time is searched according to the recorded generation time, then the file is deleted, and a new file is stored in the storage space.
When the system Time is abnormal, for example, the RTC (Real Time Clock) is abnormal, the RTC is electronic deficient, the timing is wrong, the Time zone is crossed by the device, and the like, the adoption of the above cyclic coverage technology can cause the abnormal cyclic coverage storage of the file, so that the problem of file loss occurs.
Disclosure of Invention
The embodiment of the invention aims to provide a file storage method, a device, electronic equipment and a storage medium, which are used for solving the problem of abnormality in file cycle coverage storage. The specific technical scheme is as follows:
In a first aspect, an embodiment of the present invention provides a method for storing a file, where the method includes:
acquiring a file to be stored;
determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file;
deleting the target file from the target storage space, and storing the file to be stored into the target storage space.
Optionally, the step of determining the target file based on the operation sequence of each pre-recorded stored file includes:
determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number;
and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
Optionally, the step of determining, as the target sequence number, the earliest operation sequence number among the operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files includes:
Determining an operation sequence number at the head of a queue of an operation sequence queue as a target sequence number, wherein the operation sequence queue is used for recording the operation sequence number of each stored file;
after the step of storing the file to be stored in the target storage space, the method further includes:
and determining the sum of the operation sequence number and 1 at the tail of the operation sequence queue as the operation sequence number of the file to be stored, and adding the operation sequence number of the file to be stored to the tail of the operation sequence queue.
Optionally, the step of determining the target file based on the operation sequence of each pre-recorded stored file includes:
determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number;
determining a stored file corresponding to the target sequence number as a first target file according to the corresponding relation between the pre-recorded operation sequence number and the file;
determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each stored file recorded in advance;
Determining a stored file corresponding to the target time as a second target file according to the corresponding relation between the pre-recorded generation time and the file;
determining the file as a determination target file under the condition that the first target file and the second target file are the same file;
and determining the target file based on the priority of the operation sequence and the priority of the generation time of each stored file under the condition that the first target file and the second target file are different files.
Optionally, the step of determining the target file based on the priority of the operation sequence and the priority of the generation time of each stored file includes:
determining target files from the first target file and the second target file based on the preset priority of the operation sequence and the preset priority of the generation time of each stored file; or alternatively, the first and second heat exchangers may be,
outputting alarm information; and acquiring the priority determined by the user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority, wherein the alarm information is used for indicating the priority of determining the operation sequence of each stored file and the priority of generating time.
Optionally, the step of determining the target file based on the operation sequence of each pre-recorded stored file includes:
under the condition that the system time is normal, determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each pre-recorded stored file; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file;
under the condition of abnormal system time, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
Optionally, the step of determining the stored file corresponding to the target sequence number according to the corresponding relation between the pre-recorded operation sequence number and the file includes:
searching a file name corresponding to the target sequence number from a pre-established operation sequence record file, and determining the file corresponding to the file name as a stored file corresponding to the target sequence number, wherein the operation sequence record file records the corresponding relation between the operation sequence number and the file; or alternatively, the first and second heat exchangers may be,
Acquiring operation sequence numbers included in the stored files, searching the target sequence numbers from the acquired operation sequence numbers, and determining the stored files including the target sequence numbers as stored files corresponding to the target sequence numbers; or alternatively, the first and second heat exchangers may be,
acquiring file names of the stored files, and analyzing the file names to obtain operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
Optionally, the order of operations is determined based on an acquisition time of a data stream that generated the respective stored file; or alternatively, the first and second heat exchangers may be,
the order of operations is determined based on the time of generation of the respective stored file.
In a second aspect, an embodiment of the present invention provides a file generating method, where the method includes:
acquiring a data stream for generating a file;
generating a file based on the data stream under the condition that the data stream meets a preset generation condition;
determining the operation sequence of the file, and recording the operation sequence, wherein the operation sequence is used for identifying the generation sequence of the generated file.
Optionally, the step of determining the operation sequence of the file includes:
determining an operation sequence of the file based on the acquisition time of the data stream; or alternatively, the first and second heat exchangers may be,
and determining the operation sequence of the file based on the generation time of the file.
Optionally, the data stream is multiplexed;
the step of determining the operation sequence of the file based on the acquisition time of the data stream includes:
determining the operation sequence of a third target file based on a first preset sequence determining rule under the condition that the third target file with the same acquisition time of the data stream exists;
the step of determining the operation sequence of the file based on the generation time of the file comprises the following steps:
and determining the operation sequence of the fourth target file based on a second preset sequence determination rule under the condition that the fourth target file with the same generation time exists.
In a third aspect, an embodiment of the present invention provides a file storage device, including:
the file acquisition module is used for acquiring a file to be stored;
the file determining module is used for determining the target file based on the operation sequence of each pre-recorded stored file under the condition that the target storage space meets the preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file;
And the file storage module is used for deleting the target file from the target storage space and storing the file to be stored into the target storage space.
Optionally, the file determining module includes:
a first operation sequence number determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of respective stored files based on an operation sequence of respective stored files recorded in advance;
and the file determining unit is used for determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
Optionally, the operation sequence number determining unit includes:
an operation sequence number determining subunit, configured to determine an operation sequence number located at a queue head of an operation sequence queue as a target sequence number, where the operation sequence queue is used to record the operation sequence numbers of each stored file;
the apparatus further comprises:
and the operation sequence number adding subunit is used for determining the addition of the operation sequence number positioned at the tail of the operation sequence queue and 1 as the operation sequence number of the file to be stored after the file to be stored is stored in the target storage space, and adding the operation sequence number of the file to be stored to the tail of the operation sequence queue.
Optionally, the file determining module includes:
a second operation sequence number determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files;
the first target file determining unit is used for determining a stored file corresponding to the target sequence number according to the corresponding relation between the pre-recorded operation sequence number and the file, and the stored file is used as a first target file;
a target time determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance;
a second target file determining unit, configured to determine, according to a pre-recorded correspondence between the generation time and the file, a stored file corresponding to the target time as a second target file;
a third target file determining unit, configured to determine, when the first target file and the second target file are the same file, the file as a determination target file;
and a fourth target file determining unit configured to determine a target file based on the priority of the operation order and the priority of the generation time of each stored file, in the case where the first target file and the second target file are different files.
Optionally, the fourth object file determining unit includes:
a target file determining subunit, configured to determine a target file from the first target file and the second target file based on a preset priority of an operation sequence of each stored file and a preset priority of a generation time; or alternatively, the first and second heat exchangers may be,
the alarm device is used for outputting alarm information; and acquiring the priority determined by the user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority, wherein the alarm information is used for indicating the priority of determining the operation sequence of each stored file and the priority of generating time.
Optionally, the file determining module includes:
a fifth target file determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance, in a case where the system time is normal; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file;
a sixth target file determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on an operation sequence of the respective stored files recorded in advance in the case of abnormality of the system time; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
Optionally, the file determining unit includes:
a file determining subunit, configured to find a file name corresponding to the target sequence number from a pre-created operation sequence record file, and determine the file corresponding to the file name as a stored file corresponding to the target sequence number, where the operation sequence record file records a correspondence between an operation sequence number and a file; or alternatively, the first and second heat exchangers may be,
the method comprises the steps of obtaining operation sequence numbers included in all stored files, searching the target sequence numbers from the obtained operation sequence numbers, and determining the stored files including the target sequence numbers as stored files corresponding to the target sequence numbers; or alternatively, the first and second heat exchangers may be,
the method comprises the steps of obtaining file names of all stored files, and analyzing the file names to obtain operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
In a fourth aspect, an embodiment of the present invention provides a file generating apparatus, including:
the data acquisition module is used for acquiring a data stream for generating a file;
The file generation module is used for generating a file based on the data stream under the condition that the data stream meets the preset generation condition;
the sequence determining module is used for determining the operation sequence of the files and recording the operation sequence, wherein the operation sequence is used for identifying the generation sequence of the generated files.
Optionally, the order determining module includes:
a first order determining unit configured to determine an operation order of the file based on an acquisition time of the data stream; or alternatively, the first and second heat exchangers may be,
and a second order determining unit for determining an operation order of the files based on the generation time of the files.
Optionally, the data stream is multiplexed;
the first order determining unit includes:
a first order determining subunit, configured to determine, in the case where there is a third target file with the same acquisition time of the data stream, an operation order of the third target file based on a first preset order determining rule;
the second order determining unit includes:
and the second order determining subunit is used for determining the operation order of the fourth target files based on a second preset order determining rule under the condition that the fourth target files with the same generation time exist.
In a fifth aspect, an embodiment of the present invention provides an electronic device, including a processor and a memory, wherein:
a memory for storing a computer program;
a processor configured to implement the method steps of any one of the first or second aspects when executing a program stored on a memory.
In a sixth aspect, embodiments of the present invention provide a computer readable storage medium having a computer program stored therein, the computer program implementing the method steps of any of the first or second aspects above when being executed by a processor.
The embodiment of the invention has the beneficial effects that:
in the scheme provided by the embodiment of the invention, the electronic equipment can acquire the file to be stored; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided. Of course, it is not necessary for any one product or method of practicing the invention to achieve all of the advantages set forth above at the same time.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are necessary for the description of the embodiments or the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention and that other embodiments may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart of a method for storing files according to an embodiment of the present invention;
FIG. 2 is a specific flowchart of step S102 in the embodiment shown in FIG. 1;
FIG. 3 is a schematic diagram of a file storage method according to the embodiment shown in FIG. 2;
FIG. 4 is another specific flowchart of step S102 in the embodiment shown in FIG. 1;
FIG. 5 is a schematic diagram of a file recorded in accordance with the operational sequence of the embodiment of FIG. 2;
FIG. 6 is a schematic diagram of a stored file according to the embodiment of FIG. 2;
FIG. 7 is a schematic diagram of a video file according to the embodiment shown in FIG. 2;
FIG. 8 is a flowchart of a method for generating a file according to an embodiment of the present invention;
FIG. 9 is a schematic diagram of a file storage device according to an embodiment of the present invention;
FIG. 10 is a schematic diagram showing a specific configuration of the file determination module 920 in the embodiment shown in FIG. 9;
FIG. 11 is a schematic diagram of a file generating apparatus according to an embodiment of the present invention;
fig. 12 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
In order to avoid abnormality in file cycle overlay storage, embodiments of the present invention provide a method, an apparatus, an electronic device, a computer readable storage medium, and a computer program product for file storage and file generation. The following first describes a file storage method provided by an embodiment of the present invention.
The method for storing the file provided by the embodiment of the invention can be applied to any electronic equipment needing file storage, particularly electronic equipment with limited storage space, for example, vehicle-mounted equipment, monitoring equipment and the like, and is called as electronic equipment for the sake of clarity of description.
As shown in fig. 1, a file storage method includes:
s101, acquiring a file to be stored;
s102, determining a target file based on the operation sequence of each pre-recorded stored file under the condition that the target storage space meets the preset cycle coverage storage condition;
the operation sequence is used for identifying the generation sequence of each stored file.
S103, deleting the target file from the target storage space, and storing the file to be stored into the target storage space.
In the scheme provided by the embodiment of the invention, the electronic equipment can acquire the file to be stored; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
When the file is required to be stored, the electronic device may acquire the file to be stored, that is, the file to be stored, where the file to be stored may be a video file, an image file, an audio file, or the like, which is not limited herein.
For example, in the case where the electronic device is a vehicle recorder, the file to be stored may be a newly generated or newly acquired video file; in the case where the electronic device is a monitoring camera, the file to be stored may be a new monitoring video file.
After the file to be stored is obtained, in order to determine whether the cycle coverage storage is required, the electronic device may determine whether the target storage space meets a preset cycle coverage storage condition. The target storage space is the storage space needed to store the file to be stored. Such as memory, magnetic disk, etc., in an electronic device, without specific limitation herein.
The preset cycle overlay storage condition may include at least one of: the occupation amount of the target storage space reaches a preset threshold value, the residual capacity of the target storage space is not larger than the size of the file to be stored, and a cyclic coverage storage instruction is acquired.
In the case where the target storage space satisfies any of the above-mentioned preset loop coverage storage conditions, it is indicated that the loop coverage storage is required at this time, so the electronic device may execute the above-mentioned step S102 to determine the target file to be deleted.
Specifically, the electronic device may determine the target file based on a pre-recorded operation order of each stored file, where the operation order is used to identify a generation order of each stored file. In one embodiment, the electronic device may record the order of operation of each stored file at the time of generation, such that the order of operation may identify the order of generation of each stored file. Wherein the sequence of operations may be used to represent the sequence of operations for each stored file.
In this way, the electronic device may determine the target file based on the operation sequence of each stored file, and in one embodiment, since the file generated earliest in the target storage space is the file to be deleted when performing the cyclic overlay storage, the electronic device may determine the file corresponding to the operation sequence with the earliest identification generation sequence as the target file.
In one embodiment, the electronic device may acquire a data stream, for example, a video stream acquired by a camera, and further generate a file based on the data stream and store the file when the data stream meets a preset generation condition. Wherein the preset generating conditions may be for a preset period of time, for example, 10 minutes, 15 minutes, 20 minutes, etc. When the acquired time length corresponding to the data stream reaches the preset time period, the data stream can be determined to meet the preset generation condition, and then the data stream is generated into a file and stored.
The earlier the acquisition time of the data stream, the earlier the time for generating the file by the data stream is, so the operation sequence of the stored files can be determined based on the acquisition time of the data stream and also can be determined based on the generation time of the files, which is reasonable, and the generation sequence of each stored file can be accurately identified.
Further, in the step S103, the electronic device may delete the target file from the target storage space, and store the file to be stored in the target storage space, thereby completing the cyclic overlay storage of the file. In the file storage method provided by the embodiment of the invention, the operation sequence is used for identifying the generation sequence of each stored file, instead of the generation time, the operation sequence has no dependence on the system time and is irrelevant to the system time of the electronic equipment, so that even if the system time is abnormal, the operation sequence is not influenced, and for the scheme of identifying the generation sequence of each stored file by using the generation time at present, if the system time is abnormal, the cyclic coverage storage of the file is abnormal.
For example, the electronic device stores the file 1 and the file 2, and the generation time is 30 minutes at 17 hours of 12 months and 9 days in 2020 and 35 minutes at 17 hours of 9 months in 2020, and if the system time of the electronic device is abnormal and the system time becomes 17 minutes at 17 hours of 9 months in 2020, the generation time of the file 3 generated at this time is 17 minutes at 17 hours of 9 months in 2020. Next, when the file 4 needs to be circularly stored in an overlapping mode, the electronic device finds the file 3 with the earliest generation time and deletes the file. In practice, however, file 1 is the earliest file generated, and it can be seen that this approach will result in errors in the cyclical overwrite storage of the file.
By adopting the scheme provided by the embodiment of the invention, even if the system time of the electronic equipment is abnormal, the system time is changed into 17 points of 9 days of 12 months in 2020, and the operation sequence is irrelevant to the system time, the file 3 can accept the file 1 and the file 2 to continuously record the operation sequence of the file 3 when being generated, for example, the operation sequences of the file 1 and the file 2 are respectively 1 and 2, the operation sequence of the file 3 is 3, and then the file 4 needs to be circularly covered and stored when being generated, so that the electronic equipment can find the earliest generated file identified by the operation sequence, namely the file 1 and delete the file. In practice, the page 1 of the file is the earliest file, so that the cyclic coverage storage of the file can be successfully completed, the problem of abnormal cyclic coverage storage can be avoided, and the problem of file loss can be avoided.
As shown in fig. 2, the step of determining the target file based on the operation sequence of each pre-recorded stored file may include:
s201, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number;
in one embodiment, the sequence of operations may be represented by an operation number to facilitate recording and processing. The electronic device can determine the earliest operation number among the operation numbers of the respective stored files as the target number based on the operation order of the respective stored files recorded in advance.
The electronic device may determine an operation sequence number for each file in the order of the generation time of the respective files from early to late, and in one embodiment, each time a file is stored, the electronic device may determine an operation sequence number for the file, where the operation sequence number is the stored sequence number of the last file plus 1.
For example, if the number of currently stored files in the target storage space is 6, and the operation sequence numbers are 1-6, then the electronic device may determine that the operation sequence number of the file a is 6+1=7 when the stored file a is stored. When the file B to be stored is acquired, if it is determined that the target storage space satisfies the preset cycle coverage storage condition, the electronic device may determine that the operation sequence number 1 is the target sequence number because the operation sequence number 1 is the earliest operation sequence number.
S202, determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
In order to conveniently determine the stored file corresponding to the target sequence number, the corresponding relation between the operation sequence number and the file can be recorded in advance, so that the electronic equipment can determine the stored file corresponding to the target sequence number as the target file based on the corresponding relation between the operation sequence number and the file after determining the target sequence number.
For example, the correspondence between the pre-recorded operation numbers and the files may be as follows:
if the target sequence number is determined to be 1, the electronic device can determine that the file corresponding to the target sequence number 1 is the file A1 according to the corresponding relation recorded in the table, and the file A1 is the target file, that is, the file to be deleted.
It can be seen that, in this embodiment, the electronic device may determine, as the target sequence number, the earliest operation sequence number among the operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files, and further determine, as the target file, the stored file corresponding to the target sequence number according to the correspondence between the pre-recorded operation sequence numbers and the files. Thus, the electronic device can accurately determine the target file to be deleted based on the operation sequence of each stored file.
As an implementation manner of the embodiment of the present invention, the step of determining, as the target sequence number, the earliest operation sequence number among the operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files may include:
and determining the operation sequence number at the head of the operation sequence queue as a target sequence number.
To facilitate recording the order of operations for each stored file, the electronic device may establish an order of operations queue for recording the order of operations for each stored file. Since the cyclic overlay storage of files may be performed multiple times, some stored files may be deleted, some new files may be stored in the target storage space, and thus the operation sequence number of each stored file in the target storage space is changed, and in order to accurately record the operation sequence of each stored file, the operation sequence queue may be a first-in first-out queue.
Thus, the operation sequence number at the head of the queue of the operation sequence queue is the operation sequence number of the file with the earliest time generated in the files currently stored in the target storage space, and the operation sequence number at the tail of the queue of the operation sequence queue is the operation sequence number of the file with the latest time generated in the files currently stored in the target storage space.
For example, as shown in fig. 3, operation numbers 1, 2, 3, and 4 … N are recorded in the operation sequence queue 310 from the head to the tail. The electronic device may determine the operation sequence number 1 at the head of the operation sequence queue as the target sequence number. Furthermore, the electronic device may delete the target file corresponding to the target sequence number 1, and store the file P to be stored in the target storage space.
Accordingly, after the step of storing the file to be stored in the target storage space, the method may further include:
and determining the sum of the operation sequence number and 1 at the tail of the operation sequence queue as the operation sequence number of the file to be stored, and adding the operation sequence number of the file to be stored to the tail of the operation sequence queue.
Because the target file is deleted from the target storage space and a new file is stored, namely the file to be stored, in order to ensure the accuracy of the operation sequence number recorded in the operation sequence queue, the electronic device can determine the operation sequence number of the file to be stored and add the operation sequence number to the tail of the operation sequence queue. Since the operation sequence queue is a first-in first-out queue, the target sequence number at the head of the operation sequence queue is fetched from the operation sequence queue.
In an embodiment, the file to be stored is the file currently stored latest, and the generation time is the latest, so the corresponding operation sequence number should be the largest, that is, the corresponding operation sequence number should be the sum of the operation sequence number at the tail of the operation sequence queue and 1, and then the electronic device may determine the sum of the operation sequence number at the tail of the operation sequence queue and 1 as the operation sequence number of the file to be stored.
For example, as shown in fig. 3, after storing the file P to be stored in the target storage space, the electronic device may determine that the sum (n+1) of the operation sequence numbers N and 1 located at the tail of the operation sequence queue is the operation sequence number of the file P to be stored, and add (n+1) to the tail of the operation sequence queue to obtain the operation sequence queue 320.
When the next file Q to be stored arrives, the electronic device may determine that the operation sequence number 2 at the queue head of the operation sequence queue 320 is the target sequence number, delete the target file corresponding to the target sequence number 2, and store the file Q to be stored in the target storage space. And determines the sum (n+2) of the operation sequence numbers (n+1) and 1 at the end of the operation sequence queue as the operation sequence number of the file Q to be stored, and adds (n+2) to the end of the operation sequence queue 320.
It can be seen that, in this embodiment, the electronic device may determine the operation sequence number at the head of the queue of the operation sequence queue as the target sequence number, further, after storing the file to be stored in the target storage space, determine the sum of the operation sequence number at the tail of the queue of the operation sequence queue and 1 as the operation sequence number of the file to be stored, and add the operation sequence number of the file to be stored to the tail of the queue of the operation sequence queue. Therefore, the operation sequence queue can be utilized to record the operation sequence number of each file, the operation sequence number of each file can be accurately and rapidly recorded, and the smooth and accurate circulation coverage storage of the files is ensured.
As shown in fig. 4, the step of determining the target file based on the operation sequence of each pre-recorded stored file may include:
s401, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number;
s402, determining a stored file corresponding to the target sequence number as a first target file according to the corresponding relation between the pre-recorded operation sequence number and the file;
Since the specific manner of determining the target sequence number and the first target file has been described in detail in the above embodiments, details are not described here.
S403, determining the earliest generation time in the generation time of each stored file as a target time based on the pre-recorded generation time of each stored file;
in order to determine the target file to be deleted more accurately, the electronic device may also record the corresponding relationship between the generation time and the file. As an embodiment, the electronic device may record the generation time of a file every time the file is generated, and the electronic device may delete the recorded generation time of the file every time the file is deleted.
In this way, in the case where the target storage space satisfies the preset cycle coverage storage condition, the electronic device can determine, as the target time, the earliest generation time among the generation times of the respective stored files based on the generation times of the respective stored files recorded in advance.
S404, determining a stored file corresponding to the target time as a second target file according to the corresponding relation between the pre-recorded generation time and the file;
then, the electronic device can determine the stored file corresponding to the target time as the second target file according to the corresponding relation between the pre-recorded generation time and the file. For example, the correspondence between the pre-recorded generation time and the file is shown in the following table:
Then the electronic device can determine the second target file to be file A1 based on the table if the target time is time a.
S405, determining the file as a determination target file when the first target file and the second target file are the same file;
after determining the first target file and the second target file, the electronic device may determine whether the first target file and the second target file are the same file, if the first target file and the second target file are the same file, which indicates that the files to be deleted determined based on the generation time and the operation sequence of each stored file are consistent, which indicates that the records of the generation time and the operation sequence of each stored file are accurate, and at this time, the electronic device may determine the files as the determination target files.
S406, determining the target file based on the priority of the operation sequence and the priority of the generation time of each stored file when the first target file and the second target file are different files.
If the first target file and the second target file are not the same file, it is indicated that the files to be deleted determined based on the generation time and the operation sequence of each stored file are inconsistent, and then it is indicated that the generation time and the record of the operation sequence of each stored file may be wrong, at this time, in order to determine the target file, the electronic device may determine the target file based on the priority of the operation sequence and the priority of the generation time of each stored file.
In one embodiment, the electronic device may determine, as the target file, a file corresponding to a higher one of the generation time and the priority of the operation order of each stored file. For example, the order of operation of each stored file is higher in priority than the generation time of each stored file, and the electronic device may determine that the first target file is the target file to be deleted.
It can be seen that, in this embodiment, the electronic device may consider the operation sequence and the generation time of each stored file at the same time, and determine the target file based on the priority of the operation sequence and the priority of the generation time of each stored file when the first target file and the second target file are different files. Therefore, the accuracy of determining the target file can be further improved, the target file can be determined when the result corresponding to the operation sequence and the generation time is contradictory, and the cyclic coverage and storage of the file can be ensured to be smoothly carried out.
As an implementation manner of the embodiment of the present invention, the step of determining the target file based on the priority of the operation sequence and the priority of the generation time of each stored file may at least include the following two implementations:
First embodiment: and determining target files from the first target file and the second target file based on the preset priority of the operation sequence and the preset priority of the generation time of each stored file.
In order to facilitate the operation and improve the efficiency of file cycle coverage storage, the priority of the operation sequence and the priority of the generation time of each stored file may be preset, so the electronic device may determine the target file from the first target file and the second target file based on the preset priority of the operation sequence and the preset priority of the generation time of each stored file.
If the priority of the operation sequence of each stored file is higher than the priority of the generation time, the first target file may be determined to be the target file to be deleted. If the priority of the operation sequence of each stored file is lower than the priority of the generation time, the second target file may be determined to be the target file to be deleted.
Second embodiment: outputting alarm information; and acquiring the priority determined by the user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority.
In order to enable the user to select a cyclic overlay storage policy to be used, the electronic device may output alarm information when the first target file and the second target file are different files, where the alarm information is used to instruct the user to determine a priority of an operation sequence and a priority of a generation time of each stored file.
For example, the electronic device may display a priority selection button for the user to select the loop overlay storage policy that the user wants to use, and the priority of the loop overlay storage policy selected by the user is then a higher priority. In one embodiment, the electronic device may also display the determined first and second target files for viewing by the user.
After the user selects the cyclic coverage storage policy to be used, the electronic device can acquire the priority determined by the user based on the alarm information, and further can determine the target file from the first target file and the second target file based on the priority.
If the priority determined by the user based on the alarm information is the priority of the operation order higher than the priority of the generation time, it may be determined that the first target file is the target file to be deleted. If the priority determined by the user based on the alarm information is that the priority of the operation order is lower than the priority of the generation time, it may be determined that the second target file is a target file to be deleted.
In this embodiment, the electronic device may determine the target file from the first target file and the second target file by at least two embodiments, and may also meet the needs of the user, thereby improving the user experience.
As an implementation manner of the embodiment of the invention, the alarm information can also comprise prompt information. The prompt information is used for prompting the user that the system time may be abnormal so that the user can process in time.
Under the condition that the first target file and the second target file are different files, the fact that the generation time and the record of the operation sequence of each stored file are possibly wrong is indicated, and the possibility of error is high because the record of the generation time depends on the system time, so that the system time of the electronic equipment is likely to be abnormal at the moment, and the electronic equipment can output prompt information so that a user can process in time.
As an implementation manner of the embodiment of the present invention, the step of determining the target file based on the operation sequence of each pre-recorded stored file may include:
under the condition that the system time is normal, determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each pre-recorded stored file; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file; under the condition of abnormal system time, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
Under the condition that the target storage space meets the preset cycle coverage storage condition, the electronic equipment can determine whether the current system time is abnormal or not. If no abnormality occurs in the system time, that is, in the case where the system time is normal, the generation time of each stored file recorded by the electronic device is accurate at this time, the electronic device can determine the earliest generation time among the generation times of each stored file based on the generation time of each stored file recorded in advance as the target time.
Further, a stored file corresponding to the target time is determined as the target file according to the correspondence between the pre-recorded generation time and the file. Since the specific manner of determining the target time and the target file has been described in detail in the above embodiments, a detailed description thereof is omitted herein.
If the system time is abnormal, the generation time of each stored file recorded by the electronic device is likely to be inaccurate, so the electronic device can determine the earliest operation sequence number among the operation sequence numbers of each stored file based on the operation sequence of each stored file recorded in advance as the target sequence number. Further, a stored file corresponding to the target sequence number is determined as the target file according to the correspondence between the pre-recorded operation sequence number and the file. Since the specific manner of determining the target sequence number and the target file has been described in detail in the above embodiments, details are not repeated here.
In order to ensure that when the system time is abnormal, the electronic device can determine the target file based on the operation sequence of each pre-recorded stored file, and when the system time is not abnormal, the electronic device determines the target file based on the generation time of each pre-recorded stored file, then deletes the target file and stores the file to be stored in the target storage space, and meanwhile, the electronic device updates the operation sequence number of each recorded file according to the recording mode of the operation sequence number recorded in the embodiment, so that when the system time is abnormal, the electronic device can quickly switch to a strategy for determining the target file based on the operation sequence of each pre-recorded stored file, and smooth file storage is ensured.
Therefore, in this embodiment, when the target storage space meets the preset cycle coverage storage condition, the electronic device may determine whether an abnormality occurs in the current system time, and further select a suitable cycle coverage storage policy according to whether an abnormality occurs in the current system time, so as to ensure that the target file is accurately determined, and further cycle coverage storage of the file is performed.
As an implementation manner of the embodiment of the present invention, the step of determining the stored file corresponding to the target sequence number according to the corresponding relationship between the pre-recorded operation sequence number and the file may at least include the following three manners:
The first way is: and searching a file name corresponding to the target sequence number from a pre-created operation sequence record file, and determining the file corresponding to the file name as a stored file corresponding to the target sequence number.
In order to facilitate recording the correspondence between the operation serial number and the file, the electronic device may pre-establish an operation sequence record file, where the operation sequence record file records the correspondence between the operation serial number and the file. Thus, the electronic device can search the file name corresponding to the target serial number from the pre-created operation sequence record file, and determine the file corresponding to the file name as the stored file corresponding to the target serial number.
The format of the operation sequence record file may be txt (text document), word, PDF (Portable Document Format, portable document), or the like, and is not particularly limited herein.
For example, as shown in fig. 5, the correspondence between the operation sequence number and the file may be recorded in the operation sequence record file 510, which may specifically be: AN operation sequence 1 corresponding to the file A1, AN operation sequence 2 corresponding to the file A2, AN operation sequence 3 corresponding to the file A3, AN operation sequence 4 … corresponding to the file AN corresponding to the file A4, and the like, wherein the operation sequence 1-the operation sequence N are operation sequence numbers.
The second way is: and acquiring the operation sequence numbers included in the stored files, searching the target sequence numbers from the acquired operation sequence numbers, and determining the stored files including the target sequence numbers as stored files corresponding to the target sequence numbers.
The electronic device may record the operation sequence in each stored file, so that the electronic device may obtain the operation sequence number included in each stored file, and in one embodiment, the electronic device may parse each stored file, thereby obtaining the operation sequence number included in each stored file.
After the operation serial numbers included in each stored file are obtained, the electronic device can search the target serial numbers from the obtained operation serial numbers, and then determine the stored file including the target serial numbers as the stored file corresponding to the target serial numbers.
For example, if the target sequence number is 7, the electronic device may obtain the operation sequence number included in each stored file, which is assumed to be 7-39, and then the electronic device may determine the stored file A7 including the target sequence number 7 as the stored file corresponding to the target sequence number 7.
In one embodiment, as shown in FIG. 6, stored file 610 may include file data and an operation number N. For example, the stored file 610 is a video file, which may include video data and an operation serial number, and the format of the video file may be MP4, MOV, AVI, FLV, etc., which is not limited herein.
Third mode: acquiring file names of the stored files, and analyzing the file names to obtain operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
The electronic device may add the operation sequence of each stored file to the file name of each stored file, so that the electronic device may obtain the file name of each stored file, parse the file name to obtain the operation sequence number included therein, and further search the obtained operation sequence number for the target sequence number, and determine the stored file whose file name includes the target sequence number as the stored file corresponding to the target sequence number.
In one embodiment, taking a file as a video file as an example, as shown in fig. 7, when the electronic device stores each video file, the electronic device may add the operation sequence of each video file 710 to the file name of each video file, and the obtained file name 720 may be the video name+the operation sequence n.mp4. Thus, the electronic device obtains the file name of the video file and analyzes the file name to obtain the operation serial number N included in the file name.
Therefore, in this embodiment, the electronic device may record the operation sequence of each file in any manner, and may accurately determine the stored file corresponding to the target sequence number, so as to ensure smooth circulation coverage and storage of the file, and avoid the problem of file loss.
Corresponding to the file storage method, the embodiment of the invention also provides a file generation method. The following describes a file generation method provided by the embodiment of the invention. The file generation method provided by the embodiment of the invention can be applied to any electronic equipment needing file generation, in particular to electronic equipment with limited storage space, for example, electronic equipment such as vehicle-mounted equipment and monitoring equipment.
As shown in fig. 8, a file generating method includes:
s801, acquiring a data stream for generating a file;
s802, generating a file based on the data stream under the condition that the data stream meets a preset generation condition;
s803, determining the operation sequence of the file, and recording the operation sequence.
The operation sequence is used for identifying the generation sequence of the generated files.
In the scheme provided by the embodiment of the invention, the electronic device can acquire the data stream for generating the file, generate the file based on the data stream under the condition that the data stream meets the preset generating condition, determine the operation sequence of the file, and record the operation sequence, wherein the operation sequence is used for identifying the generating sequence of the generated file. Therefore, when the cyclic coverage storage of the files is needed, the electronic equipment can determine the target files to be deleted based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependency on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
In the step S801, the electronic device may acquire the data stream in real time, where the data stream may be a video stream acquired by a camera, an audio stream acquired by a recording device, or the like, and is not limited herein.
Further, in the case where the data stream satisfies the preset generation condition, a file may be generated based on the data stream and stored, that is, the above-described step S802 may be performed. The preset generation condition may be a preset period of time or a preset data amount, for example, the preset period of time may be 10 minutes, 15 minutes, 20 minutes, or the like. The preset data amount may be 500MB, 1000MB, 1GB, etc.
In one case, when the acquired duration corresponding to the data stream reaches the preset time period, the electronic device can determine that the data stream meets the preset generation condition, and then generate and store the data stream into a file. In another case, when the acquired data amount of the data stream reaches the preset data amount, the electronic device may determine that the data stream meets the preset generation condition, and then generate and store the data stream into a file.
Next, the electronic apparatus may perform the above-described step S803, i.e., determine the operation order of the file, and record the operation order. Wherein, the operation sequence is used for identifying the generation sequence of the generated files, and in one embodiment, the operation sequence may be an operation sequence number. For example, the currently stored files have an operation order of 1 and 2, respectively, and at this time, the electronic device generates a new file and may record that the new file has an operation order of 3.
As an implementation manner of the embodiment of the present invention, the step of determining the operation sequence of the file may include:
determining an operation sequence of the file based on the acquisition time of the data stream; or determining the operation sequence of the file based on the generation time of the file.
The earlier the acquisition time of the data stream is, the earlier the time for generating the corresponding file is, so that the operation sequence of the stored files can be determined based on the acquisition time of the corresponding data stream and also can be determined based on the generation time of the files, which is reasonable, and the generation sequence of each stored file can be accurately identified.
It can be seen that, in this embodiment, the electronic device may determine the operation sequence of the file based on the acquisition time of the data stream, or determine the operation sequence of the file based on the generation time of the file, and whichever mode is adopted may obtain the operation sequence capable of accurately identifying the generation sequence of each stored file.
As an implementation of the embodiment of the present invention, in some cases, the data stream may be multiple paths. For example, the electronic device is connected to a plurality of image capturing devices, and the plurality of image capturing devices send video streams to the electronic device in real time, so that the electronic device receives multiple video streams.
In the case that the operation sequence is determined based on the acquisition time of the data stream, the step of determining the operation sequence of the file based on the acquisition time of the data stream may include:
and determining the operation sequence of the third target file based on the first preset sequence determination rule under the condition that the third target file with the same acquisition time of the data stream exists.
Because the electronic device receives multiple data streams, the multiple data streams may have the same acquisition time, and the file generated based on the data streams may have the same acquisition time.
The data streams corresponding to the third target files have the same acquisition time, which means that the files are equivalent to the cyclic coverage storage operation of the files, that is, when the cyclic coverage storage of the files is needed, it is reasonable to delete which third target file. Therefore, the first preset order may be a randomly determined operation order.
For example, the operation sequence of the currently stored files is 1-4, and then the electronic device generates two new files, where the acquisition time of the data streams corresponding to the two new files is the same, that is, the two new files are the third target files. The electronic device may randomly determine that the order of operation of the two third object files is 5 and 6, respectively.
In the case that the operation sequence is determined based on the generation time of the file, the step of determining the operation sequence of the file based on the generation time of the file may include:
and determining the operation sequence of the fourth target file based on a second preset sequence determination rule under the condition that the fourth target file with the same generation time exists.
Similarly, since the generation time corresponding to the fourth target file is the same, which indicates that the files are identical to the cyclic coverage storage operation of the file, the second preset sequence may also be a random determined operation sequence.
It can be seen that, in this embodiment, when the data stream is multiple paths, and in the case that there is a third target file with the same acquisition time of the data stream, the electronic device may determine the operation sequence of the third target file based on the first preset sequence determining rule; in the case where there is a fourth target file having the same generation time, the operation order of the fourth target file may be determined based on the second preset order determination rule. The operation sequence of the files can be determined under the condition that the files with the same acquisition time or the same generation time of the corresponding data streams appear, so that the circulation coverage storage of the subsequent files can be smoothly performed.
Corresponding to the file storage method, the embodiment of the invention also provides a file storage device. The following describes a file storage device provided in an embodiment of the present invention.
As shown in fig. 9, a file storage device, the device comprising:
a file obtaining module 910, configured to obtain a file to be stored;
a file determining module 920, configured to determine, if the target storage space meets a preset cycle coverage storage condition, a target file based on an operation sequence of each pre-recorded stored file;
the operation sequence is used for identifying the generation sequence of each stored file.
And the file storage module 930 is configured to delete the target file from the target storage space and store the file to be stored in the target storage space.
In the scheme provided by the embodiment of the invention, the electronic equipment can acquire the file to be stored; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
As shown in fig. 10, as an implementation manner of the embodiment of the present invention, the file determining module 920 may include:
a first operation sequence number determination unit 921 for determining, as a target sequence number, an earliest operation sequence number among operation sequence numbers of respective stored files based on an operation sequence of respective stored files recorded in advance;
the file determining unit 922 is configured to determine, as a target file, a stored file corresponding to the target sequence number according to a pre-recorded correspondence between the operation sequence number and the file.
As an implementation manner of the embodiment of the present invention, the operation sequence number determining unit may include:
and the operation sequence number determining subunit is used for determining the operation sequence number positioned at the queue head of the operation sequence queue as a target sequence number.
The operation sequence queue is used for recording the operation sequence numbers of all stored files.
The apparatus may further include:
and the operation sequence number adding subunit is used for determining the addition of the operation sequence number positioned at the tail of the operation sequence queue and 1 as the operation sequence number of the file to be stored after the file to be stored is stored in the target storage space, and adding the operation sequence number of the file to be stored to the tail of the operation sequence queue.
As an implementation manner of the embodiment of the present invention, the file determining module 920 may include:
a second operation sequence number determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files;
the first target file determining unit is used for determining a stored file corresponding to the target sequence number according to the corresponding relation between the pre-recorded operation sequence number and the file, and the stored file is used as a first target file;
a target time determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance;
a second target file determining unit, configured to determine, according to a pre-recorded correspondence between the generation time and the file, a stored file corresponding to the target time as a second target file;
a third target file determining unit, configured to determine, when the first target file and the second target file are the same file, the file as a determination target file;
and a fourth target file determining unit configured to determine a target file based on the priority of the operation order and the priority of the generation time of each stored file, in the case where the first target file and the second target file are different files.
As an implementation manner of the embodiment of the present invention, the fourth object file determining unit may include:
a target file determining subunit, configured to determine a target file from the first target file and the second target file based on a preset priority of an operation sequence of each stored file and a preset priority of a generation time; or alternatively, the first and second heat exchangers may be,
the alarm device is used for outputting alarm information; and acquiring the priority determined by the user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority.
The alarm information is used for indicating the priority of the operation sequence and the priority of the generation time of each stored file determined by a user.
As an implementation manner of the embodiment of the present invention, the file determining module 920 may include:
a fifth target file determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance, in a case where the system time is normal; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file;
A sixth target file determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on an operation sequence of the respective stored files recorded in advance in the case of abnormality of the system time; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
As an implementation manner of the embodiment of the present invention, the file determining unit may include:
a file determining subunit, configured to find a file name corresponding to the target sequence number from a pre-created operation sequence record file, and determine the file corresponding to the file name as a stored file corresponding to the target sequence number, where the operation sequence record file records a correspondence between an operation sequence number and a file; or alternatively, the first and second heat exchangers may be,
the method comprises the steps of obtaining operation sequence numbers included in all stored files, searching the target sequence numbers from the obtained operation sequence numbers, and determining the stored files including the target sequence numbers as stored files corresponding to the target sequence numbers; or alternatively, the first and second heat exchangers may be,
the method comprises the steps of obtaining file names of all stored files, and analyzing the file names to obtain operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
Corresponding to the file generation method, the embodiment of the invention also provides a file generation device. The following describes a document generating apparatus provided in an embodiment of the present invention.
As shown in fig. 11, a file generating apparatus includes:
a data acquisition module 1110 for acquiring a data stream for generating a file;
a file generating module 1120, configured to generate a file based on the data stream if the data stream meets a preset generating condition;
the sequence determining module 1130 is configured to determine an operation sequence of the file, and record the operation sequence, where the operation sequence is used to identify a generating sequence of the generated file.
In the scheme provided by the embodiment of the invention, the electronic device can acquire the data stream for generating the file, generate the file based on the data stream under the condition that the data stream meets the preset generating condition, determine the operation sequence of the file, and record the operation sequence, wherein the operation sequence is used for identifying the generating sequence of the generated file. Therefore, when the cyclic coverage storage of the files is needed, the electronic equipment can determine the target files to be deleted based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependency on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
As an implementation of the embodiment of the present invention, the sequence determining module 1130 may include:
a first order determining unit configured to determine an operation order of the file based on an acquisition time of the data stream; or alternatively, the first and second heat exchangers may be,
and a second order determining unit for determining an operation order of the files based on the generation time of the files.
As an implementation manner of the embodiment of the present invention, the data stream may be multiple paths;
the first order determining unit may include:
a first order determining subunit, configured to determine, in the case where there is a third target file with the same acquisition time of the data stream, an operation order of the third target file based on a first preset order determining rule;
the second order determining unit may include:
and the second order determining subunit is used for determining the operation order of the fourth target files based on a second preset order determining rule under the condition that the fourth target files with the same generation time exist.
The embodiment of the present invention further provides an electronic device, as shown in fig. 12, which is characterized by comprising a processor 1201 and a memory 1202, wherein:
a memory 1201 for storing a computer program;
The processor 1202 is configured to implement the file storing method or the file generating method according to any of the above embodiments when executing the program stored in the memory 1201.
In the scheme provided by the embodiment of the invention, the electronic equipment can acquire the file to be stored; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Or the data stream for generating the file can be obtained, the file is generated based on the data stream under the condition that the data stream meets the preset generation condition, the operation sequence of the file is determined, and the operation sequence is recorded, wherein the operation sequence is used for identifying the generation sequence of the generated file. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
As an implementation manner of the embodiment of the present invention, the electronic device may further include a communication interface and a communication bus, where the processor, the communication interface, and the memory complete communication with each other through the communication bus.
The communication bus mentioned above for the electronic devices may be a peripheral component interconnect standard (Peripheral Component Interconnect, PCI) bus or an extended industry standard architecture (Extended Industry Standard Architecture, EISA) bus, etc. The communication bus may be classified as an address bus, a data bus, a control bus, or the like. For ease of illustration, the figures are shown with only one bold line, but not with only one bus or one type of bus.
The communication interface is used for communication between the electronic device and other devices.
The Memory may include random access Memory (Random Access Memory, RAM) or may include Non-Volatile Memory (NVM), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the aforementioned processor.
The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; but also digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
In yet another embodiment of the present invention, a computer readable storage medium is provided, where a computer program is stored, where the computer program is executed by a processor to implement the file storing method or the file generating method step according to any one of the embodiments above.
In the solution provided by the embodiment of the present invention, the computer program may obtain the file to be stored when executed by the processor; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Or the data stream for generating the file can be obtained, the file is generated based on the data stream under the condition that the data stream meets the preset generation condition, the operation sequence of the file is determined, and the operation sequence is recorded, wherein the operation sequence is used for identifying the generation sequence of the generated file. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
In a further embodiment of the present invention, a computer program product comprising instructions which, when run on a computer, cause the computer to perform the file storage method or file generation method steps of any of the embodiments described above is also provided.
Therefore, in the scheme provided by the embodiment of the invention, the file to be stored can be obtained when the computer program product runs on the computer; determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file; and deleting the target file from the target storage space, and storing the file to be stored into the target storage space. Or the data stream for generating the file can be obtained, the file is generated based on the data stream under the condition that the data stream meets the preset generation condition, the operation sequence of the file is determined, and the operation sequence is recorded, wherein the operation sequence is used for identifying the generation sequence of the generated file. Therefore, the target files to be deleted are determined based on the operation sequence for identifying the generation sequence of each stored file, the accurate target files can be found, and the operation sequence is not influenced even if the system time is abnormal because the operation sequence has no dependence on the system time, so that the cyclic coverage storage of the files can be successfully completed, the problem of abnormal cyclic coverage storage is avoided, and the problem of file loss is avoided.
In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, produces a flow or function in accordance with embodiments of the present invention, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer instructions may be stored in or transmitted from one computer-readable storage medium to another, for example, by wired (e.g., coaxial cable, optical fiber, digital Subscriber Line (DSL)), or wireless (e.g., infrared, wireless, microwave, etc.). The computer readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. that contains an integration of one or more available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid State Disk (SSD)), etc.
It is noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
In this specification, each embodiment is described in a related manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. In particular, for apparatus, electronic devices, storage media, and computer program product embodiments, the description is relatively simple, as it is substantially similar to method embodiments, with reference to the description of method embodiments in part.
The foregoing description is only of the preferred embodiments of the present invention and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.

Claims (12)

1. A method of storing a file, the method comprising:
acquiring a file to be stored;
determining a target file based on a pre-recorded operation sequence of each stored file under the condition that the target storage space meets a preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file;
deleting the target file from the target storage space, and storing the file to be stored into the target storage space;
wherein the step of determining the target file based on the operation sequence of each pre-recorded stored file comprises the steps of:
determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number; determining a stored file corresponding to the target sequence number as a first target file according to the corresponding relation between the pre-recorded operation sequence number and the file; determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each stored file recorded in advance; determining a stored file corresponding to the target time as a second target file according to the corresponding relation between the pre-recorded generation time and the file; determining the file as a determination target file under the condition that the first target file and the second target file are the same file; determining a target file based on the priority of the operation sequence and the priority of the generation time of each stored file under the condition that the first target file and the second target file are different files; or alternatively, the first and second heat exchangers may be,
Under the condition that the system time is normal, determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each pre-recorded stored file; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file; under the condition of abnormal system time, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
2. The method of claim 1, wherein the step of determining the target file based on the priority of the order of operation and the priority of the generation time of the respective stored files comprises:
determining target files from the first target file and the second target file based on the preset priority of the operation sequence and the preset priority of the generation time of each stored file; or alternatively, the first and second heat exchangers may be,
Outputting alarm information; and acquiring the priority determined by the user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority, wherein the alarm information is used for indicating the priority of determining the operation sequence of each stored file and the priority of generating time.
3. The method according to claim 1 or 2, wherein the step of determining the stored file corresponding to the target sequence number according to the correspondence between the pre-recorded operation sequence number and the file comprises:
searching a file name corresponding to the target sequence number from a pre-established operation sequence record file, and determining the file corresponding to the file name as a stored file corresponding to the target sequence number, wherein the operation sequence record file records the corresponding relation between the operation sequence number and the file; or alternatively, the first and second heat exchangers may be,
acquiring operation sequence numbers included in the stored files, searching the target sequence numbers from the acquired operation sequence numbers, and determining the stored files including the target sequence numbers as stored files corresponding to the target sequence numbers; or alternatively, the first and second heat exchangers may be,
Acquiring file names of the stored files, and analyzing the file names to obtain operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
4. The method according to claim 1 or 2, wherein the order of operations is determined based on acquisition times of data streams generating the respective stored files; or alternatively, the first and second heat exchangers may be,
the order of operations is determined based on the time of generation of the respective stored file.
5. A method of generating a file, the method comprising:
acquiring a data stream for generating a file;
generating a file based on the data stream under the condition that the data stream meets a preset generation condition;
determining the operation sequence of the file, and recording the operation sequence, wherein the operation sequence is used for identifying the generation sequence of the generated file and determining the target file to be deleted;
the method for determining the target file to be deleted according to the operation sequence comprises the following steps:
determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number; determining a stored file corresponding to the target sequence number as a first target file according to the corresponding relation between the pre-recorded operation sequence number and the file; determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each stored file recorded in advance; determining a stored file corresponding to the target time as a second target file according to the corresponding relation between the pre-recorded generation time and the file; determining the file as a determination target file under the condition that the first target file and the second target file are the same file; determining a target file based on the priority of the operation sequence and the priority of the generation time of each stored file under the condition that the first target file and the second target file are different files; or alternatively, the first and second heat exchangers may be,
Under the condition that the system time is normal, determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each pre-recorded stored file; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file; under the condition of abnormal system time, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
6. The method of claim 5, wherein the step of determining the order of operation of the file comprises:
determining an operation sequence of the file based on the acquisition time of the data stream; or alternatively, the first and second heat exchangers may be,
and determining the operation sequence of the file based on the generation time of the file.
7. The method of claim 6, wherein the data stream is multiplexed;
the step of determining the operation sequence of the file based on the acquisition time of the data stream includes:
Determining the operation sequence of a third target file based on a first preset sequence determining rule under the condition that the third target file with the same acquisition time of the data stream exists;
the step of determining the operation sequence of the file based on the generation time of the file comprises the following steps:
and determining the operation sequence of the fourth target file based on a second preset sequence determination rule under the condition that the fourth target file with the same generation time exists.
8. A file storage device, the device comprising:
the file acquisition module is used for acquiring a file to be stored;
the file determining module is used for determining the target file based on the operation sequence of each pre-recorded stored file under the condition that the target storage space meets the preset cycle coverage storage condition, wherein the operation sequence is used for identifying the generation sequence of each stored file;
the file storage module is used for deleting the target file from the target storage space and storing the file to be stored into the target storage space;
wherein, the file determination module includes:
a second operation sequence number determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on the operation sequence of the respective pre-recorded stored files;
The first target file determining unit is used for determining a stored file corresponding to the target sequence number according to the corresponding relation between the pre-recorded operation sequence number and the file, and the stored file is used as a first target file;
a target time determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance;
a second target file determining unit, configured to determine, according to a pre-recorded correspondence between the generation time and the file, a stored file corresponding to the target time as a second target file;
a third target file determining unit, configured to determine, when the first target file and the second target file are the same file, the file as a determination target file;
a fourth target file determining unit configured to determine a target file based on a priority of an operation order of the respective stored files and a priority of a generation time in a case where the first target file and the second target file are different files; or alternatively, the first and second heat exchangers may be,
the file determining module includes:
a fifth target file determining unit configured to determine, as a target time, an earliest generation time among generation times of the respective stored files based on the generation times of the respective stored files recorded in advance, in a case where the system time is normal; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file;
A sixth target file determining unit configured to determine, as a target sequence number, an earliest operation sequence number among operation sequence numbers of the respective stored files based on an operation sequence of the respective stored files recorded in advance in the case of abnormality of the system time; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
9. The apparatus of claim 8, wherein the device comprises a plurality of sensors,
the fourth object file determining unit includes:
a target file determining subunit, configured to determine a target file from the first target file and the second target file based on a preset priority of an operation sequence of each stored file and a preset priority of a generation time; or, is used for outputting the alarm information; acquiring a priority determined by a user based on the alarm information, and determining a target file from the first target file and the second target file based on the priority, wherein the alarm information is used for indicating the priority of determining the operation sequence of each stored file and the priority of generating time;
the file determination unit includes:
A file determining subunit, configured to find a file name corresponding to the target sequence number from a pre-created operation sequence record file, and determine the file corresponding to the file name as a stored file corresponding to the target sequence number, where the operation sequence record file records a correspondence between an operation sequence number and a file; or, the method is used for acquiring the operation sequence numbers included in the stored files, searching the target sequence numbers from the acquired operation sequence numbers, and determining the stored files including the target sequence numbers as the stored files corresponding to the target sequence numbers; or, the method is used for obtaining the file names of the stored files and analyzing the file names to obtain the operation serial numbers included in the file names; and searching the target sequence number from the obtained operation sequence numbers, and determining the stored file with the file name comprising the target sequence number as the stored file corresponding to the target sequence number.
10. A document generating apparatus, the apparatus comprising:
the data acquisition module is used for acquiring a data stream for generating a file;
the file generation module is used for generating a file based on the data stream under the condition that the data stream meets the preset generation condition;
The sequence determining module is used for determining the operation sequence of the files and recording the operation sequence, wherein the operation sequence is used for identifying the generation sequence of the generated files and determining the target files to be deleted;
the method for determining the target file to be deleted according to the operation sequence comprises the following steps:
determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files, and taking the earliest operation sequence number as a target sequence number; determining a stored file corresponding to the target sequence number as a first target file according to the corresponding relation between the pre-recorded operation sequence number and the file; determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each stored file recorded in advance; determining a stored file corresponding to the target time as a second target file according to the corresponding relation between the pre-recorded generation time and the file; determining the file as a determination target file under the condition that the first target file and the second target file are the same file; determining a target file based on the priority of the operation sequence and the priority of the generation time of each stored file under the condition that the first target file and the second target file are different files; or alternatively, the first and second heat exchangers may be,
Under the condition that the system time is normal, determining the earliest generation time in the generation time of each stored file as a target time based on the generation time of each pre-recorded stored file; determining a stored file corresponding to the target time as a target file according to the corresponding relation between the pre-recorded generation time and the file; under the condition of abnormal system time, determining the earliest operation sequence number in the operation sequence numbers of all the stored files based on the operation sequence of all the pre-recorded stored files as a target sequence number; and determining a stored file corresponding to the target sequence number as a target file according to the corresponding relation between the pre-recorded operation sequence number and the file.
11. The apparatus of claim 10, wherein the order determination module comprises:
a first order determining unit configured to determine an operation order of the file based on an acquisition time of the data stream; or alternatively, the first and second heat exchangers may be,
a second order determining unit configured to determine an operation order of the files based on a generation time of the files;
the data flow is multipath;
the first order determining unit includes:
A first order determining subunit, configured to determine, in the case where there is a third target file with the same acquisition time of the data stream, an operation order of the third target file based on a first preset order determining rule;
the second order determining unit includes:
and the second order determining subunit is used for determining the operation order of the fourth target files based on a second preset order determining rule under the condition that the fourth target files with the same generation time exist.
12. An electronic device comprising a processor and a memory, wherein:
a memory for storing a computer program;
a processor for carrying out the method steps of any one of claims 1-4 or 5-7 when executing a program stored on a memory.
CN202011459859.0A 2020-12-11 2020-12-11 File storage and generation method and device and electronic equipment Active CN112463746B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011459859.0A CN112463746B (en) 2020-12-11 2020-12-11 File storage and generation method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011459859.0A CN112463746B (en) 2020-12-11 2020-12-11 File storage and generation method and device and electronic equipment

Publications (2)

Publication Number Publication Date
CN112463746A CN112463746A (en) 2021-03-09
CN112463746B true CN112463746B (en) 2023-11-03

Family

ID=74804689

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011459859.0A Active CN112463746B (en) 2020-12-11 2020-12-11 File storage and generation method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN112463746B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113903105B (en) * 2021-09-30 2023-11-03 杭州海康汽车软件有限公司 Video cyclic storage method and device, electronic equipment and storage medium

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1924852A (en) * 2006-08-25 2007-03-07 四川长虹电器股份有限公司 Embedded hardware video system
CN102819468A (en) * 2011-11-30 2012-12-12 凯迈(洛阳)环测有限公司 Backup and query method of FLASH-based small data
CN102841886A (en) * 2011-06-21 2012-12-26 北大方正集团有限公司 Method and device for splitting document
CN103533002A (en) * 2012-07-05 2014-01-22 阿里巴巴集团控股有限公司 Data processing method and system
CN104166650A (en) * 2013-05-16 2014-11-26 方正宽带网络服务股份有限公司 Data storage device and method
CN106649722A (en) * 2016-12-23 2017-05-10 郑州天迈科技股份有限公司 Storing and inquiring method for high-frequency data of monitoring system
CN106909550A (en) * 2015-12-22 2017-06-30 中国移动通信集团吉林有限公司 A kind of data handling system and method
CN107193886A (en) * 2017-04-27 2017-09-22 北京小米移动软件有限公司 File memory method and device
CN108345427A (en) * 2017-01-25 2018-07-31 杭州海康威视数字技术股份有限公司 A kind of hard disc data storage method and device
CN109408482A (en) * 2018-12-17 2019-03-01 浪潮电子信息产业股份有限公司 Data storage method, system, equipment and computer readable storage medium
CN110325929A (en) * 2016-12-07 2019-10-11 阿瑞路资讯安全科技股份有限公司 System and method for detecting the waveform analysis of cable network variation
CN110740190A (en) * 2019-10-28 2020-01-31 宁波三星智能电气有限公司 Event reporting method, power terminal and computer readable storage medium
CN111752912A (en) * 2019-03-26 2020-10-09 上海寒武纪信息科技有限公司 Data processing method and device

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1924852A (en) * 2006-08-25 2007-03-07 四川长虹电器股份有限公司 Embedded hardware video system
CN102841886A (en) * 2011-06-21 2012-12-26 北大方正集团有限公司 Method and device for splitting document
CN102819468A (en) * 2011-11-30 2012-12-12 凯迈(洛阳)环测有限公司 Backup and query method of FLASH-based small data
CN103533002A (en) * 2012-07-05 2014-01-22 阿里巴巴集团控股有限公司 Data processing method and system
CN104166650A (en) * 2013-05-16 2014-11-26 方正宽带网络服务股份有限公司 Data storage device and method
CN106909550A (en) * 2015-12-22 2017-06-30 中国移动通信集团吉林有限公司 A kind of data handling system and method
CN110325929A (en) * 2016-12-07 2019-10-11 阿瑞路资讯安全科技股份有限公司 System and method for detecting the waveform analysis of cable network variation
CN106649722A (en) * 2016-12-23 2017-05-10 郑州天迈科技股份有限公司 Storing and inquiring method for high-frequency data of monitoring system
CN108345427A (en) * 2017-01-25 2018-07-31 杭州海康威视数字技术股份有限公司 A kind of hard disc data storage method and device
CN107193886A (en) * 2017-04-27 2017-09-22 北京小米移动软件有限公司 File memory method and device
CN109408482A (en) * 2018-12-17 2019-03-01 浪潮电子信息产业股份有限公司 Data storage method, system, equipment and computer readable storage medium
CN111752912A (en) * 2019-03-26 2020-10-09 上海寒武纪信息科技有限公司 Data processing method and device
CN110740190A (en) * 2019-10-28 2020-01-31 宁波三星智能电气有限公司 Event reporting method, power terminal and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
浅析雪亮工程视频云存储应用;牛阿那;《中国公共安全》;第330卷(第05期);128-132 *

Also Published As

Publication number Publication date
CN112463746A (en) 2021-03-09

Similar Documents

Publication Publication Date Title
CN108076377B (en) Video storage and playing method and device, electronic equipment and storage medium
CN110913135A (en) Video shooting method and device, electronic equipment and storage medium
CN108966316B (en) Method, apparatus and device for displaying multimedia resources and predicting connection waiting time
CN109743589B (en) Article generation method and device
CN109542743B (en) Log checking method and device, electronic equipment and computer readable storage medium
CN111757037B (en) Video file reading and writing method and device
CN111669625A (en) Processing method, device and equipment for shot file and storage medium
CN112463746B (en) File storage and generation method and device and electronic equipment
CN110928946A (en) Document editing method and device and terminal equipment
CN111694708A (en) Data query method and device, electronic equipment and storage medium
CN110413684B (en) Database synchronization method, device and system
CN116415032A (en) Video file reading and storing method and device
CN111399754B (en) Method and device for releasing storage space and distributed system
CN111147778B (en) Track recording method and device based on digital video recorder and storage medium
CN111367703B (en) Fault checking method and device
CN110262752B (en) Method, device and storage medium for storing streaming media data
CN110536077B (en) Video synthesis and playing method, device and equipment
CN110971978A (en) Video playback method and device
CN110113389A (en) A kind of video broadcasting method, device, electronic equipment and storage medium
CN116303278A (en) File merging method, file reading method, device, equipment and storage medium
CN110868643B (en) Method and device for determining video downloading progress
CN112256654B (en) Document sharing method and device
CN114253755B (en) Log processing method, device, equipment and storage medium
CN112579805A (en) Image searching method and device, electronic equipment and storage medium
CN109426589B (en) A file restoration method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant