File tree Expand file tree Collapse file tree 2 files changed +2
-20
lines changed
art/estimators/certification/randomized_smoothing Expand file tree Collapse file tree 2 files changed +2
-20
lines changed Original file line number Diff line number Diff line change @@ -164,16 +164,7 @@ class was initialised.
164164 import torch
165165 from torch .utils .data import TensorDataset , DataLoader
166166
167- if verbose is not None :
168- if isinstance (verbose , int ):
169- if verbose == 0 :
170- display_pb = False
171- else :
172- display_pb = True
173- else :
174- display_pb = verbose
175- else :
176- display_pb = self .verbose
167+ display_pb = self .process_verbose (verbose )
177168
178169 # Set model mode
179170 self ._model .train (mode = training_mode )
Original file line number Diff line number Diff line change @@ -156,16 +156,7 @@ class was initialised.
156156 """
157157 import tensorflow as tf
158158
159- if verbose is not None :
160- if isinstance (verbose , int ):
161- if verbose == 0 :
162- display_pb = False
163- else :
164- display_pb = True
165- else :
166- display_pb = verbose
167- else :
168- display_pb = self .verbose
159+ display_pb = self .process_verbose (verbose )
169160
170161 if self ._train_step is None : # pragma: no cover
171162 if self ._loss_object is None : # pragma: no cover
You can’t perform that action at this time.
0 commit comments