Quantum measurement and control method, system, device and computer program product
By adopting remote process call technology in the quantum measurement and control system, the dedicated drivers of the measurement and control computer are deployed as RPC servers, which solves the problem of impact on the stability of the quantum measurement and control system, and achieves the effect of efficient operation and reducing maintenance costs.
Patent Information
- Application Number
- CN202411471752.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-22
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2044-10-22
AI Technical Summary
The stability of the quantum measurement and control system is affected, which may lead to system collapse. The existing technology needs to update the entire quantum operating system when adding or replacing the measurement and control computer, which increases the cost of maintenance and update.
Remote procedure call (RPC) technology is used to deploy the dedicated drivers of the measurement and control lower computers in the device lower computer, and package the drivers into RPC servers, and use the measurement and control upper computers as RPC clients to form a remote driver library. The quantum operating system only retains the general control method of the driver.
It avoids software conflicts between the quantum operating system and the measurement and control computer, realizes the efficient operation of the quantum measurement and control system, improves the stability of the system, and reduces the cost of maintenance and updates.
Smart Images

Figure CN119003213B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of quantum computer technology, and in particular to quantum measurement and control methods, systems, devices and computer program products. Background Art
[0002] In the current quantum measurement and control system, the measurement and control host computer is connected to the measurement and control slave computer through a network cable and a switch. The quantum operating system is deployed in the measurement and control host computer, and the driver of each measurement and control slave computer is integrated into the quantum operating system in the form of an instrument driver library. Since quantum measurement and control experiments involve frequent data exchange, including continuous writing and reading operations, the quantum operating system uses a coroutine framework to improve execution efficiency. The coroutine framework allows the operating system to release control while waiting for I / O (input / output, write / write) operations to complete, thereby improving the concurrency and responsiveness of the program. However, different measurement and control slave computers provide different program control interfaces, which may cause thread conflicts when the coroutines in the quantum operating system and the coroutines in the measurement and control slave computer interface run at the same time, thereby affecting the stability of the quantum measurement and control system and even causing the quantum measurement and control system to crash.
[0003] The above contents are only used to assist in understanding the technical solution of the present application and do not constitute an admission that the above contents are prior art. Summary of the invention
[0004] The main purpose of this application is to provide a quantum measurement and control method, system, device and computer program product, aiming to solve the technical problem that the stability of the quantum measurement and control system is affected.
[0005] To achieve the above-mentioned purpose, the present application proposes a quantum measurement and control method, which is applied to a measurement and control host computer in a quantum measurement and control system, in which a remote procedure call client is deployed, and the quantum measurement and control system also includes a measurement and control slave computer, in which a remote procedure call server is deployed, and the remote procedure call client and the remote procedure call server establish a communication connection, and the quantum measurement and control method includes:
[0006] Acquire experimental parameter information of a quantum experiment to be performed, and generate an experimental instruction according to the experimental parameter information;
[0007] The experimental instruction is sent to the remote procedure call server through the remote procedure call client, wherein the measurement and control lower computer receives the experimental instruction through the remote procedure call server and sends it to the device driver, the device driver performs the experimental operation according to the experimental instruction to obtain the experimental result, and returns the experimental result to the remote procedure call client through the remote procedure call server;
[0008] The experimental instruction is sent to the remote procedure call server through the remote procedure call client to receive the experimental result, and the experimental data is read based on the experimental result.
[0009] In one embodiment, the step of generating an experimental instruction according to the experimental parameter information includes:
[0010] Generate a configuration dictionary based on the experimental parameter information, wherein the configuration dictionary is used to store the experimental parameter information;
[0011] An experimental instance is constructed based on the configuration dictionary, and an experimental instruction is generated based on the experimental instance, wherein the experimental instance is used to characterize the experimental configuration of the quantum experiment to be performed.
[0012] In one embodiment, the step of constructing an experimental instance based on the configuration dictionary and generating an experimental instruction based on the experimental instance includes:
[0013] Parsing the configuration dictionary to generate a tuple list and a read instruction, wherein the tuple list includes a plurality of tuples, and the tuples represent experimental steps of the quantum experiment to be performed;
[0014] The tuple list is stored as a set attribute value of a preset basic instance, the read instruction is stored as a read attribute value of the basic instance, and the basic instance storing the set attribute value and the read attribute value is used as an experimental instance;
[0015] An operation instruction is constructed based on the setting attribute value, and a read instruction is constructed based on the read attribute value, and the operation instruction and the read instruction are used as the experimental instruction.
[0016] In one embodiment, before the step of sending the experimental instruction to the remote procedure call server through the remote procedure call client, the method further includes:
[0017] Determine, based on the experimental instruction, the name of the device indicated by the experimental instruction;
[0018] Detect whether the device name exists in each lower machine name stored in the preset driver dictionary;
[0019] If the device name exists in each of the slave computer names stored in the driver dictionary, the slave computer corresponding to the device name among the multiple slave computers is used as the measurement and control slave computer.
[0020] In one embodiment, before the step of detecting whether the device name exists in each lower machine name stored in the preset driver dictionary, the method further includes:
[0021] Creating multiple client instances, and establishing communication connections with server instances of remote procedure call servers of the multiple lower computers through the multiple client instances, wherein the server instances connected to the multiple client instances correspond to different lower computers;
[0022] Acquire, through the multiple client instances, the lower computer names and driver instance identifiers of the lower computers to which they are connected based on the server instances to which they are connected;
[0023] A driver dictionary is constructed by using the respective lower-level computer names of the plurality of lower-level computers as keys and the respective driver instance identifiers of the plurality of lower-level computers as values.
[0024] In addition, to achieve the above purpose, the present application also proposes a quantum measurement and control method, which is applied to a measurement and control lower computer in a quantum measurement and control system, in which a remote procedure call server is deployed, and the quantum measurement and control system also includes a measurement and control upper computer, in which a remote procedure call client is deployed, and a communication connection is established between the remote procedure call client and the remote procedure call server, and the quantum measurement and control method includes:
[0025] Receiving, through the remote procedure call server, an experimental instruction sent by the measurement and control host computer through the remote procedure call client, wherein the experimental instruction is generated by the measurement and control host computer based on the acquired experimental parameter information of the quantum experiment to be executed;
[0026] The experimental instruction is sent to the device driver through the remote procedure call server, and the device driver performs the experimental operation according to the experimental instruction to obtain the experimental result, and returns the experimental result to the remote procedure call server;
[0027] The experimental result is returned to the remote procedure call client through the remote procedure call server, wherein the measurement and control host computer receives the experimental result through the remote procedure call client and reads the experimental data based on the experimental result.
[0028] In one embodiment, before the step of receiving, through the remote procedure call server, the experimental instruction sent by the measurement and control host computer through the remote procedure call client, the step further includes:
[0029] Creating a device driver instance, and binding the device driver instance to the attributes of the remote procedure call server;
[0030] The step of sending the experimental instruction to the device driver through the remote procedure call server includes:
[0031] Parsing the experimental instruction by the remote procedure call server to determine the target driver instance corresponding to the experimental instruction;
[0032] The experimental instruction is sent to the attribute of the remote procedure call server through the remote procedure call server, and the experimental instruction is sent to the target driver instance through the attribute of the remote procedure call server.
[0033] In addition, to achieve the above-mentioned purpose, the present application also proposes a quantum measurement and control system, which includes a measurement and control host computer and a measurement and control slave computer, a remote procedure call client is deployed in the measurement and control host computer, and a remote procedure call server is deployed in the measurement and control slave computer, and the remote procedure call client and the remote procedure call server establish a communication connection.
[0034] In one embodiment, the measurement and control host computer further includes an interaction unit, an experiment processing unit and an instruction issuing unit, wherein the experiment processing unit is respectively communicatively connected to the interaction unit and the instruction issuing unit, and the instruction issuing unit is communicatively connected to the remote procedure call client.
[0035] In one embodiment, the measurement and control lower computer includes multiple remote call units, each of which includes a remote procedure call server instance and a driver unit with a communication connection, and the remote procedure call server instance is communicatively connected to the remote procedure call client.
[0036] In addition, to achieve the above-mentioned purpose, the present application also proposes a quantum measurement and control device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, and the computer program is configured to implement the steps of the quantum measurement and control method described above.
[0037] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the steps of the quantum measurement and control method described above.
[0038] In the present application, the measurement and control host computer obtains the experimental parameter information of the quantum experiment to be executed, and generates an experimental instruction according to the experimental parameter information. The measurement and control host computer sends the experimental instruction to the remote procedure call server through the remote procedure call client; the measurement and control lower computer receives the experimental instruction through the remote procedure call server and sends it to the device driver. The measurement and control lower computer performs the experimental operation according to the experimental instruction through the device driver to obtain the experimental result, and the measurement and control lower computer returns the experimental result to the remote procedure call client through the remote procedure call client; the measurement and control host computer sends the experimental instruction to the remote procedure call server through the remote procedure call client to receive the experimental result, and reads the experimental data based on the experimental result.
[0039] In this application, a quantum measurement and control system is driven based on remote procedure calls, the driver library is separated from the quantum operating system of the measurement and control host computer, the dedicated driver of the measurement and control slave computer is deployed in the device slave computer, and the driver is packaged as a remote procedure call (RPC) server. The measurement and control host computer is used as a remote procedure call client, so that the measurement and control host computer only needs to connect to the service of each measurement and control slave computer to form a remote driver library. Only the general control method of the driver is retained in the quantum operating system to realize the read and write operations of all devices, avoiding potential software conflicts between the quantum operating system and the measurement and control slave computer, realizing the efficient operation of the quantum measurement and control system, and improving the stability of the quantum measurement and control system. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0041] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0042] Figure 1 A schematic diagram of a flow chart provided for the first embodiment of the quantum measurement and control method of this application;
[0043] Figure 2 A schematic diagram of the flow chart provided for the second embodiment of the quantum measurement and control method of this application;
[0044] Figure 3 A schematic diagram of the hardware connection of a quantum measurement and control system provided in one embodiment of the present application;
[0045] Figure 4 A drive architecture diagram of a measurement and control host computer provided in an embodiment of the present application;
[0046] Figure 5 A drive architecture diagram of a measurement and control lower computer provided in an embodiment of the present application;
[0047] Figure 6 A schematic diagram of the execution flow of the measurement and control host computer provided in one embodiment of the present application;
[0048] Figure 7 A schematic diagram of the execution process of the measurement and control host computer provided in an embodiment of the present application;
[0049] Figure 8 Schematic diagram of the device structure of the hardware operating environment involved in the quantum measurement and control method in the embodiment of the present application.
[0050] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0051] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.
[0052] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.
[0053] The main solution of the embodiment of the present application is: the measurement and control host computer obtains the experimental parameter information of the quantum experiment to be executed, and generates an experimental instruction according to the experimental parameter information, and the measurement and control host computer sends the experimental instruction to the remote procedure call server through the remote procedure call client; the measurement and control lower computer receives the experimental instruction through the remote procedure call server and sends it to the device driver, the measurement and control lower computer performs the experimental operation according to the experimental instruction through the device driver to obtain the experimental result, and the measurement and control lower computer returns the experimental result to the remote procedure call client through the remote procedure call client; the measurement and control host computer sends the experimental instruction to the remote procedure call server through the remote procedure call client to receive the experimental result, and reads the experimental data based on the experimental result.
[0054] Superconducting quantum computers are mainly composed of three parts: cryogenic system, quantum measurement and control system, and quantum chip. The role of quantum measurement and control system is to achieve high-precision measurement and control of quantum bits, which is an important support for the stable operation of quantum computers. At present, the quantum measurement and control system needs to be composed of a quantum operating system and a series of microwave equipment (that is, measurement and control lower computer). The operating system is deployed in the measurement and control upper computer, and the measurement and control upper computer and the measurement and control lower computer are connected through a gigabit network cable and a switch. Through the program control interface provided by the measurement and control lower computer, the operating system can control the microwave equipment to emit any waveform of specified frequency and length and enter the quantum chip along the RF cable. Since the quantum measurement and control system has a waveform control accuracy of nanoseconds, and the control of each bit involves multiple channel waveform outputs, it is necessary to use the operating system to complete this I / O (input / output, write / write) intensive program control. In order to facilitate and quickly conduct quantum manipulation experiments, dedicated drivers are usually developed for similar microwave equipment, and all device drivers are integrated into the operating system to form a general instrument control system.
[0055] Since quantum measurement and control experiments involve frequent data exchange, quantum operating systems use a coroutine framework to improve execution efficiency. Coroutines allow the operating system to release control while waiting for I / O operations to complete, thereby improving the concurrency and responsiveness of the program. However, different measurement and control slave computers provide different program control interfaces, which may cause thread conflicts when the coroutines in the quantum operating system and the coroutines in the measurement and control slave computer interface run at the same time. Thread conflicts may cause resource competition, deadlock or other synchronization problems, all of which may affect the stability of the quantum measurement and control system and even cause the quantum measurement and control system to crash.
[0056] In addition, since the dedicated driver developed for each measurement and control slave computer is included in the quantum operating system in the form of an instrument driver library, when adding or replacing a measurement and control slave computer, the driver library or even the entire quantum operating system needs to be updated. As the number of measurement and control slave computers increases, the amount of driver library code continues to increase, increasing the maintenance and update costs of the driver library, thereby increasing the cost of maintaining and updating the quantum measurement and control system.
[0057] The embodiment of the present application provides a solution, which drives the quantum measurement and control system based on remote procedure calls, separates the driver library from the quantum operating system of the measurement and control host computer, deploys the dedicated driver of the measurement and control slave computer in the device slave computer, and packages the driver as a remote procedure call server. The measurement and control host computer is used as a remote procedure call client, so that the measurement and control host computer only needs to connect to the service of each measurement and control slave computer to form a remote driver library. Only the general control method of the driver is retained in the quantum operating system to realize the read and write operations of all devices, thereby avoiding potential software conflicts between the quantum operating system and the measurement and control slave computer, realizing the efficient operation of the quantum measurement and control system, and improving the stability of the quantum measurement and control system.
[0058] In addition, the embodiment of the present application separates the driver library from the quantum operating system of the measurement and control upper computer, making the operating system in the quantum measurement and control system more lightweight. When adding or adjusting the measurement and control lower computer, there is no need to maintain the quantum operating system, which increases the convenience of maintaining and updating the measurement and control lower computer and reduces the cost of maintaining and updating the measurement and control lower computer, thereby achieving convenience in maintaining the quantum measurement and control system and reducing the cost of maintaining and updating the quantum measurement and control system.
[0059] It should be noted that the execution subject of this embodiment can be a computing service device with data processing, network communication and program running functions, such as a tablet computer, a personal computer, a mobile phone, etc., or an electronic device that can realize the above functions (execution subject), etc.
[0060] Based on this, an embodiment of the present application provides a quantum measurement and control method, which is applied to a measurement and control host computer in a quantum measurement and control system, in which a remote procedure call client is deployed, and the quantum measurement and control system also includes a measurement and control slave computer, in which a remote procedure call server is deployed, and the remote procedure call client and the remote procedure call server establish a communication connection. In this embodiment, reference is made to Figure 1 , Figure 1 This is a flow chart of the first embodiment of the quantum measurement and control method of the present application.
[0061] In this embodiment, the quantum measurement and control method includes steps S10 to S30:
[0062] Step S10, obtaining experimental parameter information of the quantum experiment to be performed, and generating experimental instructions according to the experimental parameter information.
[0063] It should be noted that quantum experiments refer to experiments that precisely operate and measure quantum bits in quantum computers. Quantum experiments are the basis of quantum computing and quantum information processing. The purpose of the experiment is to explore the principles of quantum mechanics, verify quantum theory, and develop quantum technology and applications. In the following, unexecuted quantum experiments are referred to as pending quantum experiments to distinguish them. Experimental parameter information includes parameters and parameter values, where parameters include the configuration required for quantum experiments, which may include experimental conditions, equipment settings, etc., and parameter values are specific values of the configuration required for quantum experiments. Experimental instructions are specific operation instructions formed based on experimental parameter information, which are used to guide the measurement and control lower computer to perform experiments, and may include specific steps for the measurement and control lower computer operations, such as turning on equipment, setting parameters, starting measurements, collecting data, etc.
[0064] The measurement and control host computer can receive the experimental parameter information input by the experimenter through the human-computer interaction interface. The process of the measurement and control host computer generating experimental instructions based on the experimental parameter information is not limited here. The measurement and control host computer can collect the parameters required for the experiment through user input or preset programs, and then the measurement and control host computer generates a series of experimental instructions based on these parameters using built-in algorithms or rules. For details, please refer to the conventional instruction generation process.
[0065] In a feasible implementation manner, the process of the measurement and control host computer generating the experimental instructions according to the experimental parameter information may include steps S101-S102.
[0066] Step S101, packaging the experimental parameter information to generate a configuration dictionary.
[0067] It should be noted that the configuration dictionary is a data structure, usually a set of key-value pairs, used to store and manage experimental parameter information.
[0068] The measurement and control host computer collects all the experimental parameter information required for the experiment. These parameters define the operating conditions of the experiment, and adds each parameter and corresponding value in the experimental parameter information as a key-value pair to the configuration dictionary. The configuration dictionary can provide a structured and centralized way to manage and verify the experimental parameter information, which is convenient for the use and adjustment of subsequent steps.
[0069] Step S102, constructing an experimental instance based on the configuration dictionary, and generating an experimental instruction based on the experimental instance, wherein the experimental instance is used to characterize the experimental configuration of the quantum experiment.
[0070] It should be noted that an experimental instance is an object or data structure created based on the configuration dictionary, which represents the configuration and execution plan of the quantum experiment to be performed, and may specifically include information such as the experimental process, equipment configuration, and expected results.
[0071] The measurement and control host computer reads the parameters in the configuration dictionary, then builds the experimental instance according to the parameter values, converts or generates specific experimental instructions according to the content of the experimental instance, and sends the experimental instructions to the measurement and control slave computer. It can be understood that the construction of experimental instances allows experiments to be repeated under the same conditions, improving the reliability of the results, and the construction of experimental instances allows the experimental configuration to be quickly adjusted and updated, improving the adaptability and flexibility of the experiment.
[0072] The process of the measurement and control host computer constructing an experimental instance based on the configuration dictionary and generating an experimental instruction based on the experimental instance is not limited here, and can refer to the conventional instance generation process and instruction generation process. Exemplarily, in a feasible implementation, the process of the measurement and control host computer constructing an experimental instance based on the configuration dictionary and generating an experimental instruction based on the experimental instance can include steps S1021~S1023.
[0073] Step S1021, parsing the configuration dictionary to generate a tuple list and a read instruction, wherein the tuple list includes a plurality of tuples, and the tuples represent the experimental steps of the quantum experiment to be performed.
[0074] It should be noted that the tuple list is a collection of a series of tuples, each tuple represents a specific operation step, and the tuple may specifically contain information such as the operation type, target device, and parameters. The operation instruction is an instruction used to indicate the experimental operation of the quantum experiment to be performed. The read instruction is an instruction used to instruct the measurement and control lower computer to return the experimental results after the experiment is completed.
[0075] In this implementation, the process of parsing the configuration dictionary to generate a tuple list and a read instruction is not limited here, and a conventional tuple generation process and an instruction generation process can be used. By converting the configuration dictionary into a tuple list and a read instruction, the experimental steps of the quantum experiment to be executed are concretized, which is convenient for the measurement and control lower computer to understand and execute.
[0076] Step S1022, storing the tuple list as a set attribute value of a preset basic instance, storing the read instruction as a read attribute value of the basic instance, and using the basic instance storing the set attribute value and the read attribute value as an experimental instance.
[0077] It should be noted that the basic instance refers to the initialized experimental instance. The basic instance provides a structure for storing and processing experimental parameter information, including default settings or reserved space for subsequent filling of specific experimental parameter information. The basic instance provides a clear template for experimental configuration, simplifying the data processing and instruction generation process in subsequent steps. The preset basic instance can be constructed by the measurement and control host computer, or it can be obtained by obtaining the stored initialization instance, which is not limited here.
[0078] In addition, it should be noted that setting the attribute value means setting the value of the attribute, which is the attribute in the basic instance used to store the operation instruction. Reading the attribute value means reading the value of the attribute, which is the attribute in the basic instance used to store the read instruction.
[0079] The measurement and control host computer assigns the generated tuple list to the setting attribute of the basic instance, and assigns the read instruction to the read attribute of the basic instance, so that the basic instance contains complete experimental operation steps and data reading requirements. The assigned basic instance is called the experimental instance. By storing the tuple list and read instruction in the basic instance, the foundation is laid for generating complete experimental instructions, ensuring the integrity and accuracy of the experimental instructions.
[0080] Step S1023, constructing an operation instruction based on the setting property value, and constructing a read instruction based on the read property value, and using the operation instruction and the read instruction as the experimental instruction.
[0081] The measurement and control host computer traverses the tuple list in the basic instance, converts each tuple into a specific operation instruction, generates an instruction for reading the experimental data (i.e., a read instruction) according to the read attribute value of the basic instance, and integrates all the operation instructions and read instructions to form a complete experimental instruction.
[0082] In this implementation, the measurement and control host computer constructs experimental examples and generates experimental instructions based on the experimental examples, so that the quantum measurement and control process can ensure the accurate generation and communication of experimental instructions, thereby improving the automation level and execution efficiency of quantum experiments. At the same time, the experimental examples also improve the repeatability and reliability of the experiment, reduce the possibility of human errors, and ensure the consistency and accuracy of the quantum experiment settings.
[0083] Step S20, sending the experimental instructions to the remote procedure call server through the remote procedure call client, wherein the measurement and control lower computer receives the experimental instructions through the remote procedure call server and sends them to the device driver, and the device driver performs the experimental operation according to the experimental instructions to obtain the experimental results, and returns the experimental results to the remote procedure call client through the remote procedure call server.
[0084] It should be noted that the quantum measurement and control system includes a measurement and control host computer and a measurement and control slave computer. The measurement and control host computer is responsible for handling complex tasks, such as experimental design, data analysis and system management. The remote procedure call client is deployed in the measurement and control host computer, and the remote procedure call client is responsible for initiating remote procedure calls. The measurement and control slave computer is a computer or device connected to the actual quantum device in the quantum measurement and control system, responsible for receiving and executing instructions from the measurement and control host computer. The remote procedure call server and device driver are deployed in the measurement and control slave computer. The remote procedure call server is used to receive remote procedure call requests from the host computer and send the call request to the device driver to execute the quantum experiment to be executed. The device driver is software that directly interacts with the quantum device hardware and is responsible for executing specific hardware operations.
[0085] In this embodiment, the measurement and control upper computer sends the experimental instructions to the remote procedure call server of the measurement and control lower computer through the remote procedure call client. The remote procedure call server of the measurement and control lower computer receives the instructions and forwards them to the corresponding device driver. The device driver executes the quantum experiment to be executed according to the instructions and collects the experimental results. The experimental results are the measurement data or observation results obtained after the quantum experiment to be executed is completed.
[0086] It can be understood that, through the collaboration of the remote procedure call client and the server, it is possible to separate the driver library from the quantum operating system of the measurement and control host computer, deploy the dedicated driver of the measurement and control slave computer in the device slave computer, and package the driver as a remote procedure call server. The measurement and control host computer is used as a remote procedure call client, so that the measurement and control host computer only needs to connect to the service of each measurement and control slave computer to form a remote driver library. Only the general control method of the driver is retained in the quantum operating system to realize the read and write operations of all devices, avoiding potential software conflicts between the quantum operating system and the measurement and control slave computer, realizing the efficient operation of the quantum measurement and control system, and improving the stability of the quantum measurement and control system.
[0087] Step S30: sending the experimental instruction to the remote procedure call server through the remote procedure call client to receive the experimental result, and reading the experimental data based on the experimental result.
[0088] It should be noted that the experimental data is the experimental data of the quantum experiment to be performed extracted from the experimental results. The experimental data can be the final data of the quantum experiment to be performed, or it can be the process data during the quantum experiment to be performed, and there is no limitation here.
[0089] After the device driver of the measurement and control lower computer completes the experiment and obtains the results, it sends these results back to the remote procedure call server, which sends the experimental results back to the remote procedure call client of the measurement and control upper computer through the remote procedure call connection. The remote procedure call client of the measurement and control upper computer receives the experimental results, and the measurement and control upper computer reads the experimental data based on the experimental results, so as to process and analyze the quantum experiment based on the experimental data.
[0090] In this embodiment, the quantum measurement and control system is driven based on remote procedure calls, the driver library is separated from the quantum operating system of the measurement and control host computer, the dedicated driver of the measurement and control slave computer is deployed in the device slave computer, and the driver is packaged as a remote procedure call server. The measurement and control host computer is used as a remote procedure call client, so that the measurement and control host computer only needs to connect to the service of each measurement and control slave computer to form a remote driver library. Only the general control method of the driver is retained in the quantum operating system to realize the read and write operations of all devices, avoiding potential software conflicts between the quantum operating system and the measurement and control slave computer, realizing the efficient operation of the quantum measurement and control system, and improving the stability of the quantum measurement and control system.
[0091] In addition, the driver library is separated from the quantum operating system of the measurement and control upper computer, making the operating system in the quantum measurement and control system more lightweight. When adding or adjusting the measurement and control lower computers, there is no need to maintain the quantum operating system, which increases the convenience of maintaining and updating the measurement and control lower computers and reduces the cost of maintaining and updating the measurement and control lower computers, thereby achieving convenience in maintaining the quantum measurement and control system and reducing the cost of maintaining and updating the quantum measurement and control system.
[0092] Based on the first embodiment of the present application, in the second embodiment of the present application, the same or similar contents as those in the above-mentioned embodiment 1 can be referred to the above introduction, and will not be repeated later. On this basis, before the step S20: sending the experimental instruction to the remote procedure call server through the remote procedure call client, the quantum measurement and control method also includes steps S01~S03:
[0093] Step S01, determining the device name indicated by the experimental instruction based on the experimental instruction.
[0094] In actual application, any one of the multiple client instances may be connected to one of the multiple lower computers, and any one of the multiple client instances may not be connected to one of the multiple lower computers. In order to ensure that the experimental instructions can be correctly sent to the corresponding measurement and control lower computer for execution, in this embodiment, the measurement and control upper computer performs device connection detection based on the driver dictionary before issuing instructions.
[0095] The measurement and control host computer analyzes the experimental instructions, extracts the information of the target device, and determines the device name of the specific device that needs to be controlled.
[0096] Step S02, detecting whether the device name exists in each lower machine name stored in a preset driver dictionary.
[0097] The measurement and control host computer accesses the preset driver dictionary to check whether it contains the device name. If the device name exists in the dictionary, continue with the subsequent steps; if not, it is necessary to remind the user that the device name is wrong or perform other error processing. It should be noted that the preset driver dictionary can be constructed by the measurement and control host computer, or it can be a stored driver dictionary, which is not limited here.
[0098] It can be appreciated that by verifying that the device indicated by the experimental instruction is connected and ready to receive the instruction, the robustness and reliability of the system can be enhanced.
[0099] Step S03: If the device name exists in each of the slave computer names stored in the driver dictionary, a slave computer corresponding to the device name among the multiple slave computers is used as a measurement and control slave computer.
[0100] If the device name exists in the driver dictionary, it indicates that the slave computer corresponding to the device name has established a remote procedure call connection with the measurement and control host computer, and the slave computer corresponding to the device name is configured as the target recipient of the experimental instruction, that is, the measurement and control slave computer.
[0101] It can be understood that in a feasible implementation manner, since the measurement and control host computer parses the configuration dictionary to generate a tuple list and a read instruction, the tuple list is stored as the setting attribute value of the basic instance and the read instruction is stored as the read attribute value of the basic instance to obtain an experimental instance, an operation instruction is generated based on the tuple in the setting attribute value, and a read instruction is generated based on the read attribute value, and the operation instruction and the read instruction are used as the experimental instruction, that is, each tuple corresponds to an experimental instruction, and the lower computers indicated by the experimental instructions corresponding to each tuple may be the same or different. In this embodiment, in order to ensure that the experimental instructions can be correctly sent to the corresponding measurement and control lower computer for execution, before issuing the experimental instructions, it can be detected whether the device name indicated by the experimental instructions is the same as the historical name indicated by the historical instructions, wherein the historical instructions refer to the experimental instructions that have been sent to the lower computer, and the historical name is the device name indicated by the historical instructions; if the device name is consistent with the historical name, the lower computer corresponding to the historical name among the multiple lower computers is used as the measurement and control lower computer; if the device name is inconsistent with the historical name, a step is performed to detect whether the device name exists in the names of each lower computer stored in the driver dictionary; if the device name exists in the names of each lower computer stored in the driver dictionary, the lower computer corresponding to the device name among the multiple lower computers is used as the measurement and control lower computer.
[0102] It can be understood that this embodiment can ensure that the experimental instructions can be correctly identified, verified and sent to the measurement and control lower computer, thereby improving the accuracy of experimental execution and the stability of the system and reducing potential risks caused by equipment errors or instruction errors.
[0103] In a feasible implementation manner, before the step S02: detecting whether the device name exists in each lower machine name stored in the preset driver dictionary, the step S04-S06 is also included:
[0104] Step S04, creating multiple client instances, and establishing communication connections with server instances of remote procedure call servers of the multiple lower computers through the multiple client instances, wherein the server instances connected to the multiple client instances respectively correspond to different lower computers.
[0105] It should be noted that the client instance refers to an independent running instance of the remote procedure call client created on the measurement and control host computer for each slave computer.
[0106] In this implementation, the quantum measurement and control system includes multiple slave computers for executing and driving the quantum experiment to be executed, hereinafter referred to as multiple slave computers for distinction. The measurement and control upper computer creates multiple independent client instances, each client instance is used to connect to a remote procedure call server in a slave computer, and after the connection is established, the client instance communicates with the server instance in the connected measurement and control lower computer.
[0107] It is understandable that in actual application, any one of the multiple client instances may be connected to the server instance of one of the multiple slave machines, and any one of the multiple client instances may not be connected to the server instance of one of the multiple slave machines.
[0108] In this implementation, the measurement and control host computer can call multiple slave computers in parallel by creating an independent client instance for each slave computer, thereby improving the scalability and communication efficiency of the quantum measurement and control system.
[0109] Step S05: acquiring the lower computer name and driver instance identifier of the lower computer to which the multiple client instances are connected based on the server instances to which the multiple client instances are connected.
[0110] It should be noted that the lower computer name is the name or ID (Identity document) used to uniquely identify each lower computer. The driver instance identifier is an identifier used to uniquely identify the device driver instance on a specific lower computer. The device driver instance refers to a specific running instance of the device driver, which is associated with the quantum device and is responsible for realizing the control of the quantum device and the data exchange of the measurement and control lower computer. The measurement and control lower computer creates the device driver instance and binds the device driver instance to the attributes of the remote procedure call server.
[0111] Each client instance requests the lower computer name and driver instance ID through the established remote procedure call connection, and the server in the measurement and control lower computer responds to the request and provides the lower computer name and driver instance ID. The client instance in the measurement and control upper computer receives and stores this information for subsequent use.
[0112] By obtaining the name of the lower computer and the driver instance identifier, the upper computer can accurately identify and manage each lower computer, providing the necessary information for subsequent instruction issuance and result collection.
[0113] Step S06, constructing a driver dictionary using the respective slave computer names of the plurality of slave computers as keys and the respective driver instance identifiers of the plurality of slave computers as values.
[0114] It should be noted that the driver dictionary is a data structure used to map the lower computer name to the corresponding driver instance identifier, so that the subsequent measurement and control upper computer can quickly find and reference the driver instance.
[0115] The measurement and control host computer uses the slave computer name obtained from the client instance as the key and the driver instance identifier as the value to build a driver dictionary, which allows the host computer to quickly access the corresponding driver instance identifier through the slave computer name. It is understandable that the driver dictionary can be stored in memory or saved in a database for use by other parts of the system.
[0116] In this implementation, an efficient search mechanism is provided by constructing a driver dictionary, so that the host computer can quickly locate the driver instance of a specific slave computer, simplifying the remote procedure call process and improving the system's response speed and operational flexibility.
[0117] Based on the first and / or second embodiments of the present application, in the third embodiment of the present application, the same or similar contents as those in the above-mentioned embodiments 1 and / or 2 can be referred to the above description, and will not be described in detail later. On this basis, the quantum measurement and control method is applied to the measurement and control lower computer in the quantum measurement and control system, and the remote procedure call server is deployed in the measurement and control lower computer. The quantum measurement and control system also includes a measurement and control upper computer, and a remote procedure call client is deployed in the measurement and control upper computer. The remote procedure call client and the remote procedure call server establish a communication connection. Please refer to Figure 2 , the quantum measurement and control method comprises steps A10 to A30:
[0118] Step A10, receiving, through the remote procedure call server, the experimental instruction sent by the measurement and control host computer through the remote procedure call client, wherein the experimental instruction is generated by the measurement and control host computer based on the acquired experimental parameter information of the quantum experiment to be executed.
[0119] The measurement and control upper computer generates experimental instructions according to the experimental parameter information of the quantum experiment to be executed, and sends the experimental instructions to the remote procedure call server of the lower computer through the remote procedure call client. The measurement and control lower computer receives the experimental instructions through the remote procedure call server.
[0120] Step A20, sending the experimental instruction to the device driver through the remote procedure call server, performing the experimental operation according to the experimental instruction by the device driver to obtain the experimental result, and returning the experimental result to the remote procedure call server.
[0121] The measurement and control lower computer forwards the received experimental instructions to the corresponding device driver through the remote procedure call server. The device driver parses the experimental instructions and executes the operations of the quantum experiment to be executed according to the instructions, such as manipulating quantum bits. The device driver collects the results of the experimental operation and returns them to the remote procedure call server.
[0122] Step A30, returning the experimental result to the remote procedure call client through the remote procedure call server, wherein the measurement and control host computer receives the experimental result through the remote procedure call client and reads the experimental data based on the experimental result.
[0123] The measurement and control lower computer returns the experimental result to the remote procedure call client through the remote procedure call server. The measurement and control upper computer receives the experimental result through the remote procedure call client and reads the experimental data based on the experimental result.
[0124] In this embodiment, the quantum measurement and control system is driven based on remote procedure calls, the driver library is separated from the quantum operating system of the measurement and control host computer, the dedicated driver of the measurement and control slave computer is deployed in the device slave computer, and the driver is packaged as a remote procedure call server. The measurement and control host computer is used as a remote procedure call client, so that the measurement and control host computer only needs to connect to the service of each measurement and control slave computer to form a remote driver library. Only the general control method of the driver is retained in the quantum operating system to realize the read and write operations of all devices, avoiding potential software conflicts between the quantum operating system and the measurement and control slave computer, realizing the efficient operation of the quantum measurement and control system, and improving the stability of the quantum measurement and control system.
[0125] In addition, this embodiment separates the driver library from the quantum operating system of the measurement and control upper computer, making the operating system in the quantum measurement and control system more lightweight. When adding or adjusting the measurement and control lower computer, there is no need to maintain the quantum operating system, which increases the convenience of maintaining and updating the measurement and control lower computer and reduces the cost of maintaining and updating the measurement and control lower computer, thereby achieving convenience in maintaining the quantum measurement and control system and reducing the cost of maintaining and updating the quantum measurement and control system.
[0126] In a feasible implementation manner, before the step A10: receiving the experimental instruction sent by the measurement and control host computer through the remote procedure call client through the remote procedure call server, the step A01 is also included:
[0127] Step A01: Create a device driver instance and bind the device driver instance to the attributes of the remote procedure call server.
[0128] It should be noted that a device driver instance refers to a specific running instance of a device driver, which is associated with a quantum device and is responsible for realizing the control of the quantum device and measuring and controlling data exchange with the lower computer.
[0129] In this implementation, an instance of a device driver is initialized and created on the measurement and control lower computer, and the newly created device driver instance is bound to the properties of the remote procedure call server, making it a part of the server and accessible through the remote procedure call. By creating a device driver instance, it can be ensured that each quantum device has a corresponding driver instance available for use by the remote procedure call server, which improves the flexibility and scalability of the system.
[0130] In this implementation, the step A10: sending the experimental instruction to the device driver through the remote procedure call server includes steps A101-A102.
[0131] Step A101: parsing the experimental instruction through the remote procedure call server to determine the target driver instance corresponding to the experimental instruction.
[0132] The remote procedure call server of the measurement and control lower computer receives the experimental instructions from the upper computer, and the server parses the experimental instructions to identify the target device information contained in the instructions and the operations to be performed.
[0133] Step A102: Send the experimental instruction to the attribute of the remote procedure call server through the remote procedure call server, and send the experimental instruction to the target driver instance through the attribute of the remote procedure call server.
[0134] The remote procedure call server of the measurement and control lower computer sends the experimental instructions to the correct device driver instance bound to the server attributes based on the analysis results. The device driver instance receives and executes the experimental instructions and controls the quantum device to perform corresponding operations.
[0135] In this implementation, precise instruction parsing and issuance are used to ensure that the quantum device operates according to the predetermined experimental parameter information. In addition, the communication mechanism between the remote procedure call server and the client ensures the efficiency and real-time nature of instruction transmission, enabling the quantum measurement and control system to achieve precise control and measurement of the quantum state, ensuring the precise execution and efficient management of quantum experiments.
[0136] The present application also provides a quantum measurement and control system, wherein the quantum measurement and control device includes the quantum measurement and control system, which includes a measurement and control host computer and a measurement and control slave computer. A remote procedure call client is deployed in the measurement and control host computer, and a remote procedure call server is deployed in the measurement and control slave computer. The remote procedure call client and the remote procedure call server establish a communication connection.
[0137] The measurement and control host computer, network switch and various measurement and control slave computers are connected through network cables. The quantum operating system and remote procedure call client are deployed in the measurement and control host computer, and the device driver and remote procedure call server are deployed in the slave computer of the measurement and control slave computer. All programs in the quantum measurement and control system are written and implemented in Python. The network connection between the measurement and control host computer and the measurement and control slave computer is realized by establishing a connection between the remote procedure call client and the server. The dedicated driver contains the interface functions for reading and writing operations on the device. The remote procedure call server packages the dedicated driver and exposes it to the client. The operating system can call these interface functions through the remote procedure call client, thereby realizing the driving of the measurement and control host computer to the measurement and control slave computer, so that the quantum measurement and control system forms a closed loop. It should be noted that the quantum measurement and control system can include multiple measurement and control slave computers, so the device driver deployed in the device slave computer needs to be developed into a universal driver so that the operating system can realize convenient control.
[0138] The measurement and control host computer can be connected to multiple measurement and control slave computers through a network switch. The functions of each measurement and control slave computer can be the same or different, and there is no limitation here. Figure 3 , Figure 3 A hardware connection diagram of a quantum measurement and control system is provided. Specifically, in this embodiment, the quantum measurement and control system includes a measurement and control host computer and multiple measurement and control slave computers. The measurement and control host computer is connected to each measurement and control slave computer through a network switch (layer). Figure 3 Three measurement and control lower computers are shown in the figure.
[0139] In a feasible implementation, the measurement and control host computer further includes an interaction unit, an experiment processing unit and an instruction issuing unit, wherein the experiment processing unit is respectively communicatively connected to the interaction unit and the instruction issuing unit, and the instruction issuing unit is communicatively connected to the remote procedure call client.
[0140] The measurement and control host computer includes an interactive unit, an experiment processing unit, an instruction issuing unit, and a remote procedure call client. The interactive unit is used to interact with the experimenter, which can be achieved through Jupyter Notebook (an open source application that allows users to create and share documents containing real-time code, equations, visualizations, and explanatory text) or the web (World Wide Web). Web, World Wide Web) terminal, client and other platforms, whose function is to package the experiment category and experiment parameter information as a whole into a configuration file and pass it to the experiment processing unit for subsequent processing, and present the experiment results returned by the experiment processing unit to the experimenter; the experiment processing unit is the central brain of the measurement and control system, and its function is to build the experiment writing and reading process according to the configuration file, and complete the execution of the experiment process, map the experiment parameter information into the measurement and control lower computer attributes and pass the required instructions to the instruction issuing unit, receive the read experimental data results, and return them to the interactive unit for visualization processing; the instruction issuing unit batch processes the instruction set from the experiment processing unit, calls the drive's writing and reading interface functions through the remote procedure call client, writes the instructions into the interface function in the form of parameters and calls them, and completes the driving of the measurement and control lower computer; the remote procedure call client serves as the communication medium between the measurement and control upper computer and the measurement and control lower computer, and plays the role of message transmission. In addition, the remote procedure call client of the upper computer can instantiate multiple RPC clients and establish one-to-one connections with multiple measurement and control lower computers to generate an instrument pool, which is convenient for the operating system to control different devices.
[0141] In a specific implementation, the architecture of the interaction unit, the experiment processing unit, the instruction issuing unit and the remote procedure call client in the measurement and control host computer can have many situations, which can be set according to the actual situation and are not limited here. For example, in one feasible implementation, the measurement and control host computer can directly integrate all core components, including the interaction unit, the experiment processing unit, the instruction issuing unit and the remote procedure call client; in another feasible implementation, please refer to Figure 4 The drive architecture diagram of the measurement and control host computer shown in the figure includes a quantum operating system and a remote procedure call client (i.e. Figure 4 The quantum operating system consists of two components: the RPC Client (shown in Figure 1), the interaction unit, the experiment processing unit, and the instruction issuing unit.
[0142] In a feasible implementation, the measurement and control lower computer includes multiple remote call units, each of which includes a remote procedure call server instance and a driver unit with a communication connection, and the remote procedure call server instance is communicatively connected to the remote procedure call client.
[0143] Please refer to Figure 5The drive architecture diagram of the measurement and control lower computer shown in the figure, the measurement and control lower computer proposed in this embodiment includes multiple remote call units, each of which includes a drive unit and a remote procedure call server (that is, Figure 5 The RPC Server shown in the figure), wherein the driver unit uses the python interface provided by the measurement and control lower computer to develop a special driver class Device (a custom class name, which can be a special device class in this embodiment) that inherits the general driver class GeneralDevice (a custom class name, which can be a general device class in this embodiment), classifies the python interface according to read and write operations, and rewrites it into a member function of the Device class, which is used to control the measurement and control lower computer; the remote procedure call server uses the instantiation of the Device class as an RPC service, which is used to provide the member functions of the Device class to the measurement and control upper computer, which also plays a role in message transmission.
[0144] For example, to help understand the implementation process of the quantum measurement and control method obtained by combining this embodiment with the above-mentioned embodiment 1, please refer to Figure 6, the execution process of the measurement and control upper computer in the quantum measurement and control system proposed in this embodiment can be: first, before the experiment starts, it is necessary to connect the device first, establish RPC connections with the measurement and control lower computers one by one according to the IP address, and generate a device_pool dictionary (that is, a driver dictionary). The dictionary uses the device name and the device driver instance as the key-value pair, where the device name is obtained through the model attribute of the driver instance and has been uniformly named during development (that is, multiple client instances are created, and communication connections are established between the multiple client instances and the server instances of the remote procedure call server of the multiple lower computers, where the server instances connected to the multiple client instances are different from the lower computers; The multiple client instances obtain the lower machine names and driver instance identifiers of the lower machines connected to them based on the server instances connected to them; the driver dictionary is constructed with the lower machine names of the multiple lower machines as keys and the driver instance identifiers of the multiple lower machines as values; the experimenter edits the experiment-related parameters through the front-end interaction unit (that is, obtains the experimental parameter information of the quantum experiment to be executed), and after running the experiment, the interaction unit packages the parameters into a configuration dictionary named exp_setting (that is, the experimental parameter information) (that is, the configuration dictionary), which contains the equipment list that needs to be controlled by the experiment, the channel list of the required equipment, the parameter list that needs to be set for each channel, and other information. The dictionary is passed to the experiment processing unit for interpretation. The experiment processing unit constructs an experiment instance according to the configuration file, reorganizes all the parameters to be set into a tuple list of ("device", "channel number", "attribute", "value") as the setList attribute value of the experiment instance (that is, the set attribute value), and uses the read instruction as the getRes attribute value (that is, the read attribute value), and passes setList and getRes to the instruction issuing unit (that is, parsing the configuration dictionary to generate a tuple list and a read instruction) in sequence through the member function run (a name of a member function, used to indicate that an object starts to perform its main function or task); the tuple list is stored as the set attribute value of the preset basic instance, and the read instruction is stored as the read attribute of the basic instance Value, the basic instance storing the setting property value and the reading property value is used as the experimental instance; the operation instruction is constructed based on the setting property value, and the reading instruction is constructed based on the reading property value, and the operation instruction and the reading instruction are used as the experimental instruction). It should be noted that since the measurement and control of the quantum experiment consists of several write operations and one read operation, large-scale write and read operations require asynchronous programming. This embodiment uses the built-in asynchronous programming library asyncio of Python (Python's asynchronous I / O library, used to write single-threaded concurrent code), and implements asynchronous I / O operations through async / await (a keyword in Python for defining and calling asynchronous functions) syntax;The instruction issuing unit executes the contents in setList one by one. Specifically, for each tuple in setList, it first checks whether the "device" in it exists in the key of device_pool. If not, it means that there is no device to be controlled by the current instruction in the connected measurement and control lower computer. The experiment needs to be terminated and an exception of unknown device is thrown. If it exists, the value corresponding to the key is obtained, that is, the driver instance of the device to be controlled, and the set function of the driver is called. The tuple "channel number", "attribute" and "value" are used as parameters to implement the instruction issuing to the measurement and control lower computer (that is, based on the experimental instruction, the device to be controlled is determined). The device name indicated by the experimental instruction; detect whether the device name exists in the names of the various lower computers stored in the preset driver dictionary; if the device name exists in the names of the various lower computers stored in the driver dictionary, the lower computer corresponding to the device name among the multiple lower computers is used as the measurement and control lower computer). When all the instructions to be executed in setList are issued, the getRes read instruction can be issued. The execution logic is the same as setList. The difference is that after execution, there will be a return value read by the measurement and control lower computer, which will be passed to the experimental processing unit. The experimental processing unit will pre-process the data and hand it over to the interactive unit for visual display. ;
[0145] Please refer to Figure 7, the execution process of the measurement and control lower machine of the quantum measurement and control system proposed in this embodiment can be: when the RPC service is started, the driver instance of the measurement and control lower machine will be bound to the module attribute of the RPC server (that is, create a device driver instance, and bind the device driver instance to the attribute of the remote procedure call server), and the instruction received by RPC will be passed to the device-specific driver through the attribute, thereby realizing the remote procedure call of the measurement and control lower machine driver (that is, the remote procedure call server parses the experimental instruction to determine the target driver instance corresponding to the experimental instruction; the remote procedure call server sends the experimental instruction to the attribute of the remote procedure call server, and sends the experimental instruction to the target driver instance through the attribute of the remote procedure call server). After the connection is successfully established, the RPC server will listen to the message queue waiting for the member function to be called, and detect whether the interface call is normal. If it is normal, it will continue to listen to the message queue waiting for the member function to be called. If it is not normal, the experiment will be terminated and a driver exception will be thrown. It should be noted that in order to achieve a unified drive control method for different types and brands of measurement and control slave computers, the driver deployed in the measurement and control slave computer consists of two layers of structure: GeneralDevice class and Device class. As a general instrument driver, the GeneralDevice class provides four member functions of initialization, connection, writing, and reading according to the operation of the measurement and control instrument; the Device class inherits from GeneralDevice and is a driver developed for each measurement and control slave computer. Its member functions rewrite the functions in the parent class to implement unique control methods for some attributes of the measurement and control slave computer.
[0146] It should be noted that the above examples are only used to understand the present application and do not constitute a limitation on the quantum measurement and control method of the present application. More simple transformations based on this technical concept are all within the scope of protection of the present application.
[0147] The present application provides a quantum measurement and control device, which includes: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the quantum measurement and control method in the above-mentioned embodiment 1.
[0148] Reference below Figure 8, which shows a schematic diagram of the structure of a quantum measurement and control device suitable for implementing the embodiments of the present application. The quantum measurement and control device in the embodiments of the present application may include but is not limited to mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 8 The quantum measurement and control device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0149] like Figure 8 As shown, the quantum measurement and control device may include a processing device 1001 (such as a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM: Read Only Memory) 1002 or the program loaded from the storage device 1003 to the random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the quantum measurement and control device are also stored. The processing device 1001, ROM1002 and RAM1004 are connected to each other through a bus 1005. The input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the quantum measurement and control device to communicate with other devices wirelessly or wired to exchange data. Although the figure shows a quantum measurement and control device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or provided instead.
[0150] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.
[0151] The quantum measurement and control device provided by the present application adopts the quantum measurement and control method in the above embodiment, which can solve the technical problem that the stability of the quantum measurement and control system is affected. Compared with the prior art, the beneficial effects of the quantum measurement and control device provided by the present application are the same as the beneficial effects of the quantum measurement and control method provided by the above embodiment, and the other technical features in the quantum measurement and control device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.
[0152] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.
[0153] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0154] The present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the quantum measurement and control method in the above-mentioned embodiment.
[0155] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM: Random Access Memory), a read-only memory (ROM: Read Only Memory), an erasable programmable read-only memory (EPROM: Erasable Programmable Read Only Memory or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM: CD-Read Only Memory), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency: Radio Frequency), etc., or any suitable combination of the above.
[0156] The above-mentioned computer-readable storage medium may be included in the quantum measurement and control device; or it may exist independently without being assembled into the quantum measurement and control device.
[0157] The above-mentioned computer-readable storage medium carries one or more programs. When the above-mentioned one or more programs are executed by the quantum measurement and control device, the quantum measurement and control device implements the quantum measurement and control method in the above-mentioned embodiment.
[0158] Computer program code for performing the operations of the present application may be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0159] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0160] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.
[0161] The readable storage medium provided in this application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned quantum measurement and control method, and can solve the technical problem that the stability of the quantum measurement and control system is affected. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as the beneficial effects of the quantum measurement and control method provided in the above-mentioned embodiment, and will not be repeated here.
[0162] The present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned quantum measurement and control method when executed by a processor.
[0163] The computer program product provided in this application can solve the technical problem that the stability of the quantum measurement and control system is affected. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as the beneficial effects of the quantum measurement and control method provided in the above embodiment, which will not be repeated here.
[0164] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.
Claims
1. A quantum measurement and control method, characterized in that: The quantum measurement and control method is applied to a measurement and control host computer in a quantum measurement and control system, wherein a remote procedure call client is deployed in the measurement and control host computer, and the quantum measurement and control system further comprises a measurement and control slave computer, wherein a remote procedure call server and a device driver are deployed in the measurement and control slave computer, and the remote procedure call client establishes a communication connection with the remote procedure call server. The quantum measurement and control method comprises: Acquire experimental parameter information of a quantum experiment to be performed, and generate an experimental instruction according to the experimental parameter information; The experimental instruction is sent to the remote procedure call server through the remote procedure call client, wherein the measurement and control lower computer receives the experimental instruction through the remote procedure call server and sends it to the device driver, the device driver performs the experimental operation according to the experimental instruction to obtain the experimental result, and returns the experimental result to the remote procedure call client through the remote procedure call server; Sending the experimental instruction to the remote procedure call server through the remote procedure call client to receive the experimental result, and reading the experimental data based on the experimental result; Wherein, before the step of sending the experimental instruction to the remote procedure call server through the remote procedure call client, it also includes: Determine, based on the experimental instruction, the name of the device indicated by the experimental instruction; Creating multiple client instances, and establishing communication connections with server instances of remote procedure call servers of multiple lower computers through the multiple client instances, wherein the server instances connected to the multiple client instances correspond to different lower computers; Acquire, through the multiple client instances, the lower computer names and driver instance identifiers of the lower computers to which they are connected based on the server instances to which they are connected; Constructing a driver dictionary by using the respective lower computer names of the plurality of lower computers as keys and the respective driver instance identifiers of the plurality of lower computers as values; Detect whether the device name exists in each lower machine name stored in the preset driver dictionary; If the device name exists in the names of the slave computers stored in the driver dictionary, the slave computer corresponding to the device name among the multiple slave computers is used as the measurement and control slave computer.
2. The quantum measurement and control method according to claim 1, characterized in that: The step of generating an experimental instruction according to the experimental parameter information comprises: Generate a configuration dictionary based on the experimental parameter information, wherein the configuration dictionary is used to store the experimental parameter information; An experimental instance is constructed based on the configuration dictionary, and an experimental instruction is generated based on the experimental instance, wherein the experimental instance is used to characterize the experimental configuration of the quantum experiment to be performed.
3. The quantum measurement and control method according to claim 2, characterized in that: The step of constructing an experimental instance based on the configuration dictionary and generating an experimental instruction based on the experimental instance includes: Parsing the configuration dictionary to generate a tuple list and a read instruction, wherein the tuple list includes a plurality of tuples, and the tuples represent experimental steps of the quantum experiment to be performed; The tuple list is stored as a set attribute value of a preset basic instance, the read instruction is stored as a read attribute value of the basic instance, and the basic instance storing the set attribute value and the read attribute value is used as an experimental instance; An operation instruction is constructed based on the setting attribute value, and a read instruction is constructed based on the read attribute value, and the operation instruction and the read instruction are used as the experimental instruction.
4. A quantum measurement and control method, characterized in that: The quantum measurement and control method is applied to a measurement and control lower computer in a quantum measurement and control system, wherein a remote procedure call server and a device driver are deployed in the measurement and control lower computer. The quantum measurement and control system also includes a measurement and control upper computer, wherein a remote procedure call client is deployed in the measurement and control upper computer, and a communication connection is established between the remote procedure call client and the remote procedure call server. The quantum measurement and control method includes: Receiving, through the remote procedure call server, an experimental instruction sent by the measurement and control host computer through the remote procedure call client, wherein the experimental instruction is generated by the measurement and control host computer based on the acquired experimental parameter information of the quantum experiment to be executed; The experimental instruction is sent to the device driver through the remote procedure call server, the device driver performs the experimental operation according to the experimental instruction to obtain the experimental result, and returns the experimental result to the remote procedure call server; The experimental result is returned to the remote procedure call client through the remote procedure call server, wherein the measurement and control host computer receives the experimental result through the remote procedure call client, and reads the experimental data based on the experimental result; Wherein, before the step of receiving the experimental instruction sent by the measurement and control host computer through the remote procedure call client through the remote procedure call server, it also includes: Creating a device driver instance, and binding the device driver instance to the attributes of the remote procedure call server; The step of sending the experimental instruction to the device driver through the remote procedure call server includes: Parsing the experimental instruction by the remote procedure call server to determine the target driver instance corresponding to the experimental instruction; The experimental instruction is sent to the attribute of the remote procedure call server through the remote procedure call server, and the experimental instruction is sent to the target driver instance through the attribute of the remote procedure call server.
5. A quantum measurement and control system, characterized in that: The quantum measurement and control system includes a measurement and control host computer and a measurement and control slave computer, a remote procedure call client is deployed in the measurement and control host computer, a remote procedure call server is deployed in the measurement and control slave computer, and a communication connection is established between the remote procedure call client and the remote procedure call server; the measurement and control host computer executes the steps of the quantum measurement and control method described in any one of claims 1 to 3, and the measurement and control slave computer executes the steps of the quantum measurement and control method described in claim 4.
6. The quantum measurement and control system according to claim 5, characterized in that: The measurement and control host computer also includes an interaction unit, an experiment processing unit and an instruction issuing unit. The experiment processing unit is respectively connected to the interaction unit and the instruction issuing unit for communication, and the instruction issuing unit is connected to the remote procedure call client for communication.
7. The quantum measurement and control system according to any one of claims 5 to 6, characterized in that: The measurement and control lower computer includes a plurality of remote call units, each of which includes a remote procedure call server instance and a drive unit with communication connection, and the remote procedure call server instance is in communication connection with the remote procedure call client.
8. A quantum measurement and control device, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the quantum measurement and control method according to any one of claims 1 to 4.
9. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the quantum measurement and control method according to any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Remote control method and system of measurement instrument
CN107315360A
Calibration and verification system and calibration and verification method of test machine and electronic equipment
CN117388787A