WO2024051409A1 - 一种异步处理流程生成方法及装置 - Google Patents

一种异步处理流程生成方法及装置 Download PDF

Info

Publication number
WO2024051409A1
WO2024051409A1 PCT/CN2023/110914 CN2023110914W WO2024051409A1 WO 2024051409 A1 WO2024051409 A1 WO 2024051409A1 CN 2023110914 W CN2023110914 W CN 2023110914W WO 2024051409 A1 WO2024051409 A1 WO 2024051409A1
Authority
WO
WIPO (PCT)
Prior art keywords
target
processing component
data
asynchronous
processing
Prior art date
Application number
PCT/CN2023/110914
Other languages
English (en)
French (fr)
Inventor
胡博伟
胡景翔
宋震龙
Original Assignee
杭州海康机器人股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 杭州海康机器人股份有限公司 filed Critical 杭州海康机器人股份有限公司
Publication of WO2024051409A1 publication Critical patent/WO2024051409A1/zh

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/34Graphical or visual programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Definitions

  • the present application relates to the field of data processing technology, and in particular to an asynchronous processing flow generation method and device.
  • the processing component in the prior art is encapsulated with a data processing unit, a data input interface and a data output interface.
  • the electronic device can call the processing component and input the data into the processing component through the data input interface.
  • the data processing unit processes the data and extracts the data from the data.
  • the output interface outputs the processing results.
  • each processing component can be connected to the data input interface of other processing components, so that each processing component can jointly implement a data processing process.
  • the above-mentioned connection of each component Can be called component-specific configuration.
  • the processing results can be input into the input interface of the connected next processing component through the output interface.
  • the next processing component receives the processing results, it can continue to process the data through the output interface.
  • the self-encapsulated data processing unit continues to process the received processing results, and so on.
  • Each processing component jointly implements a data processing process.
  • the processing component located at the back end can start data processing, and data processing can be implemented between each processing component.
  • the process is a synchronous process. It is impossible to configure the processing component to implement asynchronous data processing using the configuration method of the existing technology.
  • the purpose of the embodiments of this application is to provide an asynchronous processing flow generation method and device to configure processing components to implement asynchronous data processing.
  • the specific technical solutions are as follows:
  • embodiments of the present application provide a method for generating an asynchronous processing flow.
  • the method includes:
  • each asynchronous processing component is connected, wherein the asynchronous processing component includes: a data input interface for receiving data, a data processing unit for processing data, and a data processing unit for outputting data.
  • the data output interface of each asynchronous processing component is connected to the data of the next asynchronous processing component in the processing sequence.
  • the input interface is connected;
  • the target event signal selected by the user for the target processing component in the asynchronous processing component, and display the identification of the target event signal in the first preset interface, wherein the target event signal is: the preceding asynchronous processing component passes the event The event signal output by the output interface, the pre-order asynchronous processing component is located before the target processing component in the processing sequence;
  • the operating conditions of the target processing component are generated, wherein the operating conditions are: the target event signal is output by the pre-order asynchronous processing component and the logical relationship is satisfied.
  • a data file is generated for data processing according to the asynchronous processing flow.
  • the target action is: an action that the data processing unit in the target processing component needs to perform when the operating conditions are met;
  • Configuring the target processing component to run the data processing unit when the operating conditions are established includes:
  • the target processing component is configured to run the data processing unit when the running condition is established, so that the executed data processing unit performs the target action.
  • the method further includes:
  • the target processing component is configured to output the output event signal through an event output interface during operation of the data processing unit.
  • determining the logical relationship between the target events configured by the user based on the content displayed on the first preset interface includes:
  • a target logical relationship symbol selected by the user from the displayed logical relationship symbols is determined, and a logical relationship between the target event signals is determined based on the target logical relationship symbol.
  • the logical relationship symbols include at least one of the following symbols: an AND symbol, an OR symbol, a negation symbol, parentheses, and a function used to implement a set function.
  • the asynchronous processing component is a component in a machine vision algorithm platform, and the data processing unit in the asynchronous processing component is used to process image data and/or video data.
  • inventions of the present application provide an asynchronous processing flow generation device.
  • the device includes:
  • the component connection module is used to connect each asynchronous processing component based on the processing sequence of the asynchronous processing component configured by the user, wherein the asynchronous processing component includes: a data input interface for receiving data, and a data processing module for processing data. unit, a data output interface for outputting data, an event receiving interface for receiving event signals, and an event output interface for outputting event signals. After connecting, the data output interface of each asynchronous processing component is connected to the next step in the processing sequence. Connected to the data input interface of an asynchronous processing component;
  • the identification selection module is used to determine the target event signal selected by the user for the target processing component in the asynchronous processing component, and display the identification of the target event signal in the first preset interface, wherein the target event signal is: The event signal output by the sequential asynchronous processing component through the event output interface, the pre-order asynchronous processing component is located before the target processing component in the processing sequence;
  • a logical relationship determination module configured to determine the logical relationship between the target event signals configured by the user according to the content displayed on the first preset interface
  • An operating condition generation module configured to generate operating conditions of the target processing component based on the logical relationship and the target event signal, wherein the operating conditions are: output the target event signal in the pre-order asynchronous processing component and If the logical relationship is satisfied, run the data processing unit in the target processing component;
  • a first component configuration module configured to configure the target processing component to receive the target event signal through the event receiving interface, and configure the target processing component to run the data processing unit when the operating conditions are established;
  • the data file generation module is used to generate data files for data processing according to the asynchronous processing flow based on the configuration results.
  • the device further includes:
  • An action determination module used to determine the target action selected by the user through the second preset interface, wherein the target action is: an action that the data processing unit in the target processing component needs to perform when the operating conditions are met. ;
  • the first component configuration module is specifically used for:
  • the target processing component is configured to receive the target event signal through the event receiving interface, and the target processing component is configured to run the data processing unit when the running condition is established, so that the executed data processing unit performs the target action.
  • the device further includes:
  • An output signal determination module used to determine the output event signal configured by the user through the third preset interface
  • the second component configuration module is used to configure the target processing component to output the output event signal through the event output interface during the operation of the data processing unit.
  • the logical relationship determination module is specifically used for:
  • a target logical relationship symbol selected by the user from the displayed logical relationship symbols is determined, and a logical relationship between the target event signals is determined based on the target logical relationship symbol.
  • the logical relationship symbols include at least one of the following symbols: an AND symbol, an OR symbol, a negation symbol, parentheses, and a function used to implement a set function.
  • the asynchronous processing component is a component in a machine vision algorithm platform, and the data processing unit in the asynchronous processing component is used to process image data and/or video data.
  • embodiments of the present application provide an electronic device, which is characterized by including:
  • Memory used to store computer programs
  • the processor is used to implement any of the methods described in the first aspect when executing the program stored in the memory.
  • embodiments of the present application provide a computer-readable storage medium.
  • a computer program is stored in the computer-readable storage medium.
  • any method described in the first aspect is implemented. step.
  • embodiments of the present application also provide a computer program product containing instructions that, when run on a computer, cause the computer to execute any of the methods described in the first aspect.
  • each asynchronous processing component is connected based on the processing sequence of the asynchronous processing component configured by the user, and the data output interface of each asynchronous processing component is connected to the next asynchronous processing in the processing sequence.
  • the data input interface of the component is connected; determining the target event signal selected by the user for the target processing component in the asynchronous processing component, and displaying the identification of the target event signal in the first preset interface; determining the content displayed by the user according to the first preset interface
  • the data processing unit is run under certain circumstances, and then based on the configuration results, a data file is generated for data processing according to the asynchronous processing flow.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiment of the present application, and configure the logical relationship between the target event signal and the target event signal for the target processing component in the asynchronous processing component, so as to
  • the operating conditions of the target processing component are configured so that the target processing component runs the data processing unit included in the target processing component when it obtains the target event signal and the target event signal satisfies the logical relationship. That is to say, after configuration, the target processing component does not start running the data processing unit after receiving the data output by the pre-order asynchronous processing component, but uses the event signal output by the pre-order asynchronous processing component as the running condition of the data processing unit.
  • the target processing component does not need to process the data after the pre-order asynchronous processing component completes the data processing and outputs the data. Instead, it can perform data processing after receiving the event signal at any stage during the data processing process of the pre-order asynchronous processing component. .
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal, and the target processing component receives the target event signal.
  • the target event signal meets the operating conditions, it can start executing its own data processing process.
  • the data processing of the two can be executed in parallel, which is an asynchronous relationship. Therefore, through the solution provided by the embodiment of this application, the asynchronous processing component can be configured to implement asynchronous data processing.
  • users can configure the asynchronous processing unit by performing simple operations in the visual first preset interface, and then generate various complex asynchronous processing processes based on the configuration of the asynchronous processing unit.
  • the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple and fast, reduces the user's learning cost, has a wider application range, and saves the maintenance overhead of codes or scripts. .
  • Figure 1 is a schematic flowchart of the first asynchronous processing flow generation method provided by the embodiment of the present application
  • Figure 2 is a schematic structural diagram of an asynchronous processing component provided by an embodiment of the present application.
  • Figure 3 is a schematic diagram of the connection relationship between asynchronous processing components provided by an embodiment of the present application.
  • Figure 4 is a schematic diagram of an information slot interface provided by an embodiment of the present application.
  • Figure 5 is a schematic diagram of the first first preset interface provided by the embodiment of the present application.
  • Figure 6a is a schematic diagram of the processing sequence of the first image processing flow provided by the embodiment of the present application.
  • Figure 6b is a schematic diagram of the processing sequence of the second image processing flow provided by the embodiment of the present application.
  • Figure 7 is a schematic structural diagram of a processing component in the prior art
  • Figure 8 is a schematic diagram of the connection relationship of processing components in the prior art
  • Figure 9 is a schematic flow chart of the second asynchronous processing flow generation method provided by the embodiment of the present application.
  • Figure 10 is a schematic diagram of a second preset interface provided by an embodiment of the present application.
  • Figure 11 is a schematic flow chart of the third asynchronous processing flow generation method provided by the embodiment of the present application.
  • Figure 12 is a schematic flow chart of the fourth asynchronous processing flow generation method provided by the embodiment of the present application.
  • Figure 13 is a schematic diagram of the second first preset interface provided by the embodiment of the present application.
  • Figure 14 is a schematic diagram of the third first preset interface provided by the embodiment of the present application.
  • Figure 15 is a schematic structural diagram of an asynchronous processing flow generation device provided by an embodiment of the present application.
  • Figure 16 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • embodiments of the present application provide a method and device for generating an asynchronous processing flow.
  • the embodiment of this application provides a method for generating an asynchronous processing flow.
  • the above method includes:
  • each asynchronous processing component is connected.
  • the above-mentioned asynchronous processing components include: a data input interface for receiving data, a data processing unit for processing data, and a data processing unit for outputting data.
  • the above-mentioned target event signal is: output by the pre-order asynchronous processing component through the event output interface
  • the event signal, the above-mentioned pre-order asynchronous processing component is located before the above-mentioned target processing component in the above-mentioned processing sequence;
  • the operating conditions of the target processing component are generated, wherein the above operating condition is: when the pre-order asynchronous processing component outputs the target event signal and the above logical relationship is satisfied, run the above target processing component data processing unit;
  • a data file is generated for data processing according to the asynchronous processing flow.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiment of the present application, and configure the logical relationship between the target event signal and the target event signal for the target processing component in the asynchronous processing component, so as to
  • the operating conditions of the target processing component are configured so that the target processing component runs the data processing unit included in the target processing component when it obtains the target event signal and the target event signal satisfies the logical relationship. That is to say, after configuration, the target processing component does not start running the data processing unit after receiving the data output by the pre-order asynchronous processing component, but uses the event signal output by the pre-order asynchronous processing component as the running condition of the data processing unit.
  • the target processing component does not need to process the data after the pre-order asynchronous processing component completes the data processing and outputs the data. Instead, it can perform data processing after receiving the event signal at any stage during the data processing process of the pre-order asynchronous processing component. .
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component can start executing its own data processing process when it receives the target event signal and the target event signal meets the operating conditions.
  • the data processing of the two can be executed in parallel.
  • the asynchronous processing component can be configured to implement asynchronous data processing.
  • users can configure the asynchronous processing unit by performing simple operations in the visual first preset interface, and then generate various complex asynchronous processing processes based on the configuration of the asynchronous processing unit.
  • the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple and fast, reduces the user's learning cost, has a wider application range, and saves the maintenance overhead of codes or scripts. .
  • FIG. 1 a schematic flowchart of a first asynchronous processing flow generation method provided by an embodiment of the present application is shown.
  • the above method includes the following steps S101-S106.
  • the above processing sequence can be understood as: the triggering sequence of each asynchronous processing component.
  • each asynchronous processing component can be triggered in a sequence, but after each asynchronous processing component is triggered, multiple data processing tasks can be executed in parallel at the same time.
  • the above-mentioned asynchronous processing component includes: a data input interface for receiving data, a data processing unit for processing data, a data output interface for outputting data, an event receiving interface for receiving event signals, and an output interface. Event output interface for event signals.
  • FIG. 2 is a schematic structural diagram of an asynchronous processing component provided by an embodiment of the present application.
  • the above-mentioned asynchronous processing component includes a data processing unit, a data input interface, a data output interface, an event receiving interface and an event output interface.
  • each asynchronous processing component can be connected to the data input interface of the next asynchronous processing component in the processing sequence.
  • the interface is connected, where the next asynchronous processing component in the processing sequence can be one asynchronous processing component, or multiple asynchronous processing components in parallel; accordingly, the data input interface of each asynchronous processing component can be connected to the data input interface of each asynchronous processing component in the processing sequence.
  • the previous data output interface is connected, and the previous asynchronous processing component in the processing sequence can be one asynchronous processing component or multiple asynchronous processing components in parallel.
  • a variety of asynchronous processing components can be provided in advance for the user to select.
  • the user selects the asynchronous processing component by inputting a component selection instruction.
  • the execution subject of this embodiment can be based on the component selection instruction. Determines the asynchronous processing component selected by the user.
  • the embodiments of the present application do not limit the functions of the asynchronous processing components provided in advance above.
  • the above-mentioned asynchronous processing component may be a component for image preprocessing, a component for image segmentation, a component for image feature extraction, etc.
  • the identification of the optional asynchronous processing component can be displayed on the fourth preset interface.
  • the identification of the asynchronous processing component can be the number, name, function description, etc. of the asynchronous processing component.
  • the user can view the third preset interface.
  • the content displayed on the four preset interfaces can be selected from the provided asynchronous processing components.
  • the user can input component connection instructions to control the execution body to connect to each asynchronous processing component.
  • the data output interface of one asynchronous processing component can be connected to the data input interfaces of multiple asynchronous processing components, and the data output interfaces of multiple asynchronous processing components can also be connected to the same asynchronous processing.
  • the data input interface of the component is not limited in the embodiments of this application.
  • FIG. 3 is a schematic diagram of the connection relationship between asynchronous processing components provided by an embodiment of the present application.
  • the data output interface of the asynchronous processing component connected to the starting end of the arrow in Figure 3 is connected to the data input interface of the asynchronous processing component connected to the termination end.
  • the data output interface of the asynchronous processing component 1 is connected to the data of the asynchronous processing component 3.
  • the input interfaces are connected, and the data output interface of the asynchronous processing component 2 is connected to the data input interfaces of the asynchronous processing component 3 and the asynchronous processing component 4 respectively.
  • the data output interface of the asynchronous processing component 2 is connected to the data input interfaces of the two asynchronous processing components, and the data input interface of the asynchronous processing component 3 is connected to the data output interfaces of the two asynchronous processing components.
  • S102 Determine the target event signal selected by the user for the target processing component in the asynchronous processing component, and display the identification of the target event signal in the first preset interface.
  • the above-mentioned target event signal is: an event signal output by a pre-order asynchronous processing component through an event output interface, and the above-mentioned pre-order asynchronous processing component is located before the above-mentioned target processing component in the above-mentioned processing sequence.
  • the asynchronous processing component can generate various event signals, such as execution start signal, execution end signal, execution exception signal, execution timestamp signal, etc.
  • the event signal output by the preceding asynchronous processing component can be used as the running condition of the asynchronous processing component that follows the processing sequence.
  • the user can select the required event signal as the target event signal from all event signals that can be output by the pre-order asynchronous processing component of the target processing component.
  • the identification of the target event signal may be the name, number, etc. of the target event signal.
  • Each asynchronous processing component in each asynchronous processing component can be used as a target processing component.
  • the user can select the target processing component according to the configuration requirements of the asynchronous processing process.
  • the selected processing component can be one or more, for each target processing
  • Each component can configure the target processing component through steps S102-S105.
  • an information slot can be added to the target processing component, and the target event signal corresponding to the target processing component is configured in the information slot.
  • the execution subject of the embodiment of the present application can display the information slot interface, and the user can select Target event signal.
  • FIG 4 is a schematic diagram of an information slot interface provided by an embodiment of the present application.
  • the information slot interface displays the running conditions configured for the target processing component.
  • the serial number of the running condition is displayed, such as serial number 1, and the name of the running condition is displayed, such as event 1.
  • the running conditions can be configured by clicking the configuration button. Configuration, specifically, you can configure the target event signal included in the running conditions and the logical relationship between the target event signals. By clicking the Add button, you can add new running conditions for the target processing component.
  • the identification of the selected target event signal may be displayed in the first preset interface.
  • FIG. 5 is a schematic diagram of a first preset interface provided by an embodiment of the present application.
  • the above-mentioned first preset interface displays the identification of the selected target event signal, including the identification of signal 1, the identification of signal 2, the identification of signal 3 and the identification of signal 4.
  • the subscribe button By clicking the subscribe button, the user can select other event signals of the pre-order asynchronous processing component as the target event signal.
  • S103 Determine the logical relationship between the target event signals configured by the user according to the content displayed on the first preset interface.
  • the logical relationship between target event signals may include AND, OR, NOT and other logical relationships.
  • the user can determine the selected target event signal based on the identification of the target event signal displayed on the first preset interface, and then configure the selected target event signal by selecting the identification of the target event signal on the first preset interface. Logic.
  • the above-mentioned first preset interface displays the logo of signal 1, the logo of signal 2, the logo of signal 3, and the logo of signal 4.
  • the user can based on the first preset
  • the content configuration displayed on the interface shows that the logical relationship between signal 1 and signal 2 is an AND relationship, the logical relationship between signal 2 and signal 3 is an AND relationship, and the logical relationship between signal 3 and signal 4 is an OR relationship.
  • the solution provided by the embodiment of the present application can also record the above-mentioned target event signal and the logical relationship between the target event signal.
  • the user can directly call the event signal combination when configuring other asynchronous processing components. , generate the running conditions of the asynchronous processing component, or add other event signals based on the event signal combination, and set the logical relationship between the event signal combination and the newly added event signal to form new running conditions.
  • the above-mentioned running condition is: when the pre-order asynchronous processing component outputs the target event signal and satisfies the above-mentioned logical relationship, run the data processing unit in the above-mentioned target processing component.
  • an executable file recording the identifier of the above target event signal and the above logical relationship can be generated to record the above operating conditions.
  • S105 Configure the above-mentioned target processing component to receive the target event signal through the event receiving interface, and configure the above-mentioned target processing component to run the data processing unit when the above-mentioned operating conditions are established.
  • the event receiving interface of the above-mentioned target processing component can be configured to continuously monitor the event output interface used to output the target event signal in the pre-order asynchronous processing component, thereby receiving the target event signal.
  • the target processing component can determine whether the received target event signal meets the operating conditions. Specifically, it can read the executable file recording the operating conditions generated in the aforementioned step S104 to determine whether the target event signal meets the operating conditions. Operating conditions. If the above operating conditions are met, the data processing unit is run to perform data processing, thereby realizing the configuration of the asynchronous processing process.
  • the above data file can be a script file or other executable file.
  • the above data file can record the code and configuration parameters for data processing according to the asynchronous processing flow.
  • the above data file is used to: for each asynchronous processing component, determine whether the operating condition of the asynchronous processing component is established, and control the asynchronous processing component to run the data processing unit when the operating condition is established.
  • the execution subject of the embodiment of the present application can run the above data file when it needs to execute the asynchronous processing process, thereby performing the action described in the above configuration result during the running process: judging the asynchronous processing component Whether the running condition is established, and if so, the asynchronous processing component is called to run the data processing unit, thereby controlling the operation of the asynchronous processing process.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiment of the present application, and configure the logical relationship between the target event signal and the target event signal for the target processing component in the asynchronous processing component, so as to
  • the operating conditions of the target processing component are configured so that the target processing component runs the data processing unit included in the target processing component when it obtains the target event signal and the target event signal satisfies the logical relationship. That is to say, after configuration, the target processing component does not start running the data processing unit after receiving the data output by the pre-order asynchronous processing component, but uses the event signal output by the pre-order asynchronous processing component as the running condition of the data processing unit.
  • the target processing component does not need to process the data after the pre-order asynchronous processing component completes the data processing and outputs the data. Instead, it can perform data processing after receiving the event signal at any stage during the data processing process of the pre-order asynchronous processing component. .
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component receives the target event signal and the target event signal meets the operating conditions, it can start executing its own data processing process.
  • the data processing processes of the two can be parallel. Execution is an asynchronous relationship, so through the solution provided by the embodiment of this application, the asynchronous processing component can be configured to implement asynchronous data processing.
  • users can configure the asynchronous processing unit by performing simple operations in the visual first preset interface, and then generate various complex asynchronous processing processes based on the configuration of the asynchronous processing unit.
  • the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple and fast, reduces the user's learning cost, has a wider application range, and saves the maintenance overhead of codes or scripts. .
  • the execution subject is a machine vision algorithm platform
  • the above-mentioned asynchronous processing component is a component in the above-mentioned machine vision algorithm platform
  • the data processing unit in the above-mentioned asynchronous processing component is used to process image data and/or video data. deal with.
  • an asynchronous processing flow for image data and/or video data can be generated.
  • the operation of an asynchronous processing component is not triggered by the processing result output by its pre-order asynchronous processing component, but by the event signal output by the pre-order asynchronous processing component, that is, the asynchronous processing component
  • the asynchronous processing component There is no coupling relationship between the operation and the processing results output by the preceding asynchronous processing components, so that each asynchronous processing component can run in parallel, improving the processing efficiency of image data and/or video data.
  • Figure 6a is a schematic diagram of the processing sequence of the first image processing flow provided by the embodiment of the present application.
  • image acquisition components 1-4 in the image processing process, which are used to obtain images captured by cameras 1-4 respectively.
  • the data input interface of the image acquisition components 1-4 is used to obtain images captured by the corresponding cameras.
  • the data output interface is used to output the acquired image, and the data output interfaces of the image acquisition components 1-4 are all connected to the data input interface of the image processing component.
  • the image acquisition component 1-4 After outputting the image, the image acquisition component 1-4 respectively outputs a completion signal indicating that the image output is completed through its own event output interface.
  • the image acquisition component 1-4 can continue to acquire new images after outputting the completion signal.
  • the event receiving interface of the image processing component is completed.
  • signal, the logical relationship between any two completion signals in each completion signal is an AND relationship, then the operating conditions of the image processing component are: run the data processing unit after fully receiving each completion signal, and perform the image acquisition component 1-4
  • the output image is processed.
  • FIG. 6b is a schematic diagram of the processing sequence of the second image processing flow provided by the embodiment of the present application.
  • the application scenario of the embodiment shown in Figure 6b can be a vehicle capture and recognition scenario.
  • radar in order to improve the vehicle recognition efficiency, when the surveillance camera starts to capture vehicle images, radar can be used in parallel to collect radar images, so that the images captured by the surveillance camera can be combined and radar images collected by radar for vehicle identification.
  • the image acquisition components 1-4 can output a start signal when starting to acquire images, and the radar acquisition component can receive each start signal.
  • the logical relationship between any two start signals in each start signal are all in an OR relationship, then the operating conditions of the radar acquisition component are: after receiving any start signal, run the data processing unit to collect radar images; on the other hand, the image acquisition components 1-4 can output the completion signal after the image acquisition is completed.
  • the image processing component after the image processing component receives each completion signal, it can start running its own data processing unit to process the image output by the image acquisition component 1-4.
  • the image acquisition components 1-4 can output corresponding event signals both when starting to acquire images and after completing image acquisition.
  • the above event signals are not necessarily signals indicating the completion of data processing, and can be signals at any stage of data processing. For example, it can be a start signal indicating the start of acquiring images, etc.
  • the output event signals can be received by other components and used as operating conditions for other components. That is to say, other components can be run based only on various event signals output by the image acquisition component, without obtaining the data processing results of the image acquisition component before running, and do not rely on the data processing results of the image acquisition component.
  • FIG. 7 is a schematic structural diagram of a processing component in the prior art.
  • the processing component in the prior art only includes a data input interface for receiving data, a data output interface for outputting data, and a data processing unit for processing data.
  • the asynchronous processing component provided by the embodiment of the present application includes an event receiving interface capable of receiving event signals and an event output interface capable of outputting event signals.
  • FIG. 8 is a schematic diagram of the connection relationship of processing components in the prior art.
  • the data output interface of the processing component connected to the starting end of the arrow in the figure is connected to the data input interface of the processing component connected to the ending end of the arrow.
  • the data output interface of processing component 1 is connected to the data input interface of processing component 2 and processing component 3 respectively.
  • the data output interface of processing component 2 is connected to the data input interface of processing component 4.
  • Processing component 4 and processing component 3 The data output interfaces are all connected to the data input interface of the processing component 5.
  • processing component 1 After the data processing unit in processing component 1 completes data processing, processing component 1 sends the processing results to processing component 2 and processing component 3, and the data processing units in processing component 2 and processing component 3 start data processing respectively. After the data processing unit in component 2 completes data processing, processing component 2 sends the processing results to processing component 4. After the data processing unit in processing component 4 completes data processing, processing component 4 sends the processing results to processing component 5. After the data processing unit in component 3 completes data processing, processing component 3 also sends the processing results to processing component 5. The data processing unit in processing component 5 processes the received processing results from processing component 4 and processing component 3.
  • the execution condition of the processing component located at the back end in the processing sequence is that the pre-processing component completes the data processing and outputs the processing result. That is, only after the pre-processing component completes the data processing, the subsequent processing components Only then can data processing begin.
  • the execution condition of the asynchronous processing component is related to the event signal output by the pre-order asynchronous processing component.
  • the asynchronous processing component can output an event signal at any stage during the data processing process of the data processing unit, triggering the subsequent asynchronous processing component to start running.
  • the above event signal is not necessarily an event signal that indicates the completion of data processing, and can be at any stage of data processing.
  • the image acquisition unit 1-4 can output a start signal and a completion signal when the image acquisition starts and when the image acquisition is completed. Therefore, when the subsequent asynchronous processing component receives the event signal and starts running, it can also output the start signal and the completion signal in the preamble.
  • the processing component starts running at any stage of data processing, rather than starting after the aforementioned processing component completes data processing and generates data processing results.
  • the data processing unit in the asynchronous processing component can continue its own data processing, so that the operation of each asynchronous assistant component does not depend on the data processing results of other asynchronous processing components, thus enabling the implementation of various asynchronous processing components. asynchronous data processing process.
  • FIG 9 is a schematic flow chart of the second asynchronous processing flow generation method provided by the embodiment of the present application.
  • the following step S107 is also included before the aforementioned step S105, and the aforementioned step S105 This can be achieved through the following step S105A.
  • S107 Determine the target action selected by the user through the second preset interface.
  • the above-mentioned target action is an action that needs to be executed by the data processing unit in the above-mentioned target processing component when the above-mentioned operating conditions are met.
  • the data processing unit in the target processing component may have a variety of different functions and can implement different actions.
  • the solution provided by the embodiment of the present application can configure the target action for the target processing component, so that when the operating conditions are met, Running the data processing unit enables the target actions configured for the data processing unit to be achieved.
  • the target action selected by the user can be one or more.
  • the above-mentioned target processing component is an image processing component.
  • the data processing unit in the image processing component can perform actions such as image noise reduction, image cropping, and image feature extraction.
  • the user can select a target action from them, for example, select image noise reduction as the target action. , then when the operating conditions are met, the image processing component performs image noise reduction on the received image.
  • FIG. 10 is a schematic diagram of a second preset interface provided by an embodiment of the present application.
  • the second preset interface displays the serial number of the operating condition, the name of the operating condition, and the target action to be executed when the operating condition is established.
  • the user can select the target action from the data processing unit of the target processing component through the target action selection drop-down box. Select the target action among the actions to be performed.
  • the interface shown in Figure 10 is only a form of the second preset interface, and the embodiment of the present application does not limit this.
  • the custom action added by the user in response to an instruction to add a custom action issued by the user through the fifth preset interface, the custom action added by the user can be obtained, and the above custom action can be added in the drop-down box of the second preset interface. action.
  • Custom actions added by users can be added to the drop-down box for subsequent repeated calls, realizing the reuse of custom actions.
  • S105A Configure the above-mentioned target processing component to receive the target event signal through the event receiving interface, and configure the above-mentioned target processing component to run the data processing unit when the above-mentioned operating conditions are established.
  • the executed data processing unit can be made to perform the target action.
  • step S106 when step S106 is executed to generate a data file based on the aforementioned steps S107 and S105A, the generated data file is used to control the target processing component to run the data processing unit to perform the target action when the operating conditions of the target processing component are established.
  • the user can select the target action from the actions that the data processing unit in the target processing component can perform, so that the data processing unit can perform the target action when the operating conditions are established, thereby Target processing
  • the operation of components is precisely controlled.
  • the target action is an action that the user can flexibly select from multiple actions that the data processing unit can perform.
  • the data processing unit in the target processing component can implement different actions when executing the target action when the operating conditions are met. function, improving the flexibility of the solution.
  • FIG 11 is a schematic flow chart of the third asynchronous processing flow generation method provided by the embodiment of the present application. Compared with the aforementioned embodiment shown in Figure 1, the above method also includes the following steps S108-S109.
  • S108 Determine the output event signal configured by the user through the third preset interface.
  • the event signals that the target processing component can output can be preset, and the identification of each preset event signal is displayed on the third preset interface, so that the user can change from the preset settings through the third preset interface. Select the output event signal from various event signals.
  • the identification of the above event signal may be the name or number of the event signal, etc.
  • S109 Configure the above-mentioned target processing component to output the above-mentioned output event signal through the event output interface during the operation of the data processing unit.
  • the above-mentioned target processing component can output the above-mentioned output event signal when the data processing unit starts running, can also output the above-mentioned output event signal during the operation of the data processing unit, or output the above-mentioned output event signal after the data processing unit ends. .
  • the operating conditions of the target processing component can be configured based on the event signals output by other asynchronous processing components, but also the output event signals output by the target processing component can be configured.
  • the configured output event signals are also It can be used as the running condition of other asynchronous processing components, which is conducive to generating a complete asynchronous processing process based on the event signal interaction between various asynchronous processing components.
  • FIG 12 is a schematic flow chart of the fourth asynchronous processing flow generation method provided by the embodiment of the present application. Compared with the aforementioned embodiment shown in Figure 1, the above step S103 can be implemented through the following steps S103A-S103B.
  • S103A Display preset logical relationship symbols that can represent logical relationships through the above-mentioned first preset interface.
  • the above-mentioned first preset interface also displays preset logical relationship symbols.
  • the above-mentioned logical relationship symbols include at least one of the following symbols: and symbol, or symbol, Negation symbols, parentheses, functions used to implement set functions.
  • the function for implementing the setting function may include a function for counting whether the current number of clusters is greater than the preset number of clusters.
  • the preset number of clusters may be 5, 6, etc.
  • the embodiments of the present application provide users with a rich type of logical relationship symbols.
  • the above logical relationship symbols are used to represent various different logical relationships. This is conducive to allowing users to generate operations that meet various needs based on the combinations of various logical relationships. conditions, improving the usability of the solution.
  • S103B Determine the target logical relationship symbol selected by the user from the displayed logical relationship symbols, and determine the logical relationship between the target event signals based on the above target logical relationship symbol.
  • logical relationship symbols can represent logical relationships between target event signals from preset logical relationship symbols. For example, select the AND symbol to indicate the existence and relationship between the target event signals, select the OR symbol to indicate the existence or relationship between the target event signals, select the negation symbol to indicate converting the target event signal into the opposite meaning, and select the parentheses to indicate the relationship between the target event signals. Combination of logical relationships, etc.
  • FIG. 13 is a schematic diagram of the second first preset interface provided by the embodiment of the present application.
  • the first default interface also includes preset logical relationship symbols including: brackets “(” and “)”, ampersand symbol “&&”, or symbol “
  • the logical relationship between signal 1 and signal 2 is the AND relationship
  • the logical relationship between signal 2 and signal 3 is the AND relationship
  • the logical relationship between signal 3 and signal 4 The relationship is an AND relationship.
  • the logical relationship symbols can be displayed through the graphical interface, so that the user can configure the logical relationship between the target event signals through the graphical interface, so that the user can simply and conveniently realize the target event signal. configuration of logical relationships.
  • signal 1-signal 4 shown in Figure 13 can be saved as event signal combination 1, and the user can directly call event signal combination 1 to generate running conditions when configuring other asynchronous processing components.
  • FIG 14 is a schematic diagram of the third first preset interface provided by the embodiment of the present application.
  • event signal combination 1 and signal 5 are called, and the logical relationship between event signal combination 1 and signal 5 is: OR relationship, indicating that the logical relationship recorded by event signal combination 1 is established or the data processing unit in the asynchronous processing component is run when signal 5 is received.
  • embodiments of the present application also provide an asynchronous processing flow generation device.
  • FIG. 15 is a schematic structural diagram of an asynchronous processing flow generation device provided by an embodiment of the present application.
  • the above device includes:
  • the component connection module 1501 is used to connect various asynchronous processing components based on the processing sequence of the asynchronous processing components configured by the user, wherein the asynchronous processing components include: a data input interface for receiving data, and data for processing data. A processing unit, a data output interface for outputting data, an event receiving interface for receiving event signals, and an event output interface for outputting event signals. After connecting, the data output interface of each asynchronous processing component is connected to the processing sequence. The data input interface of the next asynchronous processing component is connected;
  • the identification selection module 1502 is used to determine the target event signal selected by the user for the target processing component in the asynchronous processing component, and display the identification of the target event signal in the first preset interface, where the target event signal is: The event signal output by the pre-order asynchronous processing component through the event output interface, the pre-order asynchronous processing component is located before the target processing component in the processing sequence;
  • the logical relationship determination module 1503 is used to determine the logical relationship between the target event signals configured by the user according to the content displayed on the first preset interface;
  • the operating condition generation module 1504 is configured to generate operating conditions of the target processing component based on the logical relationship and the target event signal, wherein the operating condition is: output the target event signal in the preceding asynchronous processing component And if the logical relationship is satisfied, run the data processing unit in the target processing component;
  • the first component configuration module 1505 is used to configure the target processing component to receive the target event signal through the event receiving interface, and configure the target processing component to run the data processing unit when the operating condition is established;
  • the data file generation module 1506 is used to generate data files for data processing according to the asynchronous processing flow according to the configuration results.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiment of the present application, and configure the logical relationship between the target event signal and the target event signal for the target processing component in the asynchronous processing component, so as to
  • the operating conditions of the target processing component are configured so that the target processing component runs the data processing unit included in the target processing component when it obtains the target event signal and the target event signal satisfies the logical relationship. That is to say, after configuration, the target processing component does not start running the data processing unit after receiving the data output by the pre-order asynchronous processing component, but uses the event signal output by the pre-order asynchronous processing component as the running condition of the data processing unit.
  • the target processing component does not need to process the data after the pre-order asynchronous processing component completes the data processing and outputs the data. Instead, it can perform data processing after receiving the event signal at any stage during the data processing process of the pre-order asynchronous processing component. .
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component can start executing its own data processing process when it receives the target event signal and the target event signal meets the operating conditions.
  • the data processing of the two can be executed in parallel.
  • the asynchronous processing component can be configured to implement asynchronous data processing.
  • users can configure the asynchronous processing unit by performing simple operations in the visual first preset interface, and then generate various complex asynchronous processing processes based on the configuration of the asynchronous processing unit.
  • the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple and fast, reduces the user's learning cost, has a wider application range, and saves the maintenance overhead of codes or scripts. .
  • the above device further includes:
  • An action determination module used to determine the target action selected by the user through the second preset interface, wherein the target action is: an action that the data processing unit in the target processing component needs to perform when the operating conditions are met. ;
  • the first component configuration module 1505 is specifically used for:
  • the target processing component is configured to receive the target event signal through the event receiving interface, and the target processing component is configured to run the data processing unit when the running condition is established, so that the executed data processing unit performs the target action.
  • the user can select the target action from the actions that the data processing unit in the target processing component can perform, so that the data processing unit can perform the target action when the operating conditions are established, thereby Precisely control the operation of target processing components.
  • the target action is an action that the user can flexibly select from multiple actions that the data processing unit can perform.
  • the data processing unit in the target processing component can implement different actions when executing the target action when the operating conditions are met. function, improving the flexibility of the solution.
  • the device further includes:
  • An output signal determination module used to determine the output event signal configured by the user through the third preset interface
  • the second component configuration module is used to configure the target processing component to output the output event signal through the event output interface during the operation of the data processing unit.
  • the operating conditions of the target processing component can be configured based on the event signals output by other asynchronous processing components, but also the output event signals output by the target processing component can be configured.
  • the configured output event signals are also It can be used as the running condition of other asynchronous processing components, which is conducive to generating a complete asynchronous processing process based on the event signal interaction between various asynchronous processing components.
  • the logical relationship determination module 1503 is specifically used to:
  • a target logical relationship symbol selected by the user from the displayed logical relationship symbols is determined, and a logical relationship between the target event signals is determined based on the target logical relationship symbol.
  • the logical relationship symbols can be displayed through the graphical interface, so that the user can configure the logical relationship between the target event signals through the graphical interface, so that the user can simply and conveniently realize the target event signal. configuration of logical relationships.
  • the logical relationship symbols include at least one of the following symbols: an AND symbol, an OR symbol, a negation symbol, parentheses, and a function used to implement a set function.
  • the embodiments of the present application provide users with a rich type of logical relationship symbols.
  • the above logical relationship symbols are used to represent various different logical relationships. This is conducive to allowing users to generate operations that meet various needs based on the combinations of various logical relationships. conditions, improved Program availability.
  • the asynchronous processing component is a component in a machine vision algorithm platform, and the data processing unit in the asynchronous processing component is used to process image data and/or video data.
  • an asynchronous processing flow for image data and/or video data can be generated.
  • the operation of an asynchronous processing component is not triggered by the processing result output by its pre-order asynchronous processing component, but by the event signal output by the pre-order asynchronous processing component, that is, the asynchronous processing component
  • the asynchronous processing component There is no coupling relationship between the operation and the processing results output by the preceding asynchronous processing components, so that each asynchronous processing component can run in parallel, improving the processing efficiency of image data and/or video data.
  • An embodiment of the present application also provides an electronic device, as shown in Figure 16, including:
  • Memory 1601 used to store computer programs
  • the processor 1602 is configured to implement the method steps shown in any of the foregoing asynchronous processing flow generation methods when executing the program stored in the memory 1601.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiments of this application, and configure the target event signal for the target processing component in the asynchronous processing component.
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component can start executing its own data processing process when it receives the target event signal and the target event signal meets the operating conditions.
  • the data processing process between the two is asynchronous. Therefore, the asynchronous processing component can be configured to implement asynchronous data processing through the solution provided by the embodiment of this application.
  • the user can configure the asynchronous processing unit through the visual first preset interface. For the user, the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple.
  • the above-mentioned electronic device may also include a communication bus and/or a communication interface.
  • the processor 1602, the communication interface, and the memory 1601 complete communication with each other through the communication bus.
  • the communication bus mentioned in the above-mentioned electronic equipment can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc.
  • PCI Peripheral Component Interconnect
  • EISA Extended Industry Standard Architecture
  • the communication bus can be divided into address bus, data bus, control bus, etc. For ease of presentation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
  • the communication interface is used for communication between the above-mentioned electronic devices and other devices.
  • the memory may include random access memory (Random Access Memory, RAM) or non-volatile memory (Non-Volatile Memory, NVM), such as at least one disk memory.
  • RAM Random Access Memory
  • NVM Non-Volatile Memory
  • the memory may also be at least one storage device located far away from the aforementioned processor.
  • the above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (Network Processor, NP), etc.; it can also be a digital signal processor (Digital Signal Processor, DSP), dedicated integrated processor Circuit (Application Specific Integrated Circuit, ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
  • CPU central processing unit
  • NP Network Processor
  • DSP Digital Signal Processor
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • a computer-readable storage medium stores a computer program.
  • any of the asynchronous processing procedures described above are implemented. Generate the steps of the method.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiments of this application, and configure the connection relationship between the asynchronous processing components.
  • the target processing component configures the logical relationship between the target event signal and the target event signal, thereby configuring the operating conditions of the target processing component, so that the target processing component runs when the target event signal is obtained and the target event signal satisfies the logical relationship.
  • the data processing unit contained in the target processing component that is to say, after configuration, the target processing component does not start running the data processing unit after receiving the data output by the pre-order asynchronous processing component, but uses the event signal output by the pre-order asynchronous processing component as the running condition of the data processing unit.
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component can start executing its own data processing process when it receives the target event signal and the target event signal meets the operating conditions.
  • the data processing process between the two is asynchronous. Therefore, the asynchronous processing component can be configured to implement asynchronous data processing through the solution provided by the embodiment of this application.
  • the user can configure the asynchronous processing unit through the visual first preset interface. For the user, the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple.
  • a computer program product containing instructions is also provided, which, when run on a computer, causes the computer to execute any of the asynchronous processing flow generation methods in the above embodiments.
  • the user can configure the connection relationship between the asynchronous processing components through the solution provided by the embodiments of this application, and configure the target event signal for the target processing component in the asynchronous processing component.
  • the pre-order asynchronous processing component can continue data processing after outputting the event signal.
  • the target processing component can start executing its own data processing process when it receives the target event signal and the target event signal meets the operating conditions.
  • the data processing process between the two is asynchronous. Therefore, the asynchronous processing component can be configured to implement asynchronous data processing through the solution provided by the embodiment of this application.
  • the user can configure the asynchronous processing unit through the visual first preset interface. For the user, the implementation of the asynchronous processing flow generation solution provided by the embodiment of the present application is relatively simple.
  • the computer program product includes one or more computer instructions.
  • the computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device.
  • the computer instructions may be stored in or transmitted from one computer-readable storage medium to another, e.g., the computer instructions may be transferred from a website, computer, server, or data center Transmission to another website, computer, server or data center by wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) means.
  • 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 one or more available media integrated.
  • the available media may be magnetic media (eg, floppy disk, hard disk, tape), optical media (eg, DVD), or other media (eg, Solid State Disk (SSD)), etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

本申请实施例提供了一种异步处理流程生成方法及装置,涉及数据处理技术领域,上述方法包括:基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件;确定用户为异步处理组件中的目标处理组件选择的目标事件信号,在第一预设界面中显示目标事件信号的标识;确定用户根据第一预设界面显示的内容配置的目标事件信号之间的逻辑关系;基于逻辑关系与目标事件信号,生成目标处理组件的运行条件;配置目标处理组件通过事件接收接口接收目标事件信号,并配置目标处理组件在运行条件成立的情况下运行数据处理单元,根据配置结果,生成按照异步处理流程进行数据处理的数据文件。应用本申请实施例提供的方案能够配置异步处理组件实现异步数据处理。

Description

一种异步处理流程生成方法及装置
本申请要求于2022年9月9日提交中国专利局、申请号为202211105443.8发明名称为“一种异步处理流程生成方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及数据处理技术领域,特别是涉及一种异步处理流程生成方法及装置。
背景技术
现有技术中的处理组件内封装有数据处理单元、数据输入接口与数据输出接口,电子设备可以调用处理组件,通过数据输入接口将数据输入处理组件,数据处理单元对数据进行处理,并从数据输出接口输出处理结果。
在此基础上,按照预设的处理顺序,可以分别将各个处理组件的数据输出接口与其他处理组件的数据输入接口相连,使得各个处理组件能够共同实现一个数据处理流程,上述对于各组件的连接可以称为针对组件的配置。具体的,每一处理组件中的数据处理单元对数据进行处理之后,可以通过输出接口将处理结果输入所连接的下一处理组件的输入接口,下一处理组件接收到处理结果后,可以继续通过自身封装的数据处理单元对接收到的处理结果继续进行处理,依此类推,各个处理组件共同实现了一个数据处理流程。
但采用上述配置方式对处理组件进行配置之后,只有在连接顺序中位于前端的处理组件完成数据处理并输出处理结果之后,位于后端的处理组件才能开始进行数据处理,各个处理组件之间实现数据处理流程是同步流程。采用现有技术的配置方式无法配置处理组件实现异步数据处理。
发明内容
本申请实施例的目的在于提供一种异步处理流程生成方法及装置,以配置处理组件实现异步数据处理。具体技术方案如下:
第一方面,本申请实施例提供了一种异步处理流程生成方法,所述方法包括:
基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,所述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与所述处理顺序中的下一异步处理组件的数据输入接口相连;
确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示所述目标事件信号的标识,其中,所述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,所述前序异步处理组件在所述处理顺序中位于所述目标处理组件之前;
确定用户根据所述第一预设界面显示的内容配置的所述目标事件信号之间的逻辑关系;
基于所述逻辑关系与所述目标事件信号,生成所述目标处理组件的运行条件,其中,所述运行条件为:在前序异步处理组件输出所述目标事件信号且满足所述逻辑关系的情况下,运行所述目标处理组件中的数据处理单元;
配置所述目标处理组件通过事件接收接口接收所述目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元;
根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
本申请的一个实施例中,在所述配置所述目标处理组件通过事件接收接口接收所述目标事件信号之 前,还包括:
确定用户通过第二预设界面选择的目标动作,其中,所述目标动作为:在满足所述运行条件的情况下所述目标处理组件中的数据处理单元需要执行的动作;
所述配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,包括:
配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,以使得被运行的数据处理单元执行目标动作。
本申请的一个实施例中,所述方法还包括:
确定用户通过第三预设界面配置的输出事件信号;
配置所述目标处理组件在数据处理单元运行过程中通过事件输出接口输出所述输出事件信号。
本申请的一个实施例中,所述确定用户根据所述第一预设界面所显示的内容配置的所述目标事件之间的逻辑关系,包括:
通过所述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号;
确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于所述目标逻辑关系符号确定所述目标事件信号之间的逻辑关系。
本申请的一个实施例中,所述逻辑关系符号包括以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数。
本申请的一个实施例中,所述异步处理组件为机器视觉算法平台中的组件,所述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
第二方面,本申请实施例提供了一种异步处理流程生成装置,所述装置包括:
组件连接模块,用于基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,所述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与所述处理顺序中的下一异步处理组件的数据输入接口相连;
标识选择模块,用于确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示所述目标事件信号的标识,其中,所述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,所述前序异步处理组件在所述处理顺序中位于所述目标处理组件之前;
逻辑关系确定模块,用于确定用户根据所述第一预设界面显示的内容配置的所述目标事件信号之间的逻辑关系;
运行条件生成模块,用于基于所述逻辑关系与所述目标事件信号,生成所述目标处理组件的运行条件,其中,所述运行条件为:在前序异步处理组件输出所述目标事件信号且满足所述逻辑关系的情况下,运行所述目标处理组件中的数据处理单元;
第一组件配置模块,用于配置所述目标处理组件通过事件接收接口接收所述目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元;
数据文件生成模块,用于根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
本申请的一个实施例中,所述装置还包括:
动作确定模块,用于确定用户通过第二预设界面选择的目标动作,其中,所述目标动作为:在满足所述运行条件的情况下所述目标处理组件中的数据处理单元需要执行的动作;
所述第一组件配置模块,具体用于:
配置所述目标处理组件通过事件接收接口接收目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,以使得被运行的数据处理单元执行目标动作。
本申请的一个实施例中,所述装置还包括:
输出信号确定模块,用于确定用户通过第三预设界面配置的输出事件信号;
第二组件配置模块,用于配置所述目标处理组件在数据处理单元运行过程中通过事件输出接口输出所述输出事件信号。
本申请的一个实施例中,所述逻辑关系确定模块,具体用于:
通过所述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号;
确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于所述目标逻辑关系符号确定所述目标事件信号之间的逻辑关系。
本申请的一个实施例中,所述逻辑关系符号包括以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数。
本申请的一个实施例中,所述异步处理组件为机器视觉算法平台中的组件,所述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
第三方面,本申请实施例提供了一种电子设备,其表征在于,包括:
存储器,用于存放计算机程序;
处理器,用于执行存储器上所存放的程序时,实现第一方面任一所述的方法。
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现第一方面任一所述的方法步骤。
第五方面,本申请实施例还提供了一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述第一方面任一所述的方法。
本申请实施例有益效果:
本申请实施例提供的异步处理流程生成方法中,基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,连接后每一异步处理组件的数据输出接口与处理顺序中的下一异步处理组件的数据输入接口相连;确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示目标事件信号的标识;确定用户根据第一预设界面显示的内容配置的目标事件信号之间的逻辑关系;基于逻辑关系与目标事件信号,生成目标处理组件的运行条件;配置目标处理组件通过事件接收接口接收目标事件信号,并配置目标处理组件在运行条件成立的情况下运行数据处理单元,之后根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
由以上可见,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
这样,目标处理组件无需在前序异步处理组件完成数据处理并输出数据之后才进行数据处理,而是在前序异步处理组件进行数据处理过程中的任意阶段接收到事件信号后即可进行数据处理。
并且,前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信 号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者的数据处理可以并行执行,是异步关系,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户通过在可视化的第一预设界面中进行简便操作即可实现对异步处理单元的配置,进而基于对异步处理单元的配置生成各种复杂的异步处理流程,相较于通过编写代码或采用脚本生成处理流程,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单和快捷,降低了用户的学习成本,应用范围更加广泛,且节省了代码或脚本的维护开销。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,还可以根据这些附图获得其他的附图。
图1为本申请实施例提供的第一种异步处理流程生成方法的流程示意图;
图2为本申请实施例提供的一种异步处理组件的结构示意图;
图3为本申请实施例提供的一种异步处理组件之间连接关系的示意图;
图4为本申请实施例提供的一种信息槽界面的示意图;
图5为本申请实施例提供的第一种第一预设界面的示意图;
图6a为本申请实施例提供的第一种图像处理流程处理顺序示意图;
图6b为本申请实施例提供的第二种图像处理流程处理顺序示意图;
图7为现有技术中的处理组件的结构示意图;
图8为现有技术中处理组件连接关系的示意图;
图9为本申请实施例提供的第二种异步处理流程生成方法的流程示意图;
图10为本申请实施例提供的一种第二预设界面的示意图;
图11为本申请实施例提供的第三种异步处理流程生成方法的流程示意图;
图12为本申请实施例提供的第四种异步处理流程生成方法的流程示意图;
图13为本申请实施例提供的第二种第一预设界面的示意图;
图14为本申请实施例提供的第三种第一预设界面的示意图;
图15为本申请实施例提供的一种异步处理流程生成装置的结构示意图;
图16为本申请实施例提供的一种电子设备的结构示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员基于本申请所获得的所有其他实施例,都属于本申请保护的范围。
为了配置异步处理组件以实现异步处理流程,本申请实施例提供了一种异步处理流程生成方法及装置。
本申请实施例提供了一种异步处理流程生成方法,上述方法包括:
基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,上述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与上述处理顺序中的下一异步处理组件的数据输入接口相连;
确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示目标事件信号的标识,其中,上述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,上述前序异步处理组件在上述处理顺序中位于上述目标处理组件之前;
确定用户根据上述第一预设界面显示的内容配置的目标事件信号之间的逻辑关系;
基于上述逻辑关系与上述目标事件信号,生成目标处理组件的运行条件,其中,上述运行条件为:在前序异步处理组件输出目标事件信号且满足上述逻辑关系的情况下,运行上述目标处理组件中的数据处理单元;
配置上述目标处理组件通过事件接收接口接收目标事件信号,并配置上述目标处理组件在上述运行条件成立的情况下运行数据处理单元;
根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
由以上可见,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
这样,目标处理组件无需在前序异步处理组件完成数据处理并输出数据之后才进行数据处理,而是在前序异步处理组件进行数据处理过程中的任意阶段接收到事件信号后即可进行数据处理。
并且,前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者的数据处理可以并行执行,是异步关系,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户通过在可视化的第一预设界面中进行简便操作即可实现对异步处理单元的配置,进而基于对异步处理单元的配置生成各种复杂的异步处理流程,相较于通过编写代码或采用脚本生成处理流程,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单和快捷,降低了用户的学习成本,应用范围更加广泛,且节省了代码或脚本的维护开销。
参见图1,为本申请实施例提供的第一种异步处理流程生成方法的流程示示意图,上述方法包括以下步骤S101-S106。
S101:基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件。
上述处理顺序可以理解为:各异步处理组件的触发顺序。
需要说明的是,本申请实施例提供的方案中,各异步处理组件可以有触发的先后顺序,但是各异步处理组件被触发之后,即可同时并行执行多项数据处理任务。
其中,上述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口。
参见图2,为本申请实施例提供的一种异步处理组件的结构示意图。
由图2可见,上述异步处理组件中包含数据处理单元、数据输入接口、数据输出接口、事件接收接口与事件输出接口。
另外,连接后每一异步处理组件的数据输出接口可以与处理顺序中的下一异步处理组件的数据输入 接口相连,其中,处理顺序中的下一异步处理组件可以是一个异步处理组件,也可以是并列的多个异步处理组件;相应的,每一异步处理组件的数据输入接口可以与处理顺序中的上一数据输出接口相连,其中,处理顺序中的上一异步处理组件可以是一个异步处理组件,也可以是并列的多个异步处理组件。具体介绍详见后续图3所示的举例。
具体的,本申请实施例提供的方案中,可以为用户预先提供多种异步处理组件以供用户进行选择,用户通过输入组件选择指令选择异步处理组件,本实施例的执行主体可以基于组件选择指令确定用户选择的异步处理组件。
本申请实施例不限定上述预先提供的异步处理组件的功能。例如,上述异步处理组件可以是用于图像预处理的组件、用于图像分割的组件、用于图像特征提取的组件等。
本申请的一个实施例中,可以在第四预设界面上显示可供选择的异步处理组件的标识,异步处理组件的标识可以为异步处理组件的编号、名称、功能描述等,用户通过查看第四预设界面上显示的内容,可以从所提供的异步处理组件中进行选择。
另外,用户在选择异步处理组件之后,可以输入组件连接指令控制执行主体连接各个异步处理组件。
具体的,根据处理顺序对各个异步处理组件进行连接后,一个异步处理组件的数据输出接口可以连接多个异步处理组件的数据输入接口,多个异步处理组件的数据输出接口也可以连接同一异步处理组件的数据输入接口,本申请实施例对此不进行限定。
参见图3,为本申请实施例提供的一种异步处理组件之间连接关系的示意图。
图3中箭头的起始端连接的异步处理组件的数据输出接口与终止端连接的异步处理组件的数据输入接口相连,由图3可见,异步处理组件1的数据输出接口与异步处理组件3的数据输入接口相连,异步处理组件2的数据输出接口与异步处理组件3和异步处理组件4的数据输入接口分别相连。则异步处理组件2的数据输出接口与两个异步处理组件的数据输入接口相连,异步处理组件3的数据输入接口与两个异步处理组件的数据输出接口相连。
S102:确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示目标事件信号的标识。
其中,上述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,上述前序异步处理组件在上述处理顺序中位于上述目标处理组件之前。
异步处理组件在执行过程中,可以产生各类事件信号,如,执行开始信号、执行结束信号、执行异常信号、执行时间戳信号等。
本申请实施例提供的方案中,前序异步处理组件输出的事件信号可以作为处理顺序在其后的异步处理组件的运行条件。
具体的,用户可以从目标处理组件的前序异步处理组件能够输出的所有事件信号中选择所需的事件信号作为目标事件信号。
另外,上述目标事件信号的标识可以为目标事件信号的名称、编号等。
各个异步处理组件中的每一异步处理组件都可以作为目标处理组件,用户可以根据异步处理流程的配置需求,选择目标处理组件,所选择的处理组件可以是一个或多个,针对每一目标处理组件均可以通过步骤S102-S105对该目标处理组件进行配置。
本申请的一个实施例中,可以在目标处理组件中添加信息槽,在信息槽中配置目标处理组件对应的目标事件信号。具体的,本申请实施例的执行主体可以显示信息槽界面,用户可以在信息槽界面中选择 目标事件信号。
参见图4,为本申请实施例提供的一种信息槽界面的示意图。
由图可见,信息槽界面中显示有为目标处理组件配置的运行条件,显示有运行条件的序号,如序号1,显示有运行条件的名称,如事件1,通过点击配置按钮可以对运行条件进行配置,具体的,可以配置运行条件中包含的目标事件信号以及目标事件信号之间的逻辑关系,通过点击添加按钮可以为目标处理组件添加新的运行条件。
其中,已被选择的目标事件信号的标识可以被显示在第一预设界面中。
参见图5,为本申请实施例提供的第一种第一预设界面的示意图。
上述第一预设界面中显示有已选择的目标事件信号的标识,包括信号1的标识、信号2的标识、信号3的标识与信号4的标识。通过点击订阅按钮用户可以选择前序异步处理组件的其他事件信号作为目标事件信号。
S103:确定用户根据上述第一预设界面显示的内容配置的目标事件信号之间的逻辑关系。
具体的,目标事件信号之间的逻辑关系可以包括与、或、非等逻辑关系。用户可以根据第一预设界面显示的目标事件信号的标识确定已选择的目标事件信号,之后再通过在第一预设界面上选取目标事件信号的标识来配置已选择的目标事件信号之间的逻辑关系。
以前述图5所示的第一预设界面为例,上述第一预设界面显示有信号1的标识、信号2的标识、信号3的标识、信号4的标识,用户可以基于第一预设界面显示的内容配置信号1与信号2之间的逻辑关系为与关系,信号2与信号3之间的逻辑关系为与关系,信号3与信号4之间的逻辑关系为或关系。
此外,本申请实施例提供的方案还可以记录上述目标事件信号以及目标事件信号之间的逻辑关系,作为一个事件信号组合,用户在对其他异步处理组件进行配置时,可以直接调用该事件信号组合,生成该异步处理组件的运行条件,或者在该事件信号组合的基础上添加其他事件信号,并设置该事件信号组合与新添加的事件信号之间的逻辑关系,形成新的运行条件。
S104:基于上述逻辑关系与上述目标事件信号,生成目标处理组件的运行条件。
其中,上述运行条件为:在前序异步处理组件输出目标事件信号且满足上述逻辑关系的情况下,运行上述目标处理组件中的数据处理单元。
本申请实施例提供的方案中,在上述逻辑关系与目标事件信号配置完毕后,可以生成记录有上述目标事件信号的标识和上述逻辑关系的可执行文件,用于记录上述运行条件。
S105:配置上述目标处理组件通过事件接收接口接收目标事件信号,并配置上述目标处理组件在上述运行条件成立的情况下运行数据处理单元。
具体的,可以配置上述目标处理组件的事件接收接口持续监控前序异步处理组件中用于输出目标事件信号的事件输出接口,从而接收目标事件信号。
并且在接收到目标事件信号后,目标处理组件可以确定接收到的目标事件信号是否满足运行条件,具体的,可以读取前述步骤S104生成的记录运行条件的可执行文件,判断目标事件信号是否满足运行条件。若满足上述运行条件,则运行数据处理单元进行数据处理,从而实现异步处理流程的配置。
S106:根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
结合前述步骤S101-步骤S105可知,上述配置结果用于执行以下动作:针对每一异步处理组件,判断该异步处理组件的运行条件是否成立,并在运行条件成立的情况下控制该异步处理组件运行数据处理单元。
得到配置结果之后,可以用代码、配置参数等描述所得的配置结果,生成包含上述代码、配置参数等的数据文件,上述数据文件可以是脚本文件或者其他可执行文件。
可见,上述数据文件中可以记录有按照异步处理流程进行数据处理的代码与配置参数等。上述数据文件用于:针对每一异步处理组件,判断该异步处理组件的运行条件是否成立,并在运行条件成立的情况下控制该异步处理组件运行数据处理单元。
在上述基础上,生成上述数据文件后,本申请实施例的执行主体在需要执行异步处理流程的情况下可以运行上述数据文件,从而在运行过程中执行上述配置结果描述的动作:判断异步处理组件的运行条件是否成立,若成立则调用该异步处理组件运行数据处理单元,从而控制异步处理流程的运行。
由以上可见,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
这样,目标处理组件无需在前序异步处理组件完成数据处理并输出数据之后才进行数据处理,而是在前序异步处理组件进行数据处理过程中的任意阶段接收到事件信号后即可进行数据处理。
并且,前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者的数据处理过程可以并行执行,是异步关系,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户通过在可视化的第一预设界面中进行简便操作即可实现对异步处理单元的配置,进而基于对异步处理单元的配置生成各种复杂的异步处理流程,相较于通过编写代码或采用脚本生成处理流程,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单和快捷,降低了用户的学习成本,应用范围更加广泛,且节省了代码或脚本的维护开销。
本申请的一个实施例中,执行主体为机器视觉算法平台,上述异步处理组件为上述机器视觉算法平台中的组件,上述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
这样采用本申请实施例提供的方案对机器视觉算法平台中用于对图像数据和/或视频数据进行处理的异步处理组件进行配置之后,可以生成针对图像数据和/或视频数据的异步处理流程,在所生成的异步处理流程中,一个异步处理组件的运行不是由其前序异步处理组件的输出的处理结果触发,而是由前序异步处理组件输出的事件信号触发,也即异步处理组件的运行与其前序异步处理组件的输出的处理结果之间没有耦合关系,从而各异步处理组件可以并行运行,提高了图像数据和/或视频数据的处理效率。
下面通过具体的实施例,描述本申请实施例提供的异步处理流程生成方法。
以异步的图像处理流程为例,参见图6a,为本申请实施例提供的第一种图像处理流程处理顺序示意图。
由图可见,图像处理流程中存在四个图像获取组件1-4,分别用于获取相机1-4拍摄的图像,图像获取组件1-4的数据输入接口用于获取所对应的相机拍摄的图像,数据输出接口用于输出所获取的图像,图像获取组件1-4的数据输出接口均与图像处理组件的数据输入接口相连。
图像获取组件1-4在输出图像后分别通过自身的事件输出接口输出表示图像输出完毕的完成信号,图像获取组件1-4在输出完成信号之后可以继续获取新的图像。图像处理组件的事件接收接口接收完成 信号,各完成信号中任意两个完成信号之间的逻辑关系均为与关系,则图像处理组件的运行条件为:在完全接收到各个完成信号之后运行数据处理单元,对图像获取组件1-4输出的图像进行处理。
再参见图6b,为本申请实施例提供的第二种图像处理流程处理顺序示意图。
图6b所示实施例的应用场景可以是车辆抓拍识别场景,该场景下,为了提高车辆识别效率,监控相机开始抓拍车辆图像时,可以并行采用雷达采集雷达图像,这样可以结合监控相机抓拍的图像以及雷达采集的雷达图像进行车辆识别。
由图6b可以看出,一方面,图像获取组件1-4在开始获取图像时,可以输出开始信号,雷达采集组件可以接收各开始信号,各开始信号中任意两个开始信号之间的逻辑关系均为或关系,则雷达采集组件的运行条件为:在接收到任一开始信号之后运行数据处理单元采集雷达图像;另一方面,图像获取组件1-4在图像获取完毕之后,可以输出完成信号,与前述图6a所示举例类似的,图像处理组件接收到各个完成信号之后,可以开始运行自身的数据处理单元对图像获取组件1-4输出的图像进行处理。
可以看出,图像获取组件1-4在开始获取图像以及获取图像完毕之后可以均可以输出相应的事件信号,上述事件信号不一定是表征数据处理完成的信号,可以是数据处理任意阶段的信号,如可以是表征开始获取图像的开始信号等。所输出的事件信号可以分别被其他组件接收、作为其他组件的运行条件。也就是,其他组件仅仅基于图像采集组件输出的各类事件信号即可运行,而不需获取到图像采集组件的数据处理结果后再运行,不依赖于图像获取组件的数据处理结果。
另外,为了突出本申请实施例提供的异步处理流程生成方法与现有技术之间的区别,接下来对现有技术中的同步处理流程生成方法进行说明。
首先,对现有技术中的处理组件的结构进行说明。
参见图7,为现有技术中的处理组件的结构示意图。
由图可见,现有技术中的处理组件内仅包含用于接收数据的数据输入接口、用于输出数据的数据输出接口以及用于处理数据的数据处理单元。由此可见与现有技术相比,本申请实施例提供的异步处理组件中包含了能够接收事件信号的事件接收接口以及能够输出事件信号的事件输出接口。
另外,参见图8,为现有技术中处理组件连接关系的示意图。
图中箭头的起始端连接的处理组件的数据输出接口与箭头终止端连接的处理组件的数据输入接口相连。
由图可见,处理组件1的数据输出接口与处理组件2和处理组件3的数据输入接口分别相连,处理组件2的数据输出接口与处理组件4的数据输入接口相连,处理组件4和处理组件3的数据输出接口均与处理组件5的数据输入接口相连。
则处理组件1中的数据处理单元完成数据处理之后,处理组件1将处理结果发送至处理组件2和处理组件3,处理组件2和处理组件3中的数据处理单元便分别开始进行数据处理,处理组件2中的数据处理单元完成数据处理后,处理组件2将处理结果发送至处理组件4,处理组件4中的数据处理单元完成数据处理之后,处理组件4将处理结果发送至处理组件5,处理组件3中的数据处理单元完成数据处理之后,处理组件3也将处理结果发送至处理组件5,处理组件5中的数据处理单元对接收到的处理组件4和处理组件3的处理结果进行处理。
由此可见,现有技术中在处理顺序中位于后端的处理组件的执行条件为前序处理组件完成数据处理并输出处理结果,也就是只有在前序处理组件完成数据处理之后,后续的处理组件才能够开始进行数据处理。而本申请实施例提供的方案中异步处理组件的执行条件与前序异步处理组件输出的事件信号有关, 异步处理组件可以在数据处理单元进行数据处理过程中的任意阶段输出事件信号,触发后续异步处理组件开始运行,其中,上述事件信号不一定是表征数据处理完毕的事件信号,可以是数据处理任意阶段的事件信号,如图6b中图像采集单元1-4可以在开始获取图像以及图像获取完毕时输出开始信号和完成信号,从而,后续异步处理组件接收到事件信号开始运行时,也可以在前序处理组件数据处理的任意阶段开始运行,而不是在前述处理组件完成数据处理并产生数据处理结果之后才开始运行。在输出事件信号之后,异步处理组件中的数据处理单元可以继续进行自身的数据处理,这样使得各异步助理组件的运行不依赖于其他异步处理组件的数据处理结果,从而可以实现各个异步处理组件之间的异步数据处理流程。
参见图9,为本申请实施例提供的第二种异步处理流程生成方法的流程示意图,与前述图1所示的实施例相比,在前述步骤S105之前还包括以下步骤S107,并且前述步骤S105可以通过以下步骤S105A实现。
S107:确定用户通过第二预设界面选择的目标动作。
其中,上述目标动作为:在满足上述运行条件的情况下上述目标处理组件中的数据处理单元需要执行的动作。
具体的,目标处理组件中的数据处理单元可能具有多种不同的功能,能够实现不同的动作,本申请实施例提供的方案可以为目标处理组件配置目标动作,使得在满足运行条件的情况下,运行数据处理单元能够实现为数据处理单元配置的目标动作。用户选择的目标动作可以为一个或多个。
例如,上述目标处理组件为图像处理组件,图像处理组件中的数据处理单元能够执行图像降噪、图像裁剪、图像特征提取等动作,用户可以从中选择目标动作,如,选择图像降噪作为目标动作,则在满足运行条件的情况下,图像处理组件对接收到的图像进行图像降噪。
另外,参见图10,为本申请实施例提供的一种第二预设界面的示意图。
由图可见,第二预设界面中显示有运行条件的序号、运行条件的名称以及运行条件成立的情况下执行的目标动作,用户可以通过目标动作选择下拉框从目标处理组件的数据处理单元能够执行的动作中选择目标动作。
图10所示的界面仅为第二预设界面的一种形式,本申请实施例对此不进行限制。
本申请的一个实施例中,可以响应于用户通过第五预设界面发出的自定义动作的添加指令,获得用户添加的自定义动作,并在第二预设界面的下拉框中添加上述自定义动作。
这样可以使得用户根据自身的实际需求灵活的添加自定义动作,提高了方案的灵活性和可扩展性,有利于实现复杂的实际业务。且可以将用户添加的自定义动作添加至下拉框,以供后续重复调用,实现了自定义动作的复用。
S105A:配置上述目标处理组件通过事件接收接口接收目标事件信号,配置上述目标处理组件在上述运行条件成立的情况下运行数据处理单元。
本步骤中,配置上述目标处理组件通过事件接收接口接收目标事件信号,并配置上述目标处理组件在上述运行条件成立的情况下运行数据处理单元后,可以使得被运行的数据处理单元执行目标动作
此外,在前述步骤S107和S105A的基础上执行步骤S106生成数据文件时,所生成的数据文件用于在目标处理组件的运行条件成立时控制目标处理组件运行数据处理单元执行目标动作。
由以上可见,本申请实施例提供的方案中,用户可以从目标处理组件内的数据处理单元能够执行的动作中选择目标动作,使得在运行条件成立的情况下数据处理单元能够执行目标动作,从而对目标处理 组件的运行进行精确地控制。
另外,目标动作是用户从数据处理单元能够执行的多个动作灵活选取的动作,根据目标动作的不同,目标处理组件内的数据处理单元在满足运行条件的情况下执行目标动作时,可以实现不同的功能,提高了方案的灵活性。
参见图11,为本申请实施例提供的第三种异步处理流程生成方法的流程示意图,与前述图1所示的实施例相比,上述方法还包括以下步骤S108-S109。
S108:确定用户通过第三预设界面配置的输出事件信号。
本申请实施例提供的方案中,可以预先设置目标处理组件能够输出的事件信号,并在第三预设界面显示预先设置的各个事件信号的标识,使得用户能够通过第三预设界面从预先设置的各个事件信号中选择输出事件信号。
上述事件信号的标识可以为事件信号的名称或编号等。
S109:配置上述目标处理组件在数据处理单元运行过程中通过事件输出接口输出上述输出事件信号。
具体的,上述目标处理组件可以在数据处理单元运行开始时输出上述输出事件信号,也可以在数据处理单元运行的过程中输出上述输出事件信号,或者在数据处理单元运行结束后输出上述输出事件信号。
由以上可见,本申请实施例提供的方案中不仅可以基于其他异步处理组件输出的事件信号配置目标处理组件的运行条件,还可以配置目标处理组件输出的输出事件信号,所配置的输出事件信号又可以作为其他异步处理组件的运行条件,这样有利于基于各异步处理组件之间的事件信号交互生成完整的异步处理流程。
参见图12,为本申请实施例提供的第四种异步处理流程生成方法的流程示意图,与前述图1所示的实施例相比,上述步骤S103可以通过以下步骤S103A-S103B实现。
S103A:通过上述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号。
具体的,上述第一预设界面上除了显示目标事件信号的标识之外,还显示有预设的逻辑关系符号,上述逻辑关系符号中包含以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数。
例如,上述实现设定功能的函数可以包括用于统计当前簇数量是否大于预设簇数量的函数等,如,上述预设簇数量可以为5、6等。
可见,本申请实施例为用户提供了类型丰富的逻辑关系符号,上述逻辑关系符号用于表示各种不同的逻辑关系,这样有利于使得用户基于各种逻辑关系符合的组合生成满足多样需求的运行条件,提高了方案的可用性。
S103B:确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于上述目标逻辑关系符号确定目标事件信号之间的逻辑关系。
用户可以从预设的逻辑关系符号中选择能够表示目标事件信号之间逻辑关系的逻辑关系符号。例如,选择与符号表示目标事件信号之间存在与关系,选择或符号表示目标事件信号之间存在或关系,选择否定符号表示将目标事件信号转换为相反的含义,选择括号表示对目标事件信号之间逻辑关系进行组合等。
参见图13,为本申请实施例提供的第二种第一预设界面的示意图。
在前述图5所示的实施例的基础上,第一预设界面中还包括预设的逻辑关系符号包括:括号“(”和“)”、与符号“&&”、或符号“||”、否定符号“!”。
用户从预设的逻辑关系符号中进行选择后,信号1与信号2之间的逻辑关系为与关系,信号2与信号3之间的逻辑关系为与关系,信号3与信号4之间的逻辑关系为与关系。
由以上可见,本申请实施例提供的方案中可以通过图像化界面显示逻辑关系符号,使得用户可以通过图像化界面配置目标事件信号之间的逻辑关系,使得用户能够简单便捷地实现对目标事件信号之间逻辑关系的配置。
此外,可以将图13所示的信号1-信号4之间的逻辑关系保存为事件信号组合1,则用户在为其他异步处理组件进行配置时,可以直接调用事件信号组合1生成运行条件。
下面结合图14对调用事件信号组合生成运行条件的方式进行说明。
参见图14,为本申请实施例提供的第三种第一预设界面的示意图。
在前述图5所示的实施例和图13所示的实施例的基础上,图14所示的示意图中调用事件信号组合1与信号5,事件信号组合1与信号5之间的逻辑关系为或关系,表示事件信号组合1记录的逻辑关系成立或接收到信号5的情况下运行异步处理组件中的数据处理单元。
与前述异步处理流程生成方法相对应,本申请实施例还提供了一种异步处理流程生成装置。
参见图15,为本申请实施例提供的一种异步处理流程生成装置的结构示意图,上述装置包括:
组件连接模块1501,用于基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,所述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与所述处理顺序中的下一异步处理组件的数据输入接口相连;
标识选择模块1502,用于确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示所述目标事件信号的标识,其中,所述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,所述前序异步处理组件在所述处理顺序中位于所述目标处理组件之前;
逻辑关系确定模块1503,用于确定用户根据所述第一预设界面显示的内容配置的所述目标事件信号之间的逻辑关系;
运行条件生成模块1504,用于基于所述逻辑关系与所述目标事件信号,生成所述目标处理组件的运行条件,其中,所述运行条件为:在前序异步处理组件输出所述目标事件信号且满足所述逻辑关系的情况下,运行所述目标处理组件中的数据处理单元;
第一组件配置模块1505,用于配置所述目标处理组件通过事件接收接口接收所述目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元;
数据文件生成模块1506,用于根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
由以上可见,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
这样,目标处理组件无需在前序异步处理组件完成数据处理并输出数据之后才进行数据处理,而是在前序异步处理组件进行数据处理过程中的任意阶段接收到事件信号后即可进行数据处理。
并且,前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者的数据处理可以并行执行,是异步关系,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户通过在可视化的第一预设界面中进行简便操作即可实现对异步处理单元的配置,进而基于对异步处理单元的配置生成各种复杂的异步处理流程,相较于通过编写代码或采用脚本生成处理流程,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单和快捷,降低了用户的学习成本,应用范围更加广泛,且节省了代码或脚本的维护开销。
本申请的一个实施例中,上述装置还包括:
动作确定模块,用于确定用户通过第二预设界面选择的目标动作,其中,所述目标动作为:在满足所述运行条件的情况下所述目标处理组件中的数据处理单元需要执行的动作;
所述第一组件配置模块1505,具体用于:
配置所述目标处理组件通过事件接收接口接收目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,以使得被运行的数据处理单元执行目标动作。
由以上可见,本申请实施例提供的方案中,用户可以从目标处理组件内的数据处理单元能够执行的动作中选择目标动作,使得在运行条件成立的情况下数据处理单元能够执行目标动作,从而对目标处理组件的运行进行精确地控制。
另外,目标动作是用户从数据处理单元能够执行的多个动作灵活选取的动作,根据目标动作的不同,目标处理组件内的数据处理单元在满足运行条件的情况下执行目标动作时,可以实现不同的功能,提高了方案的灵活性。
本申请的一个实施例中,所述装置还包括:
输出信号确定模块,用于确定用户通过第三预设界面配置的输出事件信号;
第二组件配置模块,用于配置所述目标处理组件在数据处理单元运行过程中通过事件输出接口输出所述输出事件信号。
由以上可见,本申请实施例提供的方案中不仅可以基于其他异步处理组件输出的事件信号配置目标处理组件的运行条件,还可以配置目标处理组件输出的输出事件信号,所配置的输出事件信号又可以作为其他异步处理组件的运行条件,这样有利于基于各异步处理组件之间的事件信号交互生成完整的异步处理流程。
本申请的一个实施例中,所述逻辑关系确定模块1503,具体用于:
通过所述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号;
确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于所述目标逻辑关系符号确定所述目标事件信号之间的逻辑关系。
由以上可见,本申请实施例提供的方案中可以通过图像化界面显示逻辑关系符号,使得用户可以通过图像化界面配置目标事件信号之间的逻辑关系,使得用户能够简单便捷地实现对目标事件信号之间逻辑关系的配置。
本申请的一个实施例中,所述逻辑关系符号包括以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数。
可见,本申请实施例为用户提供了类型丰富的逻辑关系符号,上述逻辑关系符号用于表示各种不同的逻辑关系,这样有利于使得用户基于各种逻辑关系符合的组合生成满足多样需求的运行条件,提高了 方案的可用性。
本申请的一个实施例中,所述异步处理组件为机器视觉算法平台中的组件,所述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
这样采用本申请实施例提供的方案对机器视觉算法平台中用于对图像数据和/或视频数据进行处理的异步处理组件进行配置之后,可以生成针对图像数据和/或视频数据的异步处理流程,在所生成的异步处理流程中,一个异步处理组件的运行不是由其前序异步处理组件的输出的处理结果触发,而是由前序异步处理组件输出的事件信号触发,也即异步处理组件的运行与其前序异步处理组件的输出的处理结果之间没有耦合关系,从而各异步处理组件可以并行运行,提高了图像数据和/或视频数据的处理效率。
本申请实施例还提供了一种电子设备,如图16所示,包括:
存储器1601,用于存放计算机程序;
处理器1602,用于执行存储器1601上所存放的程序时,实现前述异步处理流程生成方法任一所示的方法步骤。
应用本申请实施例提供的电子设备进行异步处理流程生成时,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者之间的数据处理过程是异步的,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户可以通过可视化的第一预设界面实现对异步处理单元的配置,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单。
并且上述电子设备还可以包括通信总线和/或通信接口,处理器1602、通信接口、存储器1601通过通信总线完成相互间的通信。
上述电子设备提到的通信总线可以是外设部件互连标准(Peripheral Component Interconnect,PCI)总线或扩展工业标准结构(Extended Industry Standard Architecture,EISA)总线等。该通信总线可以分为地址总线、数据总线、控制总线等。为便于表示,图中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。
通信接口用于上述电子设备与其他设备之间的通信。
存储器可以包括随机存取存储器(Random Access Memory,RAM),也可以包括非易失性存储器(Non-Volatile Memory,NVM),例如至少一个磁盘存储器。可选的,存储器还可以是至少一个位于远离前述处理器的存储装置。
上述的处理器可以是通用处理器,包括中央处理器(Central Processing Unit,CPU)、网络处理器(Network Processor,NP)等;还可以是数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。
在本申请提供的又一实施例中,还提供了一种计算机可读存储介质,该计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现上述任一异步处理流程生成方法的步骤。
执行本申请实施例提供的计算机可读存储介质中存储的计算机程序进行异步处理流程生成时,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者之间的数据处理过程是异步的,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户可以通过可视化的第一预设界面实现对异步处理单元的配置,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单。
在本申请提供的又一实施例中,还提供了一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述实施例中任一异步处理流程生成方法。
执行本申请实施例提供的计算机程序进行异步处理流程生成时,用户可以通过本申请实施例提供的方案配置异步处理组件之间的连接关系,并为异步处理组件中的目标处理组件配置目标事件信号与目标事件信号之间的逻辑关系,从而对目标处理组件的运行条件进行配置,使得目标处理组件在获得目标事件信号且目标事件信号满足逻辑关系的情况下,运行目标处理组件中包含的数据处理单元。也就是配置之后目标处理组件的并非在接收到前序异步处理组件输出的数据后开始运行数据处理单元,而是以前序异步处理组件输出的事件信号作为数据处理单元的运行条件。
前序异步处理组件输出事件信号后可以继续进行数据处理,目标处理组件接收到目标事件信号且目标事件信号满足运行条件时可以开始执行自身的数据处理流程,两者之间的数据处理过程是异步的,因此通过本申请实施例提供的方案可以配置异步处理组件实现异步数据处理。另外,用户可以通过可视化的第一预设界面实现对异步处理单元的配置,对于用户而言,本申请实施例提供的异步处理流程生成方案的实现较为简单。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者其他介质(例如固态硬盘Solid State Disk(SSD))等。
需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。 而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。
本说明书中的各个实施例均采用相关的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置、电子设备、计算机可读存储介质和计算机程序产品实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。
以上所述仅为本申请的较佳实施例,并非用于限定本申请的保护范围。凡在本申请的精神和原则之内所作的任何修改、等同替换、改进等,均包含在本申请的保护范围内。

Claims (10)

  1. 一种异步处理流程生成方法,其特征在于,所述方法包括:
    基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,所述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与所述处理顺序中的下一异步处理组件的数据输入接口相连;
    确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示所述目标事件信号的标识,其中,所述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,所述前序异步处理组件在所述处理顺序中位于所述目标处理组件之前;
    确定用户根据所述第一预设界面显示的内容配置的所述目标事件信号之间的逻辑关系;
    基于所述逻辑关系与所述目标事件信号,生成所述目标处理组件的运行条件,其中,所述运行条件为:在前序异步处理组件输出所述目标事件信号且满足所述逻辑关系的情况下,运行所述目标处理组件中的数据处理单元;
    配置所述目标处理组件通过事件接收接口接收所述目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元;
    根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
  2. 根据权利要求1所述的方法,其特征在于,在所述配置所述目标处理组件通过事件接收接口接收所述目标事件信号之前,还包括:
    确定用户通过第二预设界面选择的目标动作,其中,所述目标动作为:在满足所述运行条件的情况下所述目标处理组件中的数据处理单元需要执行的动作;
    所述配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,包括:
    配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,以使得被运行的数据处理单元执行目标动作。
  3. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    确定用户通过第三预设界面配置的输出事件信号;
    配置所述目标处理组件在数据处理单元运行过程中通过事件输出接口输出所述输出事件信号。
  4. 根据权利要求1-3中任一项所述的方法,其特征在于,所述确定用户根据所述第一预设界面所显示的内容配置的所述目标事件之间的逻辑关系,包括:
    通过所述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号;
    确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于所述目标逻辑关系符号确定所述目标事件信号之间的逻辑关系。
  5. 根据权利要求4所述的方法,其特征在于,所述逻辑关系符号包括以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数。
  6. 根据权利要求1-3中任一项所述的方法,其特征在于,所述异步处理组件为机器视觉算法平台中的组件,所述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
  7. 一种异步处理流程生成装置,其特征在于,所述装置包括:
    组件连接模块,用于基于用户配置的异步处理组件的处理顺序,连接各个异步处理组件,其中,所述异步处理组件包含:用于接收数据的数据输入接口、用于对数据进行处理的数据处理单元、用于输出 数据的数据输出接口、用于接收事件信号的事件接收接口、用于输出事件信号的事件输出接口,连接后每一异步处理组件的数据输出接口与所述处理顺序中的下一异步处理组件的数据输入接口相连;
    标识选择模块,用于确定用户为异步处理组件中的目标处理组件选择的目标事件信号,并在第一预设界面中显示所述目标事件信号的标识,其中,所述目标事件信号为:前序异步处理组件通过事件输出接口输出的事件信号,所述前序异步处理组件在所述处理顺序中位于所述目标处理组件之前;
    逻辑关系确定模块,用于确定用户根据所述第一预设界面显示的内容配置的所述目标事件信号之间的逻辑关系;
    运行条件生成模块,用于基于所述逻辑关系与所述目标事件信号,生成所述目标处理组件的运行条件,其中,所述运行条件为:在前序异步处理组件输出所述目标事件信号且满足所述逻辑关系的情况下,运行所述目标处理组件中的数据处理单元;
    第一组件配置模块,用于配置所述目标处理组件通过事件接收接口接收所述目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元;
    数据文件生成模块,用于根据配置结果,生成按照异步处理流程进行数据处理的数据文件。
  8. 根据权利要求7所述的装置,其特征在于,
    所述装置还包括:动作确定模块,用于确定用户通过第二预设界面选择的目标动作,其中,所述目标动作为:在满足所述运行条件的情况下所述目标处理组件中的数据处理单元需要执行的动作;所述第一组件配置模块,具体用于:配置所述目标处理组件通过事件接收接口接收目标事件信号,并配置所述目标处理组件在所述运行条件成立的情况下运行数据处理单元,以使得被运行的数据处理单元执行目标动作;
    所述装置还包括:输出信号确定模块,用于确定用户通过第三预设界面配置的输出事件信号;第二组件配置模块,用于配置所述目标处理组件在数据处理单元运行过程中通过事件输出接口输出所述输出事件信号;
    所述逻辑关系确定模块,具体用于:通过所述第一预设界面显示预设的能够表示逻辑关系的逻辑关系符号;确定用户从所显示的逻辑关系符号中选择的目标逻辑关系符号,基于所述目标逻辑关系符号确定所述目标事件信号之间的逻辑关系;
    所述逻辑关系符号包括以下符号中的至少一种:与符号、或符号、否定符号、括号、用于实现设定功能的函数;
    所述异步处理组件为机器视觉算法平台中的组件,所述异步处理组件中的数据处理单元用于对图像数据和/或视频数据进行处理。
  9. 一种电子设备,其表征在于,包括:
    存储器,用于存放计算机程序;
    处理器,用于执行存储器上所存放的程序时,实现权利要求1-6任一所述的方法。
  10. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现权利要求1-6任一所述的方法步骤。
PCT/CN2023/110914 2022-09-09 2023-08-03 一种异步处理流程生成方法及装置 WO2024051409A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202211105443.8A CN115687224A (zh) 2022-09-09 2022-09-09 一种异步处理流程生成方法及装置
CN202211105443.8 2022-09-09

Publications (1)

Publication Number Publication Date
WO2024051409A1 true WO2024051409A1 (zh) 2024-03-14

Family

ID=85061663

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/110914 WO2024051409A1 (zh) 2022-09-09 2023-08-03 一种异步处理流程生成方法及装置

Country Status (2)

Country Link
CN (1) CN115687224A (zh)
WO (1) WO2024051409A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115687224A (zh) * 2022-09-09 2023-02-03 杭州海康机器人股份有限公司 一种异步处理流程生成方法及装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110113436A1 (en) * 2009-11-12 2011-05-12 Red Hat, Inc. Event Logging Application Programming Interface (API)
CN108922188A (zh) * 2018-07-24 2018-11-30 河北德冠隆电子科技有限公司 雷达跟踪定位的四维实景交通路况感知预警监控管理系统
CN109669720A (zh) * 2018-11-22 2019-04-23 北京字节跳动网络技术有限公司 基于Promise的链式异步请求处理方法、装置及电子设备
CN112099848A (zh) * 2020-09-11 2020-12-18 杭州海康威视数字技术股份有限公司 一种业务处理方法、装置及设备
CN115687224A (zh) * 2022-09-09 2023-02-03 杭州海康机器人股份有限公司 一种异步处理流程生成方法及装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110113436A1 (en) * 2009-11-12 2011-05-12 Red Hat, Inc. Event Logging Application Programming Interface (API)
CN108922188A (zh) * 2018-07-24 2018-11-30 河北德冠隆电子科技有限公司 雷达跟踪定位的四维实景交通路况感知预警监控管理系统
CN109669720A (zh) * 2018-11-22 2019-04-23 北京字节跳动网络技术有限公司 基于Promise的链式异步请求处理方法、装置及电子设备
CN112099848A (zh) * 2020-09-11 2020-12-18 杭州海康威视数字技术股份有限公司 一种业务处理方法、装置及设备
CN115687224A (zh) * 2022-09-09 2023-02-03 杭州海康机器人股份有限公司 一种异步处理流程生成方法及装置

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
ZHENG DONG-WEI, XU WEI-SHENG, CEN FENG: "Research on the Key Technologies of Asynchronous Circuit Design Based on Petri Net", JISUANJI-FANGZHEN = COMPUTER SIMULATION, ZHONGGUO HANGTIAN GONGYE ZONGGONGSI, CN, vol. 26, no. 10, 31 October 2009 (2009-10-31), CN , pages 344 - 347, XP009553103, ISSN: 1006-9348 *

Also Published As

Publication number Publication date
CN115687224A (zh) 2023-02-03

Similar Documents

Publication Publication Date Title
US20200301663A1 (en) Interactive control method and device for voice and video communications
CN105308648B (zh) 用于对用户选定的兴趣区域进行超分辨的系统和方法
WO2024051409A1 (zh) 一种异步处理流程生成方法及装置
US20190051147A1 (en) Remote control method, apparatus, terminal device, and computer readable storage medium
WO2023051185A1 (zh) 图像处理方法、装置、电子设备及存储介质
CN108833781B (zh) 图像预览方法、装置、终端及计算机可读存储介质
CN113190106B (zh) 手势识别方法、装置及电子设备
US20220375460A1 (en) Method and apparatus for generating interaction record, and device and medium
CN112149545B (zh) 样本生成方法、装置、电子设备及存储介质
CN111901695B (zh) 视频内容截取方法、装置和设备及计算机存储介质
CN111611767B (zh) 验证方法和装置
CN113589982A (zh) 一种资源播放方法、装置、电子设备和存储介质
CN112188097A (zh) 拍摄方法、拍摄装置、终端设备及计算机可读存储介质
WO2020057241A1 (zh) 应用程序显示的方法、装置及终端设备
CN105608430A (zh) 人脸聚类方法及装置
WO2022170982A1 (zh) 图像处理方法、图像生成方法、装置、设备和介质
JP2023536365A (ja) ビデオ処理方法及び装置
WO2020030072A1 (zh) 用于分配资源、领取资源、发布资源的方法和设备
WO2017124956A1 (zh) 信息输入方法、装置及终端设备
US10931610B2 (en) Method, device, user terminal and electronic device for sharing online image
WO2024087618A1 (zh) 一种截屏方法、截屏装置、截屏设备及计算机存储介质
CN105426065A (zh) 浏览位置标记方法及装置
CN112087569B (zh) 一种摄像机及摄像机启动方法、装置
WO2020020095A1 (zh) 编辑工具的配置方法和配置参数的生成方法
EP3598738A1 (en) Video synthesis method, apparatus and device, and video playing method, apparatus and device

Legal Events

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

Ref document number: 23862108

Country of ref document: EP

Kind code of ref document: A1