CN117873404A - Hard disk diagram optimization method and system based on machine vision multiple cameras - Google Patents

Hard disk diagram optimization method and system based on machine vision multiple cameras Download PDF

Info

Publication number
CN117873404A
CN117873404A CN202410271241.3A CN202410271241A CN117873404A CN 117873404 A CN117873404 A CN 117873404A CN 202410271241 A CN202410271241 A CN 202410271241A CN 117873404 A CN117873404 A CN 117873404A
Authority
CN
China
Prior art keywords
queue
image
hard disk
storing
thread
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.)
Pending
Application number
CN202410271241.3A
Other languages
Chinese (zh)
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.)
Guangzhou Yihong Intelligent Equipment Co ltd
Original Assignee
Guangzhou Yihong Intelligent Equipment 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 Guangzhou Yihong Intelligent Equipment Co ltd filed Critical Guangzhou Yihong Intelligent Equipment Co ltd
Priority to CN202410271241.3A priority Critical patent/CN117873404A/en
Publication of CN117873404A publication Critical patent/CN117873404A/en
Pending legal-status Critical Current

Links

Landscapes

  • Closed-Circuit Television Systems (AREA)

Abstract

The invention discloses a hard disk diagram optimizing method and a system based on a machine vision multi-camera, which relate to the technical field of machine vision and comprise the steps of collecting camera original image data and hard disk diagram storing data, and constructing N groups of queues and threads; constructing a multi-camera algorithm processing thread, storing an original image and a detection result screenshot into a graph-taking queue, constructing a system storage monitoring and evaluating algorithm, and performing fault evaluation on a storage queue process; and the thread corresponding to the hard disk acquires the image from the image taking queue and writes the image into the image storing queue, and the image in the image storing queue is written into the hard disk. According to the method, by constructing N groups of queues and threads, a high-efficiency data processing flow is realized, the load of a single processing unit is reduced, and processing and storage tasks are dispersed, so that the response speed and the data processing capacity of the whole system are improved; by separating the read and write operations of the image, the system can more flexibly adjust the processing and storage policies to cope with different workload and performance requirements.

Description

Hard disk diagram optimization method and system based on machine vision multiple cameras
Technical Field
The invention relates to the technical field of machine vision, in particular to a hard disk diagram optimizing method and system based on multiple cameras of machine vision.
Background
In modern machine vision project development, especially in those application scenarios where a large number of high-resolution images need to be processed, the prior art faces many challenges, especially when multiple types of cameras (such as 2D, line scan, 3D, etc.) are used, the data processing and storage requirements are extremely huge, for example, in some high-end industrial detection or AI labeling applications, a single industrial personal computer needs to process and store image data reaching TB level every day, such large-scale data processing not only puts extremely high demands on computing resources, but also faces significant challenges on data storage and management, and a key limitation in the prior art is that in a multi-camera system, a separate thread needs to be started for each camera to process and store image data, and this way may still be compatible when only a small number of cameras are used up, but as the number of cameras increases, the I/O resources of the system hard disk become a problem when multiple threads attempt to write into the same hard disk at the same time, so that the writing speed of the hard disk decreases significantly, the response time increases significantly, and in addition, the system cannot occupy the memory and even consume up due to the continuous memory, and the memory of the system may crash.
The method effectively reduces the resource contention of the I/O of the hard disk, improves the writing speed, reduces the response time of the hard disk, provides the functions of fault prediction and performance monitoring for the system by the system deposit monitoring and evaluating algorithm, and can evaluate possible faults in the process of depositing the queue by analyzing the comprehensive data such as the length of the queue, the image processing time, the queue waiting time, the system resource using condition, and the like.
Disclosure of Invention
The present invention has been made in view of the above-described problems.
Therefore, the technical problems solved by the invention are as follows: the existing hard disk image processing and storing method has low writing speed, low efficiency and low reliability, and can avoid the contention of system hard disk I/O resources in the image processing process, reduce fragmented storage and avoid the problem of continuous increment of memory caused by slow writing speed of the hard disk.
In order to solve the technical problems, the invention provides the following technical scheme: a hard disk memory map optimizing method based on machine vision multi-camera comprises the steps of collecting camera original image data and hard disk memory map data, and constructing N groups of queues and threads; constructing a multi-camera algorithm processing thread, storing an original image and a detection result screenshot into a graph-taking queue, constructing a system storage monitoring and evaluating algorithm, and performing fault evaluation on a storage queue process; and the thread corresponding to the hard disk acquires the image from the image taking queue and writes the image into the image storing queue, and the image in the image storing queue is written into the hard disk.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the hard disk image storage data comprise queue length data, image processing time data, queue waiting time data, image size and quality data, system resource service condition data, queue processing rate data, image transmission speed data and fault and abnormality record data; the system resource use condition data comprises CPU use rate, memory occupation and hard disk I/O load.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the construction of N groups of queues and threads comprises constructing N groups of queues and threads in the threads corresponding to each hard disk; constructing an original image drawing thread safety queue A11, storing the original image taken out of the original image queue B11, and adding the original image into the queue A11 when the original image processing is completed; constructing a truncated image taking thread safety queue A21, and storing the truncated image taken out of the truncated image queue B21; constructing an original storage thread safety queue A31, and temporarily storing an original image taken out of the queue A11; constructing a screenshot thread safety queue A41, and temporarily storing the intercepted image taken out of the queue A21; the same hard disk for original image drawing and intercepted image drawing uses the same thread, and the same hard disk for original image storage and screenshot uses the same thread.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the process thread for constructing the multi-camera algorithm comprises an original image queue B11 and a intercepted image queue B21 for constructing thread safety, and the multi-camera algorithm is constructedExpressed as:
wherein,for the number of groups of hard disk map data, +.>For the processing time of the i-th group of threads, +.>For the length of the i-th group queue, +.>For processing the priority of a thread +.>For the processing rate of the i-th set of original images and the detection result screenshots, t is the time variable, and the expected minimum performance level under hardware and software configuration is +.>The method comprises the steps of carrying out a first treatment on the surface of the When (when)When the thread or queue memory map performance reaches the standard; when (when)When the thread or queue graph storing performance does not reach the standard, the number of threads, the length of the queue and the processing rate are adjusted, so that the thread or queue graph storing performance reaches the standard.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the construction system deposit monitoring and evaluating algorithm comprises the steps of storing an original image of an original image queue B11 into an original image drawing process safety queue A11 after the thread or queue drawing performance meets the standard, storing a detection result screenshot in a intercepted image queue B21 into an intercepted image drawing process safety queue A21, and the construction system deposit monitoring and evaluating algorithm is expressed as follows:
wherein,representing the use of system resources, < >>For the estimated time window length, t is the time variable,for the state function of queue B11, +.>For the state function of queue B21, +.>For the state function of queue A11, +.>For the state function of queue A21, +.>For the system resource usage function, +.>For adjusting the coefficients, the system stores the state functions in the monitoring and evaluating algorithm as follows:
wherein n is the total number of elements of the queue B11, k is the iteration number of the elements of the queue B11, m is the total number of elements of the queue B21, j is the iteration number of the elements of the queue B21, and the use condition function of system resourcesExpressed as:
wherein,for system resource adjustment factor, +.>For CPU utilization, ++>For memory occupation, is->Is a hard disk I/O load.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the fault evaluation of the process of storing the queue comprises the steps of performing fault evaluation on the flow of storing the original image of the queue B11 into the queue A11 and the flow of storing the detection result screenshot in the queue B21 into the queue A21 through a system storing monitoring evaluation algorithm function value; when the function value of the system deposit monitoring and evaluating algorithm is more than 0 and less than or equal to 0.2, no fault occurs in the process of image deposit queuing; when the function value of the system deposit monitoring and evaluating algorithm is more than 0.2 and less than or equal to 0.6, potential faults occur in the process of storing images into the queue, and the overflow of the queue, the processing delay, the data loss and the insufficient system resources are checked; when the function value of the system deposit monitoring and evaluating algorithm is more than 0.6 and less than or equal to 1, the image deposit queue process breaks down, after the fault type is determined, the fault is removed, the damage condition of hardware, software and communication is checked, and the system is recovered.
As a preferable scheme of the hard disk memory map optimizing method based on the machine vision multi-camera, the invention comprises the following steps: the writing of the pictures in the picture storing queue into the hard disk comprises the steps that a thread corresponding to the hard disk acquires pictures from a picture taking queue and writes the pictures into the picture storing queue, the picture taking queue comprises a queue A11 and a queue A21, and the picture storing queue comprises a queue A31 and a queue A41; 1 unit image is fetched from A11 to be written to the hard disk at a time through the original image storage thread safety queue A31, and 1 unit image is fetched from A21 to be written to the hard disk at a time through the screenshot thread safety queue A41.
The invention also aims to provide a hard disk memory map optimizing system based on machine vision multiple cameras, which can store original images and detection result screenshots into a map-taking queue by constructing a multi-camera algorithm processing thread, and the system is constructed to store a monitoring evaluation algorithm to perform fault evaluation on the process of storing the queue, so that the problem of low reliability in processing and storing the existing hard disk images is solved.
As a preferable scheme of the hard disk memory map optimizing system based on the machine vision multi-camera, the invention comprises the following steps: the system comprises a queue thread construction module, a graph storage fault detection module and an image writing module; the queue thread construction module is used for collecting hard disk diagram data and constructing N groups of queues and threads; the system comprises a storage image fault detection module, a storage image detection module and a storage image detection module, wherein the storage image fault detection module is used for constructing a processing thread of a multi-camera algorithm, storing an original image and a detection result screenshot into a drawing queue, constructing a system storage monitoring evaluation algorithm, and performing fault evaluation on a storage queue process; the image writing module is used for the threads corresponding to the hard disk to acquire images from the image taking queue and write the images into the image storing queue, the images in the image storing queue are written into the hard disk, the system automatically and regularly checks the residual storage space and the I/O performance of each hard disk, and when the residual storage space of the hard disk is smaller than or equal to a threshold value, the writing task is automatically distributed to the spare hard disk, and meanwhile, a system administrator is reminded of taking corresponding measures; when the residual storage space of the hard disk is larger than a threshold value, the allocation of the storage tasks is dynamically adjusted based on the real-time performance and the storage requirement of the hard disk, and the data integrity is checked regularly.
A computer device comprising a memory storing a computer program and a processor executing the computer program is the step of implementing a machine vision multi-camera based hard disk memory map optimization method.
A computer readable storage medium having stored thereon a computer program which when executed by a processor implements the steps of a machine vision multi-camera based hard disk memory map optimization method.
The invention has the beneficial effects that: according to the hard disk memory map optimizing method based on the machine vision multi-camera, N groups of queues and threads are constructed by collecting hard disk map data, so that an efficient data processing flow is realized, the load of a single processing unit is reduced, and processing and storage tasks are dispersed, so that the response speed and the data processing capacity of the whole system are improved; by constructing a multi-camera algorithm processing thread and a system logging monitoring and evaluating algorithm, fault evaluation is carried out on a logging queue process, the system logging monitoring and evaluating algorithm can monitor the data logging process in real time and forecast and evaluate possible faults, so that the reliability of the system is improved, maintenance personnel can timely respond to potential system problems, the system downtime is reduced, and the data flow and the processing flow are optimized; the image is transferred from the image taking queue to the image storing queue through a special thread, and then the image is written into the hard disk from the image storing queue, so that direct read-write operation on a single hard disk is reduced, resource contention and hard disk I/O load are reduced, the image writing process is more orderly and efficient, the problem of memory occupation increment caused by low hard disk read-write speed is reduced, the system can more flexibly adjust processing and storage strategies through separating image reading and writing operations so as to cope with different work loads and performance requirements, other hard disk resources can be effectively utilized by the system when main hard disk resources are tense through load balancing and data backup, and the risk of data loss is reduced.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is an overall flowchart of a hard disk memory map optimizing method based on machine vision multiple cameras according to a first embodiment of the present invention.
Fig. 2 is an overall flowchart of a hard disk memory map optimizing system based on machine vision multiple cameras according to a third embodiment of the present invention.
Detailed Description
So that the manner in which the above recited objects, features and advantages of the present invention can be understood in detail, a more particular description of the invention, briefly summarized above, may be had by reference to the embodiments, some of which are illustrated in the appended drawings. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
Example 1
Referring to fig. 1, for one embodiment of the present invention, there is provided a hard disk memory map optimizing method based on machine vision multi-camera, including:
s1: and collecting camera original image data and hard disk memory image data, and constructing N groups of queues and threads.
Further, the hard disk memory data includes queue length data, image processing time data, queue waiting time data, image size and quality data, system resource use condition data, queue processing rate data, image transmission speed data, fault and anomaly record data; the system resource use condition data comprises CPU use rate, memory occupation and hard disk I/O load.
It should be noted that, constructing N groups of queues and threads includes constructing N groups of queues and threads in the threads corresponding to each hard disk; constructing an original image drawing thread safety queue A11, storing the original image taken out of the original image queue B11, and adding the original image into the queue A11 when the original image processing is completed; constructing a truncated image taking thread safety queue A21, and storing the truncated image taken out of the truncated image queue B21; constructing an original storage thread safety queue A31, and temporarily storing an original image taken out of the queue A11; constructing a screenshot thread safety queue A41, and temporarily storing the intercepted image taken out of the queue A21; the same hard disk for original image drawing and intercepted image drawing uses the same thread, and the same hard disk for original image storage and screenshot uses the same thread.
It should also be noted that, in the method, multiple groups of queues and threads are constructed in the threads corresponding to each hard disk to improve the parallelism and efficiency of data processing, by dispersing the hard disk I/O requests, the bottlenecks of resource contention and data processing are reduced, the original image drawing thread safety queue A11 and the intercepting image drawing thread safety queue A21 are used for storing the original image and the intercepting image respectively, the separation ensures the efficient management of the data flow, reduces the processing delay, and the original image drawing thread safety queue A31 and the screenshot thread safety queue A41 temporarily store the image for writing into the hard disk, so that the image storage process is more efficient and the pressure of the hard disk I/O is reduced.
S2: and (3) constructing a multi-camera algorithm processing thread, storing the original image and the detection result screenshot into a graph-taking queue, constructing a system storage monitoring and evaluating algorithm, and performing fault evaluation on the process of storing into the queue.
Further, building a multi-camera algorithmic processing thread includes building a thread-safe primitiveImage queue B11 and truncated image queue B21, and multi-camera algorithm is constructedExpressed as:
wherein,for the number of groups of hard disk map data, +.>For the processing time of the i-th group of threads, +.>For the length of the i-th group queue, +.>For processing the priority of a thread +.>For the processing rate of the i-th set of original images and the detection result screenshots, t is the time variable, and the expected minimum performance level under hardware and software configuration is +.>The method comprises the steps of carrying out a first treatment on the surface of the When (when)When the thread or queue memory map performance reaches the standard; when (when)When the thread or queue graph storing performance does not reach the standard, the number of threads, the length of the queue and the processing rate are adjusted, so that the thread or queue graph storing performance reaches the standard.
It should be noted that, the system deposit monitoring and evaluating algorithm is constructed by storing the original image of the original image queue B11 into the original image capturing process safety queue a11, storing the screenshot of the detection result in the captured image queue B21 into the captured image capturing process safety queue a21 after the thread or queue deposit performance reaches the standard, and the system deposit monitoring and evaluating algorithm is constructed by:
wherein,representing the use of system resources, < >>For the estimated time window length, t is the time variable,for the state function of queue B11, +.>For the state function of queue B21, +.>For the state function of queue A11, +.>For the state function of queue A21, +.>For the system resource usage function, +.>For adjusting the coefficients, the system stores the state functions in the monitoring and evaluating algorithm as follows:
wherein n is the total number of elements of the queue B11, k is the iteration number of the elements of the queue B11, m is the total number of elements of the queue B21, j is the iteration number of the elements of the queue B21, and the use condition function of system resourcesExpressed as:
wherein,for system resource adjustment factor, +.>For CPU utilization, ++>For memory occupation, is->Is a hard disk I/O load.
It should also be noted that, performing fault evaluation on the process of storing in the queue includes performing fault evaluation on the process of storing the original image of the queue B11 in the queue a11 and the process of storing the screenshot of the detection result in the queue B21 in the queue a21 by using the function value of the system storing monitoring evaluation algorithm; when the function value of the system deposit monitoring and evaluating algorithm is more than 0 and less than or equal to 0.2, no fault occurs in the process of image deposit queuing; when the function value of the system deposit monitoring and evaluating algorithm is more than 0.2 and less than or equal to 0.6, potential faults occur in the process of storing images into the queue, and the overflow of the queue, the processing delay, the data loss and the insufficient system resources are checked; when the function value of the system deposit monitoring and evaluating algorithm is more than 0.6 and less than or equal to 1, the image deposit queue process breaks down, after the fault type is determined, the fault is removed, the damage condition of hardware, software and communication is checked, and the system is recovered.
It should also be noted that the dynamic optimization mechanism introduced in the invention can adjust the configuration of the graph storing threads and queues according to the real-time performance data, the adaptive performance adjustment is based on accurate performance parameters such as processing time, queue length and processing speed, the mechanism ensures that under the condition of high load or system resource limitation, image processing and storage tasks are not delayed or interrupted, thereby obviously improving data throughput and system response capability, integrating key system resource use parameters (such as CPU utilization rate, memory occupation and hard disk I/O load) and queue states, the algorithm can evaluate the potential risk in the graph storing process in real time, not only improving the operation and maintenance efficiency of the system, but also greatly reducing operation interruption and maintenance cost caused by failure.
S3: and the thread corresponding to the hard disk acquires the image from the image taking queue and writes the image into the image storing queue, and the image in the image storing queue is written into the hard disk.
Further, writing the images in the image storage queue into the hard disk comprises the threads corresponding to the hard disk, acquiring the images from the image taking queue and writing the images into the image storage queue, writing the images in the image storage queue into the hard disk, wherein the image taking queue comprises a queue A11 and a queue A21, and the image storage queue comprises a queue A31 and a queue A41; through the original image storage thread safety queue A31, 1 unit image is taken from A11 and written to the hard disk each time, through the screenshot thread safety queue A41, 1 unit image is taken from A21 and written to the hard disk each time, the system automatically and regularly checks the residual storage space and I/O performance of each hard disk, and when the residual storage space of the hard disk is smaller than or equal to a threshold value, the writing task is automatically distributed to the spare hard disk, and meanwhile, a system administrator is reminded of taking corresponding measures; when the residual storage space of the hard disk is larger than a threshold value, the allocation of the storage tasks is dynamically adjusted based on the real-time performance and the storage requirement of the hard disk, and the data integrity is checked regularly.
It should be noted that, the arrangement of the graph taking queue and the graph storing queue allows the system to efficiently move the image data from the collection point to the storage medium, the queue management strategy not only improves the efficiency of data processing, but also reduces the risk of losing or delaying the data in the transmission process, the dedicated thread of each queue in the system ensures the continuity and stability of the data flow, by distributing the graph storing task to the specific thread, the invention reduces the load and response time of the hard disk I/O, thereby improving the efficiency of the whole storage process, which is particularly important for the application scenario requiring fast processing and storing of a large amount of image data, in the multi-camera system, numerous threads write into the same hard disk at the same time, possibly causes serious resource deprivation, effectively lightens the competition of the hard disk I/O resources by dispersing the storage request and optimizing the thread distribution, improves the overall performance and reliability of the system, while improving the data processing rate, the effective management of the graph storing queue and optimizing distribution reduce the risk of system faults, ensure the safety and integrity of the hard disk of the data under high load condition, and automatic efficiency of the data, and the system can not only control the system, but also reduce the performance of losing the data to the required by the system when the system is in the condition of losing the whole storage space, and the system is not triggered by the system, the performance of the system is reduced by the system, the system is not meeting the requirements of the performance of the system is reduced when the system is triggered by the system is not meeting the requirements of the conditions of the automatic performance of the system, and the system is triggered by the system is not meeting the system running the task, the system can dynamically adjust data distribution according to the performance and storage requirements of the current hard disk, and the intelligent distribution strategy can maximize the use efficiency of the hard disk and maintain the performance of the system.
Example 2
In order to verify the beneficial effects of the invention, scientific demonstration is carried out through economic benefit calculation and simulation experiments.
First, a control experiment was designed, which included two sets of systems: one group adopts the prior art, the other group adopts the method of the invention, two groups of systems process the image data of the same type and quantity, in order to ensure the fairness of comparison, the experiment focuses on key indexes such as queue length, image processing time, queue waiting time, image size, CPU utilization rate, memory occupation, hard disk I/O load, etc., these indexes are important parameters for evaluating the performance and stability of the system, for adopting the group of the prior art, the image data is processed according to the traditional thread and queue management mode; the invention adopts the group of the method, realizes the optimized queue and thread management strategy and the system storage monitoring evaluation algorithm, and the invention mainly comprises the steps of firstly, collecting hard disk diagram data and constructing N groups of queues and threads; step two, constructing a multi-camera algorithm processing thread, storing an original image and a detection result screenshot into a graph-taking queue, constructing a system storage monitoring evaluation algorithm, and performing fault evaluation on a process of storing into the queue; and step three, the thread corresponding to the hard disk acquires images from the image acquisition queue and writes the images into the image storage queue, and the images in the image storage queue are written into the hard disk.
Referring to table 1, experimental data were recorded and analyzed.
Table 1 table of experimental data records
In the extended data table, compared with the prior art, the embodiment of the invention shows remarkable improvement on various performance indexes, the reduction of the queue length in the embodiment of the invention shows higher efficient image management capability, reduces data congestion and processing delay, the reduction of image processing time and queue waiting time directly reflects faster image processing and transmission capability, which means that the system can process a large amount of image data more efficiently, the reduction of CPU utilization rate and memory occupation shows that the embodiment of the invention has lower system resource consumption and more stable operation in large-scale image processing, the reduction of the hard disk I/O load further proves the optimization of the embodiment of the invention in terms of data storage, reduces the pressure of the hard disk, reduces the system delay caused by the performance bottleneck of the hard disk, and obviously reflects the innovative improvement and the performance improvement brought by the aspects of multi-camera image processing and storage by comparing the data of the embodiment of the prior art and the invention.
Example 3
Referring to fig. 2, for one embodiment of the present invention, a hard disk memory map optimizing system based on machine vision multiple cameras is provided, which includes a queue thread construction module, a memory map fault detection module, and an image writing module.
The queue thread construction module is used for collecting hard disk diagram data and constructing N groups of queues and threads; the image storage fault detection module is used for constructing a multi-camera algorithm processing thread, storing an original image and a detection result screenshot into an image taking queue, constructing a system storage monitoring and evaluating algorithm, and performing fault evaluation on the process of storing into the queue; the image writing module is used for the thread corresponding to the hard disk to acquire the image from the image capturing queue and write the image into the image storing queue, and the image in the image storing queue is written into the hard disk.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method of the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, randomAccess Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable instructions for implementing logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium may even be paper or other suitable medium upon which the program is printed, as the program may be electronically captured, via, for instance, optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner, if necessary, and then stored in a computer memory.
It is to be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above-described embodiments, the various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like. It should be noted that the above embodiments are only for illustrating the technical solution of the present invention and not for limiting the same, and although the present invention has been described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that the technical solution of the present invention may be modified or substituted without departing from the spirit and scope of the technical solution of the present invention, which is intended to be covered in the scope of the claims of the present invention.
It should be noted that the above embodiments are only for illustrating the technical solution of the present invention and not for limiting the same, and although the present invention has been described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that the technical solution of the present invention may be modified or substituted without departing from the spirit and scope of the technical solution of the present invention, which is intended to be covered in the scope of the claims of the present invention.

Claims (10)

1. The hard disk memory map optimizing method based on the machine vision multi-camera is characterized by comprising the following steps of:
collecting camera original image data and hard disk memory data, and constructing N groups of queues and threads;
constructing a multi-camera algorithm processing thread, storing an original image and a detection result screenshot into a graph-taking queue, constructing a system storage monitoring and evaluating algorithm, and performing fault evaluation on a storage queue process;
and the thread corresponding to the hard disk acquires the image from the image taking queue and writes the image into the image storing queue, and the image in the image storing queue is written into the hard disk.
2. The machine vision multi-camera based hard disk memory map optimization method of claim 1, wherein: the hard disk image storage data comprise queue length data, image processing time data, queue waiting time data, image size and quality data, system resource service condition data, queue processing rate data, image transmission speed data and fault and abnormality record data;
the system resource use condition data comprises CPU use rate, memory occupation and hard disk I/O load.
3. The machine vision multi-camera based hard disk memory map optimization method of claim 2, wherein: the construction of N groups of queues and threads comprises constructing N groups of queues and threads in the threads corresponding to each hard disk;
constructing an original image drawing thread safety queue A11, storing the original image taken out of the original image queue B11, and adding the original image into the queue A11 when the original image processing is completed;
constructing a truncated image taking thread safety queue A21, and storing the truncated image taken out of the truncated image queue B21;
constructing an original storage thread safety queue A31, and temporarily storing an original image taken out of the queue A11;
constructing a screenshot thread safety queue A41, and temporarily storing the intercepted image taken out of the queue A21;
the same hard disk for original image drawing and intercepted image drawing uses the same thread, and the same hard disk for original image storage and screenshot uses the same thread.
4. The machine vision multi-camera based hard disk memory map optimization method of claim 3, wherein: the process thread for constructing the multi-camera algorithm comprises an original image queue B11 and a intercepted image queue B21 for constructing thread safety, and the multi-camera algorithm is constructedExpressed as:
wherein,for the number of groups of hard disk map data, +.>For the processing time of the i-th group of threads, +.>For the length of the i-th group queue, +.>For processing the priority of a thread +.>For the processing rate of the ith group of original images and detection result screenshot, t is time variable, and under the configuration of hardware and softwareIs +.>
When (when)When the thread or queue memory map performance reaches the standard;
when (when)When the thread or queue graph storing performance does not reach the standard, the number of threads, the length of the queue and the processing rate are adjusted, so that the thread or queue graph storing performance reaches the standard.
5. The machine vision multi-camera based hard disk memory map optimization method of claim 4, wherein: the construction system deposit monitoring and evaluating algorithm comprises the steps of storing an original image of an original image queue B11 into an original image drawing process safety queue A11 after the thread or queue drawing performance meets the standard, storing a detection result screenshot in a intercepted image queue B21 into an intercepted image drawing process safety queue A21, and the construction system deposit monitoring and evaluating algorithm is expressed as follows:
wherein,representing the use of system resources, < >>For the estimated time window length, t is the time variable, +.>For the state function of queue B11, +.>For the state function of queue B21, +.>As a function of the state of the queue a11,for the state function of queue A21, +.>For the system resource usage function, +.>For adjusting the coefficients, the system stores the state functions in the monitoring and evaluating algorithm as follows:
wherein n is the total number of elements of the queue B11, k is the iteration number of the elements of the queue B11, m is the total number of elements of the queue B21, j is the iteration number of the elements of the queue B21, and the use condition function of system resourcesExpressed as:
wherein,for system resource adjustment factor, +.>For CPU utilization, ++>For memory occupation, is->Is a hard disk I/O load.
6. The machine vision multi-camera based hard disk memory map optimization method of claim 5, wherein: the fault evaluation of the process of storing the queue comprises the steps of performing fault evaluation on the flow of storing the original image of the queue B11 into the queue A11 and the flow of storing the detection result screenshot in the queue B21 into the queue A21 through a system storing monitoring evaluation algorithm function value;
when the function value of the system deposit monitoring and evaluating algorithm is more than 0 and less than or equal to 0.2, no fault occurs in the process of image deposit queuing;
when the function value of the system deposit monitoring and evaluating algorithm is more than 0.2 and less than or equal to 0.6, potential faults occur in the process of storing images into the queue, and the overflow of the queue, the processing delay, the data loss and the insufficient system resources are checked;
when the function value of the system deposit monitoring and evaluating algorithm is more than 0.6 and less than or equal to 1, the image deposit queue process breaks down, after the fault type is determined, the fault is removed, the damage condition of hardware, software and communication is checked, and the system is recovered.
7. The machine vision multi-camera based hard disk memory map optimization method of claim 6, wherein: the writing of the pictures in the picture storing queue into the hard disk comprises the steps that a thread corresponding to the hard disk acquires pictures from a picture taking queue and writes the pictures into the picture storing queue, the picture taking queue comprises a queue A11 and a queue A21, and the picture storing queue comprises a queue A31 and a queue A41;
through the original image storage thread safety queue A31, 1 unit image is taken from A11 and written to the hard disk each time, through the screenshot thread safety queue A41, 1 unit image is taken from A21 and written to the hard disk each time, the system automatically and regularly checks the residual storage space and I/O performance of each hard disk, and when the residual storage space of the hard disk is smaller than or equal to a threshold value, the writing task is automatically distributed to the spare hard disk, and meanwhile, a system administrator is reminded of taking corresponding measures;
when the residual storage space of the hard disk is larger than a threshold value, the allocation of the storage tasks is dynamically adjusted based on the real-time performance and the storage requirement of the hard disk, and the data integrity is checked regularly.
8. A system employing the machine vision multi-camera based hard disk map optimization method of any one of claims 1-7, wherein: the system comprises a queue thread construction module, a graph storage fault detection module and an image writing module;
the queue thread construction module is used for collecting camera original image data and hard disk memory map data and constructing N groups of queues and threads;
the system comprises a storage image fault detection module, a storage image detection module and a storage image detection module, wherein the storage image fault detection module is used for constructing a processing thread of a multi-camera algorithm, storing an original image and a detection result screenshot into a drawing queue, constructing a system storage monitoring evaluation algorithm, and performing fault evaluation on a storage queue process;
the image writing module is used for the thread corresponding to the hard disk to acquire the image from the image taking queue and write the image into the image storing queue, and the image in the image storing queue is written into the hard disk.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the machine vision multi-camera based hard disk memory map optimization method of any one of claims 1 to 7 when the computer program is executed.
10. A computer readable storage medium having stored thereon a computer program, characterized in that the computer program when executed by a processor implements the steps of the machine vision multi-camera based hard disk memory map optimization method of any of claims 1 to 7.
CN202410271241.3A 2024-03-11 2024-03-11 Hard disk diagram optimization method and system based on machine vision multiple cameras Pending CN117873404A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410271241.3A CN117873404A (en) 2024-03-11 2024-03-11 Hard disk diagram optimization method and system based on machine vision multiple cameras

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410271241.3A CN117873404A (en) 2024-03-11 2024-03-11 Hard disk diagram optimization method and system based on machine vision multiple cameras

Publications (1)

Publication Number Publication Date
CN117873404A true CN117873404A (en) 2024-04-12

Family

ID=90579518

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410271241.3A Pending CN117873404A (en) 2024-03-11 2024-03-11 Hard disk diagram optimization method and system based on machine vision multiple cameras

Country Status (1)

Country Link
CN (1) CN117873404A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107479961A (en) * 2017-08-28 2017-12-15 湖南友哲科技有限公司 Based on the quick scanning processing method of computer multiple thread multinuclear microscopic cell image
CN111124641A (en) * 2019-12-12 2020-05-08 中盈优创资讯科技有限公司 Data processing method and system using multiple threads
CN112073327A (en) * 2020-08-19 2020-12-11 广东省新一代通信与网络创新研究院 Anti-congestion software distribution method, device and storage medium
CN114253477A (en) * 2021-12-15 2022-03-29 威创集团股份有限公司 Ultrahigh concurrent image data writing method and device and readable storage medium
CN114327280A (en) * 2021-12-29 2022-04-12 以萨技术股份有限公司 Message storage method and system based on cold-hot separation storage
CN114564457A (en) * 2022-02-24 2022-05-31 滨州东方地毯有限公司 Storage space optimization method and system for database file

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107479961A (en) * 2017-08-28 2017-12-15 湖南友哲科技有限公司 Based on the quick scanning processing method of computer multiple thread multinuclear microscopic cell image
CN111124641A (en) * 2019-12-12 2020-05-08 中盈优创资讯科技有限公司 Data processing method and system using multiple threads
CN112073327A (en) * 2020-08-19 2020-12-11 广东省新一代通信与网络创新研究院 Anti-congestion software distribution method, device and storage medium
CN114253477A (en) * 2021-12-15 2022-03-29 威创集团股份有限公司 Ultrahigh concurrent image data writing method and device and readable storage medium
CN114327280A (en) * 2021-12-29 2022-04-12 以萨技术股份有限公司 Message storage method and system based on cold-hot separation storage
CN114564457A (en) * 2022-02-24 2022-05-31 滨州东方地毯有限公司 Storage space optimization method and system for database file

Similar Documents

Publication Publication Date Title
JP4205103B2 (en) Information system, load control method, load control program, and recording medium
US9495201B2 (en) Management of bottlenecks in database systems
CN106293944B (en) non-consistency-based I/O access system and optimization method under virtualized multi-core environment
CN102622426A (en) Database writing system and database writing method
US11144330B2 (en) Algorithm program loading method and related apparatus
CN103684916A (en) Method and system for intelligent monitoring and analyzing under cloud computing
CN107273200B (en) Task scheduling method for heterogeneous storage
CN109308170B (en) Data processing method and device
US9396087B2 (en) Method and apparatus for collecting performance data, and system for managing performance data
US12001289B2 (en) Data recovery method, apparatus and device, and readable storage medium
CN107402863B (en) Method and equipment for processing logs of service system through log system
US9817754B2 (en) Flash memory management
US20140109100A1 (en) Scheduling method and system
CN109656895A (en) Distributed memory system, method for writing data, device and storage medium
DE112021004473T5 (en) STORAGE-LEVEL LOAD BALANCING
EP2328322A1 (en) Method and apparatus for accessing files stored in a storage access network (SAN) or network attached storange (NAS)
CN106469119A (en) A kind of data write buffer method based on NVDIMM and its device
CN109375868B (en) Data storage method, scheduling device, system, equipment and storage medium
CN110780821A (en) Optimization method and device of distributed storage system, server and storage medium
CN117873404A (en) Hard disk diagram optimization method and system based on machine vision multiple cameras
CN114020792A (en) Method, system, storage medium and server for supplementing historical data to real-time database
CN114924848A (en) IO (input/output) scheduling method, device and equipment
CN109947798A (en) A kind of processing method and processing device of stream event
WO2016044980A1 (en) Thread migration method, apparatus and system
CN103677757B (en) A kind of can the program parallelization degree control method of perception memory device bandwidth

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