The present invention concerns a method for assessing a robustness of a smoothed classifier, a method for assessing an overall robustness of a smoothed classifier, a method for training a smoothed classifier, a method for operating a smoothed classifier, a method for providing an actuator control signal, a computer program and a machine-readable storage medium.
In safety-critical applications like, for example, highly automated driving, it is important that a classification and/or semantic segmentation of an input signal depending on which further actions of the system are selected is correct.
However, without appropriate counter-measures, classifiers, like, e.g., neural network classification systems can easily be fooled. Classifiers which may be based on deep learning may be sensitive to small perturbations. In order to deploy such systems in the physical world it is important to provide a proof about the system's robustness.
“Certified Robustness to Adversarial Examples with Differential Privacy”, arXiv preprint arXiv:1802.03471v3, 2018, Mathias Lecuyer, Vaggelis Atlidakis, Roxana Geambasu, Daniel Hsu, Suman Jana and “Second-Order Adversarial Attack and Certifiable Robustness”, arXiv preprint arXiv: 1809.03113v1, 2018, Bai Li, Changyou Chen, Wenlin Wang, Lawrence Carin describe a randomization technique to create a certifiably robust classifier based on a given classifier f, that maps an input signal to classes . Classifier f is also called a base classifier in this context. They also presented certifiably robust bounds for such a smoothed classifier.
A smoothed classifier g may be defined as follows: When presented with an input x, the smoothed classifier g returns the most likely prediction by base classifier f under noise, in particular under random Gaussian perturbations of input signal x:
where ϵ˜(0, σ2I) for some predefined variance σ2.
In order to be sure that the classification of said smoothed classifier g is correct, it is important to have guaranteed robustness. A method in accordance with an example embodiment of the present invention may yield a robustness value (also called a robustness bound) that guarantees that the classification yielded by smoothed classifier g is the same for all input vectors that lie within a ball of radius around input signal x.
Therefore, in a first aspect, the present invention is concerned with a computer-implemented method for assessing a robustness of a smoothed classifier (g) for classifying sensor signals received from a sensor (30). In accordance with an example embodiment of the present invention, the method comprises the following steps:
It may then be decided that the smoothed classifier (g) is robust if and only if said robustness value is larger than a predefined threshold.
For example, said predefined threshold may be given by a quantity characterizing noise in said sensor signals.
In a preferred embodiment, said robustness value is determined proportional to Φ−1(pA)−Φ−1(pB), preferably σ·(Φ−1(pA)−Φ−1(pB)).
If it is chosen equal to
the bound is tight. This bound is substantially larger and therefore more useful than previously known bounds. In mathematical terms, pA is a lower bound on (f(x+ϵ)=cA), pB is an upper bound on
To compute the robustness value around input signal x, it is necessary to compute pA and pB. However, if the input signal is high-dimensional, it is impossible to exactly compute the distribution of f (x+ϵ), which is a discrete distribution over the set of possible classes . That is because in order to compute g(x) exactly, it is necessary to compute f(x+ϵ) over all possible states x+ϵ and integrate a Gaussian along the set SA={x+ϵ|f(x+ϵ)=cA}.
A good approximation can be obtained by Monte Carlo estimation to construct bounds pA and pB.that satisfy
Estimating pA and pB while simultaneously identifying the top class cA is potentially inefficient. A straightforward implementation would compute pi=(f(x+ϵ)=ci) for all classes ci and then identify cA as the class with the largest pi. This is guaranteed to be precise, but expensive to compute.
One way is a two-step procedure. First, use n0 samples from f(x+ϵ) to take a guess
In a further aspect of the present invention, it is possible to apply the above method to a test set comprising a plurality of test input signals (xi). Using said test input signal (xi) as input signal (x) as above, it is then possible to determine a plurality of test robustness values (i), each corresponding to one of the test input signals (xi). It is then possible to determine an overall robustness value (ov) that characterizes the determined set of test robustness values (i′), for example its minimum value.
It may then be decided that the smoothed classifier (g) is robust if and only if said overall robustness value ov is larger than a predefined threshold.
Alternatively, it is then possible to determine whether said smoothed classifier (g) is robust or not based on a relative size of said robustness value () and said overall robustness value (ov). Said relative size is an indicator whether said input signal (x) is meaningfully represented by the test set, or not, or, in other words, whether said input signal (x) is representative of said test set. For example, it may be determined that said smoothed classifier (g) is robust if and only if said relative size, for example a quotient /ov′ is larger than a second predefined threshold.
In a further aspect of the present invention, this decision whether the smoothed classifier (g) is robust or not as a cut-off criterion is used for training of said smoothed classifier (g), wherein training is continued if said smooth classifier (g) is determined to be non-robust.
In a still further aspect of the present invention, it is possible to use relative size for training during operation of said smoothed classifier. In accordance with an example embodiment of the present invention, it may be provided to operate said smoothed classifier (g), determining whether said smoothed classifier (g) is robust or not using the above method, and, if said smoothed classifier (g) is determined to be non-robust based on said relative size, send said input signal (x) to a remote server, receive, from said remote server, a target classification of said input signal (x), and further train said smoothed classifier (g) using said input signal (x) and said target classification. For example, said target classification may have been provided by a human expert. Remote may mean that said remote server and a computer executing said smoothed classifier are not integrated in a single unit.
In another still further aspect of the present invention, it is possible to use said robustness value as a trigger for closer inspection, by determining, using the above method, said robustness value () of said smoothed classifier (g) when provided with said input signal (x) and adjusting operating parameters of said sensor (30) depending on said robustness value. In particular, said sensor (30) may be controlled to zoom into a region that is classified as non-robust.
In another still further aspect of the present invention, it is possible to use said robustness value for safe operation of an actuator, by assessing whether said smoothed classifier (g) is robust or not using the above method, and determining an actuator control signal (A) for controlling said actuator in accordance with a result of said assessment, in particular by determining said actuator control signal (A) to cause said actuator to operate in a safe mode if said smoothed classifier (g) is deemed not robust as a result of said assessment.
Naturally, the above methods are not limited in application to automated driving. In other applications, said actuator may be controlling an at least partially autonomous robot (100) and/or a manufacturing machine (200)) and/or an access control system (300).
Example embodiments of the present invention are discussed with reference to the following figures in more detail below.
Shown in
Thereby, control system 40 receives a stream of sensor signals S. It then computes a series of actuator control commands A depending on the stream of sensor signals S, which are then transmitted to actuator 10.
Control system 40 receives the stream of sensor signals S of sensor 30 in an optional receiving unit 50. Receiving unit 50 transforms the sensor signals S into input signals x. Alternatively, in case of no receiving unit 50, each sensor signal S may directly be taken as an input signal x. Input signal x may, for example, be given as an excerpt from sensor signal S. Alternatively, sensor signal S may be processed to yield input signal x. Input signal x comprises image data corresponding to an image recorded by sensor 30. In other words, input signal x is provided in accordance with sensor signal S.
Input signal x is then passed on to a classifier 60, which may, for example, be given by an artificial neural network.
Classifier 60 is parametrized by parameters ϕ, which are stored in and provided by parameter storage St1.
Classifier 60 determines output signals y from input signals x. The output signal y comprises top class cA and robustness value . Naturally, top class cA and robustness value may correspond to a classification of the entire input signal x. Alternatively, it may be given as a semantic segmentation, e.g., by assigning classes to bounding boxes. Output signals y are transmitted to an optional conversion unit 80, which is configured to determine actuator control commands A. Actuator control commands A are then transmitted to actuator 10 for controlling actuator 10 accordingly. Alternatively, output signals y may directly be taken as control commands A.
Actuator 10 receives actuator control commands A, is controlled accordingly and carries out an action corresponding to actuator control commands A. Actuator 10 may comprise a control logic which transforms actuator control command A into a further control command, which is then used to control actuator 10.
In further embodiments, control system 40 may comprise sensor 30. In even further embodiments, control system 40 alternatively or additionally may comprise actuator 10.
In still further embodiments, control system 40 may control a display 10a instead of an actuator 10.
Furthermore, control system 40 may comprise a processor 45 (or a plurality of processors) and at least one machine-readable storage medium 46 on which instructions are stored which, if carried out, cause control system 40 to carry out a method according to one aspect of the present invention.
Sensor 30 may comprise one or more video sensors and/or one or more radar sensors and/or one or more ultrasonic sensors and/or one or more LiDAR sensors and or one or more position sensors (like, e.g., GPS). Some or all of these sensors are preferably but not necessarily integrated in vehicle 100.
Alternatively or additionally sensor 30 may comprise an information system for determining a state of the actuator system. One example for such an information system is a weather information system which determines a present or future state of the weather in environment 20.
For example, using input signal x, the classifier 60 may for example detect objects in the vicinity of the at least partially autonomous robot. Output signal y may comprise an information which characterizes where objects are located in the vicinity of the at least partially autonomous robot. Control command A may then be determined in accordance with this information, for example to avoid collisions with said detected objects.
Actuator 10, which is preferably integrated in vehicle 100, may be given by a brake, a propulsion system, an engine, a drivetrain, or a steering of vehicle 100. Actuator control commands A may be determined such that actuator (or actuators) 10 is/are controlled such that vehicle 100 avoids collisions with said detected objects. Detected objects may also be classified according to what the classifier 60 deems them most likely to be, e.g., pedestrians or trees, and actuator control commands A may be determined depending on the classification.
In further embodiments, the at least partially autonomous robot may be given by another mobile robot (not shown), which may, for example, move by flying, swimming, diving or stepping. The mobile robot may, inter alia, be an at least partially autonomous lawn mower, or an at least partially autonomous cleaning robot. In all of the above embodiments, actuator command control A may be determined such that propulsion unit and/or steering and/or brake of the mobile robot are controlled such that the mobile robot may avoid collisions with said identified objects.
In a further embodiment, the at least partially autonomous robot may be given by a gardening robot (not shown), which uses sensor 30, preferably an optical sensor, to determine a state of plants in the environment 20. Actuator 10 may be a nozzle for spraying chemicals. Depending on an identified species and/or an identified state of the plants, an actuator control command A may be determined to cause actuator 10 to spray the plants with a suitable quantity of suitable chemicals.
In even further embodiments, the at least partially autonomous robot may be given by a domestic appliance (not shown), like, e.g., a washing machine, a stove, an oven, a microwave, or a dishwasher. Sensor 30, e.g., an optical sensor, may detect a state of an object which is to undergo processing by the household appliance. For example, in the case of the domestic appliance being a washing machine, sensor 30 may detect a state of the laundry inside the washing machine. Actuator control signal A may then be determined depending on a detected material of the laundry.
Shown in
Sensor 30 may be given by an optical sensor which captures properties of, e.g., a manufactured product 12. Classifier 60 may determine a state of the manufactured product 12 from these captured properties. Actuator 10 which controls manufacturing machine 11 may then be controlled depending on the determined state of the manufactured product 12 for a subsequent manufacturing step of manufactured product 12. Or, actuator 10 may be controlled during manufacturing of a subsequent manufactured product 12 depending on the determined state of the manufactured product 12.
Shown in
Control system 40 then determines actuator control commands A for controlling the automated personal assistant 250. The actuator control commands A are determined in accordance with sensor signal S from sensor 30. Sensor signal S is transmitted to the control system 40. For example, classifier 60 may be configured to, e.g., carry out a gesture recognition algorithm to identify a gesture made by user 249. Control system 40 may then determine an actuator control command A for transmission to the automated personal assistant 250. It then transmits said actuator control command A to the automated personal assistant 250.
For example, actuator control command A may be determined in accordance with the identified user gesture recognized by classifier 60. It may then comprise information that causes the automated personal assistant 250 to retrieve information from a database and output this retrieved information in a form suitable for reception by user 249.
In further embodiments, instead of the automated personal assistant 250, control system 40 controls a domestic appliance (not shown) controlled in accordance with the identified user gesture. The domestic appliance may be a washing machine, a stove, an oven, a microwave or a dishwasher.
Shown in
Shown in
Shown in
Shown in
Then (902), a predefined second number of samples n is provided and n random numbers ϵ are sampled from the standard Gaussian distribution with predefined standard deviation σ are added onto input signal x. For each random number ϵ, base classifier f returns a corresponding classification f(x+ϵ). By counting the number of occurrences of estimated top class
of estimated top class
Next (903), because the statistical sample with n data points is subject to fluctuations, lower bound pA satisfying (f(x+ϵ)=cA)≥pA is computed as a lower confidence bound with probability at least 1−α. This expression may conveniently given by the a quantile of the beta-distribution with parameters k and n-k+1.
For example one could use the following formula with Fa,b,c being the 1−c quantile of the F-distribution with parameters a and b. Then, the lower bound pA may be given by equation
Upper bound pB is computed (904) as pB=1−pA.
Then (905) it is checked whether pA≥pB, in which case the robustness value is computed using equation (2). If pA<pB, the algorithm abstains and issues a default error message, e.g., by setting =−1. This concludes the method.
Then (912) the top two classes cA, cB are selected as the two most frequently occurring classes amongst these classifications f(x+ϵ). nA and nB denote their absolute frequencies. Then (913), it is checked whether the two-sided binomial hypothesis test that nA is drawn from Binomial (½, nA+nB) returns a p-value of less than α. If this is the case (914), top class cA is returned, otherwise the algorithm abstaind.
Shown in
Shown in
Alternatively, overall robustness value may be selected differently, e.g., as the median or average value of all i. Then (2400), it is decided whether said overall robustness value ov is greater than a second threshold value τ2, which may be provided like threshold value τ in step (1200). If this is the case, classifier 60 is deemed to be overall robust (2500), if not (2600), it is deemed not to be overall robust.
Shown in
Steps (2100) and (2200) are identical to those in the method illustrated in
≤ov·c (4)
If this is the case (2700), input signal x is deemed not to be well represented in the test set and hence classifier 60 trained using the test set is deemed not robust. If this is not the case (2800), input signal x is deemed to be well represented in the test set, and hence classifier 60 is deemed to be robust.
Shown in
An actuator control signal (A) may then (916) be determined in accordance with said parameter vu, and actuator (10) may be controlled in accordance with said actuator control signal (A). For example, if said parameter vu indicates a non-vulnerability, said actuator control signal (A) may then be determined to correspond to normal operation mode, whereas, if said parameter vu indicates a vulnerability, said actuator control signal (A) may then be determined to correspond to a fail-safe operation mode, by, e.g., reducing a dynamics of a motion of said actuator (10).
Shown in
Shown in
Shown in
The term “computer” covers any device for the processing of pre-defined calculation instructions. These calculation instructions can be in the form of software, or in the form of hardware, or also in a mixed form of software and hardware.
It is further understood that the procedures cannot only be completely implemented in software as described. They can also be implemented in hardware, or in a mixed form of software and hardware.
Number | Date | Country | Kind |
---|---|---|---|
19155345.2 | Feb 2019 | EP | regional |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/IB2020/050176 | 1/10/2020 | WO | 00 |