iV 2017 Translating visually the reasoning of a perceptron: the weighted rainbow boxes technique and an application in antibiotherapy Jean-Baptiste Lamy, Rosy Tsopra jibalamy@free.fr LIMICS , Université Paris 13, Sorbonne Paris Cité, 93017 Bobigny, France INSERM UMRS 1142, UPMC Université Paris 6, Sorbonne Universités This work was funded by the French drug agency (ANSM, Agence Nationale de Sécurité du Médicament et des produits de santé) through the RaMiPa project (AAP-2016).
Introduction w 1 Perceptron I 1 Artificial / formal neuron f(x) w 2 Simplified model of a biological neuron I 2 O = f(I 1 x w 1 Unit for artificial neural networks (ANN) ... + I 2 x w 2 + ... w n n inputs I , n weights w , I n + I n x w n ) 1 activation function f , 1 output O Can solve linearly separable problems More complex problems required ANN with hidden layers Sufficient for many real-life problems Ex : choosing an antibiotic Perceptron and ANN act as a black-box A solution could be the visualization of the reasoning 3
Related works: Visualization of artificial neural networks Visualization of the topology of the network with oriented graphs Bond diagram Lascaux 4
Related works: Visualization of artificial neural networks Visualization of the topology of the network with oriented graphs Connectomics Xia et al., BrainNet Viewer: a network visualization tool for human brain connectomics PloS one 2013 5
Related works: Visualization of artificial neural networks Visualization of the weights of the network with Hinton diagrams Hinton, Distributed representations, 1986 6
Related works: Visualization of artificial neural networks For a single perceptron: 2-3 inputs + 1 output => hyperplane Problematic for more than 3 inputs Input #2 Input #1 7
Rainbow boxes A recent visualization technique for overlapping sets Several elements and several sets made of these elements One column per element One rectangular box per set, covering the columns corresponding to the elements of the set Boxes may have holes Columns are ordered by a heuristic algorithm that minimizes the number and the size of holes 8
Visualizing a perceptron with rainbow boxes Let us consider a perceptron with : Boolean inputs (0 / 1) Output : Boolean, with f (x) = 1 if and only if x > t , t being a given constant Positive real, with f (x) = x Strictly positive weights No bias w 1 = 1.5 I 1 f(x) w 2 = 1.0 I 2 O = f(I 1 x w 1 + I 2 x w 2 w 3 = 2.0 + I 3 x w 3 ) I 3 9
Visualizing a perceptron with rainbow boxes The input vectors can be seen as overlapping sets Each input vector can be described as the set of inputs that are true ( 0, 1, 1 ) ( 1, 1, 1 ) ( 0, 0, 1 ) ( 0, 0, 0 ) I 1 I 2 I 3 w 1 = 1.5 I 1 f(x) w 2 = 1.0 I 2 O = f(I 1 x w 1 + I 2 x w 2 w 3 = 2.0 + I 3 x w 3 ) I 3 10
Visualizing a perceptron with rainbow boxes Weighted rainbow boxes : additional visual variable : box height Input weights w are represented by box height and color saturation Output values O are obtained by summing visually the ( 0, 1, 1 ) ( 1, 1, 1 ) ( 0, 0, 1 ) ( 0, 0, 0 ) heights of the boxes O (1, 1, 1) w 1 I 1 O (0, 1, 1) I 2 w 2 O (0, 0, 1) w 3 I 3 w 1 = 1.5 I 1 f(x) w 2 = 1.0 I 2 O = f(I 1 x w 1 + I 2 x w 2 w 3 = 2.0 + I 3 x w 3 ) I 3 11
Visualizing a perceptron with rainbow boxes Weighted rainbow boxes : additional visual variable : box height Input weights w are represented by box height and color saturation Output values O are obtained by summing visually the ( 0, 1, 1 ) ( 1, 1, 1 ) ( 0, 0, 1 ) ( 0, 0, 0 ) heights of the boxes For Boolean output, t I 1 a threshold horizontal line is added I 2 I 3 w 1 = 1.5 I 1 f(x) w 2 = 1.0 I 2 O = f(I 1 x w 1 + I 2 x w 2 w 3 = 2.0 + I 3 x w 3 ) I 3 12
Application in antibiotherapy Non-optimal antibiotics => complications for the patient and emergence of bacteria resistance In primary care, 6 antibiotic properties to consider [Tsopra et al.] Knowledge base (OWL ontology, ALIF family of DLs) 7 indications in urinary infections 6 properties corresponding to antibiotics disadvantages: I1: moderate efficacy I2: complex administration protocol I3: risk of emergence of bacteria resistance I4: risk of adverse effects I5: broad bacteria spectrum I6: precious class (i.e. should be reserved for serious disorders) 13
Medical reasoning Medical reasoning for selecting an antibiotic proceeds by the progressive exclusion of the worst antibiotics Correspond to a lexical order of the 6 disadvantages w1 > w2 > w3 > w4 = w5 = w6 Can be represented by a perceptron with 6 inputs (1 per disadvantage) and 1 output (a real score, lower means better antibiotic) : w1 > w2 + w3 + w4 + w5 + w6 w2 > w3 + w4 + w5 + w6 w3 > w4 + w5 + w6 w 1 = 16.0 w4 = w5 = w6 I 1 (efficacy) w 2 = 7.9 O Visual constraints : I 2 (protocol) w 3 = 3.8 f noop (x) = x w i ≥ 1 I 3 (resistance) (score) w 4 = 1.0 Σw i should be minimum I 4 (adverse effect) = I 1 x w 1 + I 2 x w 2 w 5 = 1.0 w i , w j should be + I 3 x w 3 + I 4 x w 4 I 5 (spectrum) sufficiently different + I 5 x w 5 + I 6 x w 6 w 6 = 1.0 I 6 (precious class) 14
Visualization 15
Visualization Shows the 10 antibiotics that can be prescribed for cystitis in adults with risk of complication, with their disadvantages Allow the visual computation of a score for each antibiotics Lower score => better antibiotic Here, nitrofurantoin is the best antibiotic Followed by enoxacin, lomefloxacin, norfloxacin and ofloxacin 16
User study protocol 11 General Practitioners (GPs) Two datasets with 5 and 10 antibiotics For each dataset : The GPs scored their feeling about 4 affirmations (5-level Likert scale) Then he indicated the antibiotic he would prescribe Finally he indicated if he would like to have this system in practice (5-level Likert scale) 17
User study results For each dataset, 8 GPs choose the drug with the lowest score 18
Discussion Weighted rainbow boxes Reasoning power equivalent to a perceptron Visual translation of the reasoning Can present Boolean properties of several items, but also permit the visual computation of a score for each item Pre-attentive immediate computation unless holes are involved Holes complicates the visualization but Human eyes can deal with a limited number of holes Weighted rainbow boxes vs hyperplane : Hyperplane is limited to 2-3 inputs Weighted rainbow boxes is limited to Boolean inputs 19
Perspectives Visualization of networks with several perceptrons ANN with one layer of several neurons ANN with hidden layers 20
Perspectives Visualization of networks with several perceptrons ANN with several outputs ANN with hidden layers Application to other domains Visualization of reasoning Visual translation of a reasoning that is not visual by nature Case-Based Reasoning 21
References JB Lamy, H Berthelot, M Favre, Rainbow boxes: a technique for visualizing overlapping sets and an application to the comparison of drugs properties , iV2016, Lisboa R Tsopra, A Venot, C Duclos, Towards evidence-based CDSSs implementing the medical reasoning contained in CPGs: application to antibiotic prescription , Stud Health Technol Inform 2014, 205:13-17 R Tsopra, A Venot, C Duclos, An algorithm using twelve properties of antibiotics to find the recommended antibiotics, as in CPGs , AMIA Annu Symp Proc 2014 22
Recommend
More recommend