SYMBOL INDEX (2257 symbols across 231 files) FILE: cleverhans/devtools/checks.py class CleverHansTest (line 17) | class CleverHansTest(unittest.TestCase): method setUp (line 20) | def setUp(self): method tearDown (line 25) | def tearDown(self): method assertClose (line 28) | def assertClose(self, x, y, *args, **kwargs): FILE: cleverhans/devtools/list_files.py function list_files (line 6) | def list_files(suffix=""): function _list_files (line 47) | def _list_files(path, suffix=""): FILE: cleverhans/devtools/mocks.py function random_feed_dict (line 16) | def random_feed_dict(rng, placeholders): class SimpleDataset (line 35) | class SimpleDataset(Dataset): method __init__ (line 41) | def __init__( FILE: cleverhans/devtools/tests/test_format.py function update_whitelist (line 24) | def update_whitelist(): function test_format_pep8 (line 84) | def test_format_pep8(): FILE: cleverhans/devtools/version.py function dev_version (line 11) | def dev_version(): function append_dev_version (line 27) | def append_dev_version(release_version): FILE: cleverhans/experimental/certification/certify.py function main (line 82) | def main(_): FILE: cleverhans/experimental/certification/dual_formulation.py class DualFormulation (line 29) | class DualFormulation(object): method __init__ (line 35) | def __init__( method create_projected_dual (line 184) | def create_projected_dual(self): method construct_lanczos_params (line 238) | def construct_lanczos_params(self): method set_differentiable_objective (line 291) | def set_differentiable_objective(self): method get_h_product (line 354) | def get_h_product(self, vector, dtype=None): method get_psd_product (line 416) | def get_psd_product(self, vector, dtype=None): method get_full_psd_matrix (line 445) | def get_full_psd_matrix(self): method make_m_psd (line 499) | def make_m_psd(self, original_nu, feed_dictionary): method get_lanczos_eig (line 538) | def get_lanczos_eig(self, compute_m=True, feed_dict=None): method compute_certificate (line 561) | def compute_certificate(self, current_step, feed_dictionary): FILE: cleverhans/experimental/certification/nn.py class NeuralNetwork (line 15) | class NeuralNetwork(object): method __init__ (line 20) | def __init__( method forward_pass (line 132) | def forward_pass(self, vector, layer_index, is_transpose=False, is_abs... function load_network_from_checkpoint (line 195) | def load_network_from_checkpoint(checkpoint, model_json, input_shape=None): FILE: cleverhans/experimental/certification/optimization.py class Optimization (line 21) | class Optimization(object): method __init__ (line 24) | def __init__(self, dual_formulation_object, sess, optimization_params): method tf_min_eig_vec (line 58) | def tf_min_eig_vec(self): method tf_smooth_eig_vec (line 66) | def tf_smooth_eig_vec(self): method get_min_eig_vec_proxy (line 84) | def get_min_eig_vec_proxy(self, use_tf_eig=False): method get_scipy_eig_vec (line 117) | def get_scipy_eig_vec(self): method prepare_for_optimization (line 151) | def prepare_for_optimization(self): method run_one_step (line 257) | def run_one_step( method run_optimization (line 363) | def run_optimization(self): FILE: cleverhans/experimental/certification/tests/dual_formulation_test.py class DualFormulationTest (line 16) | class DualFormulationTest(unittest.TestCase): method test_init (line 17) | def test_init(self): method test_set_differentiable_objective (line 62) | def test_set_differentiable_objective(self): method test_get_full_psd_matrix (line 112) | def test_get_full_psd_matrix(self): method test_get_psd_product (line 159) | def test_get_psd_product(self): FILE: cleverhans/experimental/certification/tests/nn_test.py class NeuralNetworkTest (line 15) | class NeuralNetworkTest(unittest.TestCase): method test_init (line 16) | def test_init(self): method test_forward_pass (line 38) | def test_forward_pass(self): FILE: cleverhans/experimental/certification/tests/optimization_test.py class OptimizationTest (line 15) | class OptimizationTest(tf.test.TestCase): method prepare_dual_object (line 18) | def prepare_dual_object(self): method test_init (line 100) | def test_init(self): method test_get_min_eig_vec_proxy (line 122) | def test_get_min_eig_vec_proxy(self): method test_optimization (line 198) | def test_optimization(self): FILE: cleverhans/experimental/certification/tests/utils_test.py class UtilsTest (line 20) | class UtilsTest(tf.test.TestCase): method test_minimum_eigen_vector (line 21) | def test_minimum_eigen_vector(self): method test_tf_lanczos_smallest_eigval (line 37) | def test_tf_lanczos_smallest_eigval(self): FILE: cleverhans/experimental/certification/utils.py function diag (line 11) | def diag(diag_elements): function initialize_dual (line 23) | def initialize_dual( function eig_one_step (line 138) | def eig_one_step(current_vector, learning_rate, vector_prod_fn): function minimum_eigen_vector (line 206) | def minimum_eigen_vector(x, num_steps, learning_rate, vector_prod_fn): function tf_lanczos_smallest_eigval (line 228) | def tf_lanczos_smallest_eigval( FILE: cleverhans/jax/attacks/fast_gradient_method.py function fast_gradient_method (line 8) | def fast_gradient_method( FILE: cleverhans/jax/attacks/projected_gradient_descent.py function projected_gradient_descent (line 7) | def projected_gradient_descent( FILE: cleverhans/jax/utils.py function one_hot (line 4) | def one_hot(x, k, dtype=np.float32): function partial_flatten (line 9) | def partial_flatten(x): function clip_eta (line 14) | def clip_eta(eta, norm, eps): FILE: cleverhans/plot/image.py function show (line 14) | def show(ndarray, min_val=None, max_val=None): function save (line 33) | def save(path, ndarray, min_val=None, max_val=None): function as_pil (line 48) | def as_pil(ndarray, min_val=None, max_val=None): function make_grid (line 113) | def make_grid(image_batch): FILE: cleverhans/plot/pyplot_image.py function pair_visual (line 10) | def pair_visual(original, adversarial, figure=None): function grid_visual (line 53) | def grid_visual(data): function get_logits_over_interval (line 86) | def get_logits_over_interval( function linear_extrapolation_plot (line 137) | def linear_extrapolation_plot( FILE: cleverhans/plot/save_pdf.py function save_pdf (line 8) | def save_pdf(path): FILE: cleverhans/plot/success_fail.py function plot_report_from_path (line 19) | def plot_report_from_path( function plot_report (line 69) | def plot_report( function make_curve (line 128) | def make_curve(report, success_name, fail_names): FILE: cleverhans/tf2/attacks/basic_iterative_method.py function basic_iterative_method (line 8) | def basic_iterative_method( FILE: cleverhans/tf2/attacks/carlini_wagner_l2.py function carlini_wagner_l2 (line 8) | def carlini_wagner_l2(model_fn, x, **kwargs): class CarliniWagnerL2Exception (line 16) | class CarliniWagnerL2Exception(Exception): class CarliniWagnerL2 (line 20) | class CarliniWagnerL2(object): method __init__ (line 21) | def __init__( method attack (line 100) | def attack(self, x): method _attack (line 114) | def _attack(self, x): method attack_step (line 275) | def attack_step(self, x, y, modifier, const): method gradient (line 282) | def gradient(self, x, y, modifier, const): function l2 (line 304) | def l2(x, y): function loss_fn (line 309) | def loss_fn( function clip_tanh (line 340) | def clip_tanh(x, clip_min, clip_max): FILE: cleverhans/tf2/attacks/fast_gradient_method.py function fast_gradient_method (line 9) | def fast_gradient_method( FILE: cleverhans/tf2/attacks/madry_et_al.py function madry_et_al (line 8) | def madry_et_al( FILE: cleverhans/tf2/attacks/momentum_iterative_method.py function momentum_iterative_method (line 10) | def momentum_iterative_method( function loss_fn (line 112) | def loss_fn(labels, logits): FILE: cleverhans/tf2/attacks/projected_gradient_descent.py function projected_gradient_descent (line 10) | def projected_gradient_descent( FILE: cleverhans/tf2/attacks/spsa.py function spsa (line 8) | def spsa( class SPSAAdam (line 83) | class SPSAAdam(tf.optimizers.Adam): method __init__ (line 90) | def __init__( method _get_delta (line 105) | def _get_delta(self, x, delta): method _compute_gradients (line 117) | def _compute_gradients(self, loss_fn, x): method _apply_gradients (line 166) | def _apply_gradients(self, grads, x, optim_state): method init_state (line 196) | def init_state(self, x): method minimize (line 205) | def minimize(self, loss_fn, x, optim_state): function margin_logit_loss (line 220) | def margin_logit_loss(model_logits, label, nb_classes=10): function _project_perturbation (line 248) | def _project_perturbation( function projected_optimization (line 279) | def projected_optimization( FILE: cleverhans/tf2/utils.py function clip_eta (line 5) | def clip_eta(eta, norm, eps): function random_exponential (line 39) | def random_exponential(shape, rate=1.0, dtype=tf.float32, seed=None): function random_laplace (line 52) | def random_laplace(shape, loc=0.0, scale=1.0, dtype=tf.float32, seed=None): function random_lp_vector (line 68) | def random_lp_vector(shape, ord, eps, dtype=tf.float32, seed=None): function get_or_guess_labels (line 120) | def get_or_guess_labels(model_fn, x, y=None, targeted=False): function set_with_mask (line 158) | def set_with_mask(x, x_other, mask): function compute_gradient (line 171) | def compute_gradient(model_fn, loss_fn, x, y, targeted): function optimize_linear (line 198) | def optimize_linear(grad, eps, norm=np.inf): FILE: cleverhans/torch/attacks/carlini_wagner_l2.py function carlini_wagner_l2 (line 8) | def carlini_wagner_l2( FILE: cleverhans/torch/attacks/fast_gradient_method.py function fast_gradient_method (line 8) | def fast_gradient_method( FILE: cleverhans/torch/attacks/hop_skip_jump_attack.py function hop_skip_jump_attack (line 8) | def hop_skip_jump_attack( function compute_distance (line 216) | def compute_distance(x_ori, x_pert, constraint=2): function approximate_gradient (line 225) | def approximate_gradient( function project (line 262) | def project(original_image, perturbed_images, alphas, shape, constraint): function binary_search_batch (line 274) | def binary_search_batch( function initialize (line 325) | def initialize(decision_function, sample, shape, clip_min, clip_max): function geometric_progression_for_stepsize (line 362) | def geometric_progression_for_stepsize( function select_delta (line 381) | def select_delta( FILE: cleverhans/torch/attacks/noise.py function noise (line 9) | def noise(x, eps=0.3, order=np.inf, clip_min=None, clip_max=None): FILE: cleverhans/torch/attacks/projected_gradient_descent.py function projected_gradient_descent (line 9) | def projected_gradient_descent( FILE: cleverhans/torch/attacks/semantic.py function semantic (line 6) | def semantic(x, center=True, max_val=1.0): FILE: cleverhans/torch/attacks/sparse_l1_descent.py function sparse_l1_descent (line 8) | def sparse_l1_descent( FILE: cleverhans/torch/attacks/spsa.py function spsa (line 8) | def spsa( function _project_perturbation (line 171) | def _project_perturbation( function _compute_spsa_gradient (line 186) | def _compute_spsa_gradient(loss_fn, x, delta, samples, iters): function _margin_logit_loss (line 214) | def _margin_logit_loss(logits, labels): FILE: cleverhans/torch/tests/test_attacks.py class TrivialModel (line 22) | class TrivialModel(torch.nn.Module): method __init__ (line 23) | def __init__(self): method forward (line 27) | def forward(self, x, **kwargs): class SimpleModel (line 31) | class SimpleModel(torch.nn.Module): method __init__ (line 32) | def __init__(self): method forward (line 37) | def forward(self, x): class DummyModel (line 44) | class DummyModel(torch.nn.Module): method __init__ (line 45) | def __init__(self, n_features): method forward (line 53) | def forward(self, x): class CommonAttackProperties (line 58) | class CommonAttackProperties(CleverHansTest): method setUp (line 59) | def setUp(self): method help_adv_examples_success_rate (line 70) | def help_adv_examples_success_rate(self, model, x, rate=0.5, **kwargs): method help_targeted_adv_examples_success_rate (line 77) | def help_targeted_adv_examples_success_rate(self, model, x, rate=0.7, ... class TestFastGradientMethod (line 87) | class TestFastGradientMethod(CommonAttackProperties): method setUp (line 88) | def setUp(self): method test_invalid_input (line 94) | def test_invalid_input(self): method test_invalid_eps (line 109) | def test_invalid_eps(self): method test_eps_equals_zero (line 120) | def test_eps_equals_zero(self): method test_eps (line 126) | def test_eps(self): method test_clips (line 134) | def test_clips(self): method test_invalid_clips (line 149) | def test_invalid_clips(self): method test_adv_example_success_rate_linf (line 164) | def test_adv_example_success_rate_linf(self): method test_targeted_adv_example_success_rate_linf (line 171) | def test_targeted_adv_example_success_rate_linf(self): method test_adv_example_success_rate_l1 (line 176) | def test_adv_example_success_rate_l1(self): method test_targeted_adv_example_success_rate_l1 (line 181) | def test_targeted_adv_example_success_rate_l1(self): method test_adv_example_success_rate_l2 (line 186) | def test_adv_example_success_rate_l2(self): method test_targeted_adv_example_success_rate_l2 (line 191) | def test_targeted_adv_example_success_rate_l2(self): class TestProjectedGradientMethod (line 197) | class TestProjectedGradientMethod(CommonAttackProperties): method setUp (line 198) | def setUp(self): method test_invalid_input (line 209) | def test_invalid_input(self): method test_invalid_eps (line 241) | def test_invalid_eps(self): method test_invalid_eps_iter (line 266) | def test_invalid_eps_iter(self): method test_eps_equals_zero (line 291) | def test_eps_equals_zero(self): method test_eps_iter_equals_zero (line 317) | def test_eps_iter_equals_zero(self): method test_invalid_clips (line 343) | def test_invalid_clips(self): method test_adv_example_success_rate_linf (line 374) | def test_adv_example_success_rate_linf(self): method test_targeted_adv_example_success_rate_linf (line 381) | def test_targeted_adv_example_success_rate_linf(self): method test_adv_example_success_rate_l1 (line 386) | def test_adv_example_success_rate_l1(self): method test_targeted_adv_example_success_rate_l1 (line 399) | def test_targeted_adv_example_success_rate_l1(self): method test_adv_example_success_rate_l2 (line 412) | def test_adv_example_success_rate_l2(self): method test_targeted_adv_example_success_rate_l2 (line 417) | def test_targeted_adv_example_success_rate_l2(self): method test_do_not_reach_lp_boundary (line 422) | def test_do_not_reach_lp_boundary(self): method test_attack_strength (line 455) | def test_attack_strength(self): method test_eps (line 474) | def test_eps(self): method test_clip_eta (line 481) | def test_clip_eta(self): method test_clips (line 485) | def test_clips(self): method test_attack_does_not_cache_graph_computation_for_nb_iter (line 516) | def test_attack_does_not_cache_graph_computation_for_nb_iter(self): method test_multiple_initial_random_step (line 520) | def test_multiple_initial_random_step(self): class TestCarliniWagnerL2 (line 548) | class TestCarliniWagnerL2(CommonAttackProperties): method setUp (line 549) | def setUp(self): method test_adv_example_success_rate (line 559) | def test_adv_example_success_rate(self): method test_targeted_adv_example_success_rate (line 569) | def test_targeted_adv_example_success_rate(self): method test_adv_examples_clipped_successfully (line 579) | def test_adv_examples_clipped_successfully(self): method test_high_confidence_adv_example (line 590) | def test_high_confidence_adv_example(self): method test_high_confidence_targeted_adv_example (line 617) | def test_high_confidence_targeted_adv_example(self): class TestSPSA (line 646) | class TestSPSA(CommonAttackProperties): method setUp (line 647) | def setUp(self): method test_invalid_input (line 659) | def test_invalid_input(self): method test_invalid_eps (line 673) | def test_invalid_eps(self): method test_eps_equals_zero (line 678) | def test_eps_equals_zero(self): method test_invalid_clips (line 683) | def test_invalid_clips(self): method test_adv_example_success_rate_linf (line 695) | def test_adv_example_success_rate_linf(self): method test_targeted_adv_example_success_rate_linf (line 700) | def test_targeted_adv_example_success_rate_linf(self): method test_adv_example_success_rate_l1 (line 703) | def test_adv_example_success_rate_l1(self): method test_targeted_adv_example_success_rate_l1 (line 714) | def test_targeted_adv_example_success_rate_l1(self): method test_adv_example_success_rate_l2 (line 725) | def test_adv_example_success_rate_l2(self): method test_targeted_adv_example_success_rate_l2 (line 728) | def test_targeted_adv_example_success_rate_l2(self): method test_attack_strength (line 731) | def test_attack_strength(self): method test_eps (line 748) | def test_eps(self): method test_clips (line 755) | def test_clips(self): class TestHopSkipJumpAttack (line 770) | class TestHopSkipJumpAttack(CommonAttackProperties): method setUp (line 771) | def setUp(self): method test_generate_np_untargeted_l2 (line 775) | def test_generate_np_untargeted_l2(self): method test_generate_untargeted_linf (line 791) | def test_generate_untargeted_linf(self): method test_generate_np_targeted_linf (line 807) | def test_generate_np_targeted_linf(self): method test_generate_targeted_l2 (line 836) | def test_generate_targeted_l2(self): class TestSparseL1Descent (line 868) | class TestSparseL1Descent(CommonAttackProperties): method setUp (line 869) | def setUp(self): method generate_adversarial_examples (line 873) | def generate_adversarial_examples(self, **kwargs): method generate_targeted_adversarial_examples (line 884) | def generate_targeted_adversarial_examples(self, **kwargs): method test_invalid_input (line 902) | def test_invalid_input(self): method test_gives_adversarial_example (line 907) | def test_gives_adversarial_example(self): method test_targeted_gives_adversarial_example (line 914) | def test_targeted_gives_adversarial_example(self): method test_can_be_called_with_different_eps (line 921) | def test_can_be_called_with_different_eps(self): method test_clip_works_as_expected (line 928) | def test_clip_works_as_expected(self): method test_do_not_reach_lp_boundary (line 941) | def test_do_not_reach_lp_boundary(self): method test_generate_np_gives_clipped_adversarial_examples (line 952) | def test_generate_np_gives_clipped_adversarial_examples(self): method test_clip_eta (line 965) | def test_clip_eta(self): method test_attack_strength (line 973) | def test_attack_strength(self): method test_grad_clip (line 987) | def test_grad_clip(self): method test_sparsity (line 1006) | def test_sparsity(self): method test_grad_sparsity_checks (line 1024) | def test_grad_sparsity_checks(self): FILE: cleverhans/torch/tests/test_utils.py class TestOptimizeLinear (line 9) | class TestOptimizeLinear(CleverHansTest): method setUp (line 14) | def setUp(self): method test_optimize_linear_linf (line 23) | def test_optimize_linear_linf(self): method test_optimize_linear_l2 (line 32) | def test_optimize_linear_l2(self): method test_optimize_linear_l1 (line 41) | def test_optimize_linear_l1(self): method test_optimize_linear_l1_ties (line 50) | def test_optimize_linear_l1_ties(self): method test_optimize_linear_linf_satisfies_norm_constraint (line 59) | def test_optimize_linear_linf_satisfies_norm_constraint(self): method test_optimize_linear_l1_satisfies_norm_constraint (line 64) | def test_optimize_linear_l1_satisfies_norm_constraint(self): method test_optimize_linear_l2_satisfies_norm_constraint (line 70) | def test_optimize_linear_l2_satisfies_norm_constraint(self): method test_clip_eta_linf (line 93) | def test_clip_eta_linf(self): method test_clip_eta_l1 (line 98) | def test_clip_eta_l1(self): method test_clip_eta_l2 (line 108) | def test_clip_eta_l2(self): FILE: cleverhans/torch/utils.py function clip_eta (line 8) | def clip_eta(eta, norm, eps): function get_or_guess_labels (line 42) | def get_or_guess_labels(model, x, **kwargs): function optimize_linear (line 69) | def optimize_linear(grad, eps, norm=np.inf): function zero_out_clipped_grads (line 127) | def zero_out_clipped_grads(grad, x, clip_min, clip_max): FILE: cleverhans/utils.py class _ArgsWrapper (line 40) | class _ArgsWrapper(object): method __init__ (line 46) | def __init__(self, args): method __getattr__ (line 51) | def __getattr__(self, name): class AccuracyReport (line 55) | class AccuracyReport(object): method __init__ (line 63) | def __init__(self): function batch_indices (line 76) | def batch_indices(batch_nb, data_length, batch_size): function other_classes (line 98) | def other_classes(nb_classes, class_ind): function to_categorical (line 115) | def to_categorical(y, nb_classes, num_classes=None): function random_targets (line 144) | def random_targets(gt, nb_classes): function pair_visual (line 184) | def pair_visual(*args, **kwargs): function grid_visual (line 196) | def grid_visual(*args, **kwargs): function get_logits_over_interval (line 208) | def get_logits_over_interval(*args, **kwargs): function linear_extrapolation_plot (line 224) | def linear_extrapolation_plot(*args, **kwargs): function set_log_level (line 240) | def set_log_level(level, name="cleverhans"): function get_log_level (line 250) | def get_log_level(name="cleverhans"): class TemporaryLogLevel (line 258) | class TemporaryLogLevel(object): method __init__ (line 267) | def __init__(self, level, name): method __enter__ (line 271) | def __enter__(self): method __exit__ (line 275) | def __exit__(self, type, value, traceback): function create_logger (line 280) | def create_logger(name): function deterministic_dict (line 299) | def deterministic_dict(normal_dict): function ordered_union (line 309) | def ordered_union(l1, l2): function safe_zip (line 325) | def safe_zip(*args): function shell_call (line 339) | def shell_call(command, **kwargs): function deep_copy (line 377) | def deep_copy(numpy_dict): FILE: cleverhans_v3.1.0/cleverhans/attack_bundling.py function single_run_max_confidence_recipe (line 43) | def single_run_max_confidence_recipe( function basic_max_confidence_recipe (line 130) | def basic_max_confidence_recipe( function fixed_max_confidence_recipe (line 215) | def fixed_max_confidence_recipe( function random_search_max_confidence_recipe (line 302) | def random_search_max_confidence_recipe( class AttackConfig (line 346) | class AttackConfig(object): method __init__ (line 355) | def __init__(self, attack, params=None, name=None, pass_y=False): method __str__ (line 365) | def __str__(self): method __repr__ (line 370) | def __repr__(self): function bundle_attacks (line 374) | def bundle_attacks( function bundle_attacks_with_goal (line 461) | def bundle_attacks_with_goal( function run_batch_with_goal (line 524) | def run_batch_with_goal( function save (line 606) | def save(criteria, report, report_path, adv_x_val): class AttackGoal (line 624) | class AttackGoal(object): method start (line 640) | def start(self, run_counts): method get_criteria (line 648) | def get_criteria(self, sess, model, advx, y, batch_size=BATCH_SIZE): method extra_criteria (line 673) | def extra_criteria(self): method request_examples (line 680) | def request_examples(self, attack_config, criteria, run_counts, batch_... method is_satisfied (line 688) | def is_satisfied(self, criteria, run_counts): method print_progress (line 694) | def print_progress(self, criteria, run_counts): method get_attack_config (line 703) | def get_attack_config(self, attack_configs, run_counts, criteria): method new_wins (line 711) | def new_wins(self, orig_criteria, orig_idx, new_criteria, new_idx): class Misclassify (line 727) | class Misclassify(AttackGoal): method __init__ (line 749) | def __init__(self, new_work_goal=None, break_ties="wrong_confidence"): method start (line 757) | def start(self, run_counts): method is_satisfied (line 764) | def is_satisfied(self, criteria, run_counts): method print_progress (line 786) | def print_progress(self, criteria, run_counts): method filter (line 815) | def filter(self, run_counts, criteria): method get_attack_config (line 826) | def get_attack_config(self, attack_configs, run_counts, criteria): method extra_criteria (line 836) | def extra_criteria(self): method request_examples (line 842) | def request_examples(self, attack_config, criteria, run_counts, batch_... method new_wins (line 873) | def new_wins(self, orig_criteria, orig_idx, new_criteria, new_idx): class MaxConfidence (line 889) | class MaxConfidence(AttackGoal): method __init__ (line 915) | def __init__(self, t=1.0, new_work_goal=None): method filter (line 925) | def filter(self, run_counts, criteria): method extra_criteria (line 936) | def extra_criteria(self): method is_satisfied (line 939) | def is_satisfied(self, criteria, run_counts): method print_progress (line 959) | def print_progress(self, criteria, run_counts): method get_attack_config (line 991) | def get_attack_config(self, attack_configs, run_counts, criteria): method start (line 1002) | def start(self, run_counts): method request_examples (line 1018) | def request_examples(self, attack_config, criteria, run_counts, batch_... method new_wins (line 1047) | def new_wins(self, orig_criteria, orig_idx, new_criteria, new_idx): function unfinished_attack_configs (line 1053) | def unfinished_attack_configs(new_work_goal, work_before, run_counts, lo... class _CriteriaFactory (line 1101) | class _CriteriaFactory(object): method __init__ (line 1106) | def __init__(self, model, extra_criteria_factory=None): method __hash__ (line 1116) | def __hash__(self): method __eq__ (line 1121) | def __eq__(self, other): method __call__ (line 1130) | def __call__(self): class _ExtraCriteriaFactory (line 1148) | class _ExtraCriteriaFactory(object): method __init__ (line 1153) | def __init__(self, properties_to_hash=None): method __hash__ (line 1156) | def __hash__(self): method __eq__ (line 1161) | def __eq__(self, other): method __call__ (line 1168) | def __call__(self, x_batch, y_batch, predictions, correct, max_probs): class _WrongConfidenceFactory (line 1172) | class _WrongConfidenceFactory(_ExtraCriteriaFactory): method __call__ (line 1173) | def __call__(self, x_batch, y_batch, predictions, correct, max_probs): function bundle_examples_with_goal (line 1178) | def bundle_examples_with_goal( function spsa_max_confidence_recipe (line 1252) | def spsa_max_confidence_recipe( FILE: cleverhans_v3.1.0/cleverhans/attacks/attack.py class Attack (line 19) | class Attack(object): method __init__ (line 26) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 87) | def generate(self, x, **kwargs): method construct_graph (line 121) | def construct_graph(self, fixed, feedable, x_val, hash_key): method generate_np (line 178) | def generate_np(self, x_val, **kwargs): method construct_variables (line 212) | def construct_variables(self, kwargs): method get_or_guess_labels (line 275) | def get_or_guess_labels(self, x, kwargs): method parse_params (line 304) | def parse_params(self, params=None): function arg_type (line 320) | def arg_type(arg_names, kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks/basic_iterative_method.py class BasicIterativeMethod (line 8) | class BasicIterativeMethod(ProjectedGradientDescent): method __init__ (line 13) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks/carlini_wagner_l2.py class CarliniWagnerL2 (line 21) | class CarliniWagnerL2(Attack): method __init__ (line 39) | def __init__(self, model, sess, dtypestr="float32", **kwargs): method generate (line 65) | def generate(self, x, **kwargs): method parse_params (line 105) | def parse_params( function ZERO (line 166) | def ZERO(): class CWL2 (line 170) | class CWL2(object): method __init__ (line 171) | def __init__( method attack (line 308) | def attack(self, imgs, targets): method attack_batch (line 326) | def attack_batch(self, imgs, labs): FILE: cleverhans_v3.1.0/cleverhans/attacks/deep_fool.py class DeepFool (line 22) | class DeepFool(Attack): method __init__ (line 35) | def __init__(self, model, sess, dtypestr="float32", **kwargs): method generate (line 53) | def generate(self, x, **kwargs): method parse_params (line 102) | def parse_params( function deepfool_batch (line 135) | def deepfool_batch( function deepfool_attack (line 191) | def deepfool_attack( FILE: cleverhans_v3.1.0/cleverhans/attacks/elastic_net_method.py function ZERO (line 21) | def ZERO(): class ElasticNetMethod (line 25) | class ElasticNetMethod(Attack): method __init__ (line 41) | def __init__(self, model, sess, dtypestr="float32", **kwargs): method generate (line 69) | def generate(self, x, **kwargs): method parse_params (line 111) | def parse_params( class EAD (line 187) | class EAD(object): method __init__ (line 188) | def __init__( method attack (line 410) | def attack(self, imgs, targets): method attack_batch (line 443) | def attack_batch(self, imgs, labs): FILE: cleverhans_v3.1.0/cleverhans/attacks/fast_feature_adversaries.py class FastFeatureAdversaries (line 16) | class FastFeatureAdversaries(Attack): method __init__ (line 33) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method parse_params (line 43) | def parse_params( method attack_single_step (line 90) | def attack_single_step(self, x, eta, g_feat): method generate (line 133) | def generate(self, x, g, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks/fast_gradient_method.py class FastGradientMethod (line 15) | class FastGradientMethod(Attack): method __init__ (line 29) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 40) | def generate(self, x, **kwargs): method parse_params (line 66) | def parse_params( function fgm (line 136) | def fgm( function optimize_linear (line 224) | def optimize_linear(grad, eps, ord=np.inf): FILE: cleverhans_v3.1.0/cleverhans/attacks/hop_skip_jump_attack.py class HopSkipJumpAttack (line 18) | class HopSkipJumpAttack(Attack): method __init__ (line 35) | def __init__(self, model, sess, dtypestr="float32", **kwargs): method generate (line 61) | def generate(self, x, **kwargs): method generate_np (line 127) | def generate_np(self, x, **kwargs): method parse_params (line 165) | def parse_params( method _hsja (line 221) | def _hsja(self, sample, target_label, target_image): function BoundaryAttackPlusPlus (line 374) | def BoundaryAttackPlusPlus(model, sess, dtypestr="float32", **kwargs): function _check_first_dimension (line 384) | def _check_first_dimension(x, tensor_name): function clip_image (line 394) | def clip_image(image, clip_min, clip_max): function compute_distance (line 399) | def compute_distance(x_ori, x_pert, constraint="l2"): function approximate_gradient (line 408) | def approximate_gradient( function project (line 445) | def project(original_image, perturbed_images, alphas, shape, constraint): function binary_search_batch (line 458) | def binary_search_batch( function initialize (line 509) | def initialize(decision_function, sample, shape, clip_min, clip_max): function geometric_progression_for_stepsize (line 544) | def geometric_progression_for_stepsize( function select_delta (line 563) | def select_delta( FILE: cleverhans_v3.1.0/cleverhans/attacks/lbfgs.py class LBFGS (line 17) | class LBFGS(Attack): method __init__ (line 28) | def __init__(self, model, sess, dtypestr="float32", **kwargs): method generate (line 45) | def generate(self, x, **kwargs): method parse_params (line 90) | def parse_params( class LBFGS_impl (line 124) | class LBFGS_impl(object): method __init__ (line 146) | def __init__( method attack (line 194) | def attack(self, x_val, targets): FILE: cleverhans_v3.1.0/cleverhans/attacks/madry_et_al.py class MadryEtAl (line 8) | class MadryEtAl(ProjectedGradientDescent): method __init__ (line 13) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks/max_confidence.py class MaxConfidence (line 12) | class MaxConfidence(Attack): method __init__ (line 28) | def __init__(self, model, sess=None, base_attacker=None): method generate (line 42) | def generate(self, x, **kwargs): method parse_params (line 56) | def parse_params(self, y=None, nb_classes=10, **kwargs): method attack (line 66) | def attack(self, x, true_y): method attack_class (line 114) | def attack_class(self, x, target_y): FILE: cleverhans_v3.1.0/cleverhans/attacks/momentum_iterative_method.py class MomentumIterativeMethod (line 15) | class MomentumIterativeMethod(Attack): method __init__ (line 29) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 53) | def generate(self, x, **kwargs): method parse_params (line 141) | def parse_params( FILE: cleverhans_v3.1.0/cleverhans/attacks/noise.py class Noise (line 12) | class Noise(Attack): method __init__ (line 31) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 37) | def generate(self, x, **kwargs): method parse_params (line 57) | def parse_params(self, eps=0.3, ord=np.inf, clip_min=None, clip_max=No... FILE: cleverhans_v3.1.0/cleverhans/attacks/projected_gradient_descent.py class ProjectedGradientDescent (line 17) | class ProjectedGradientDescent(Attack): method __init__ (line 34) | def __init__( method generate (line 64) | def generate(self, x, **kwargs): method parse_params (line 202) | def parse_params( FILE: cleverhans_v3.1.0/cleverhans/attacks/saliency_map_method.py class SaliencyMapMethod (line 16) | class SaliencyMapMethod(Attack): method __init__ (line 30) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 48) | def generate(self, x, **kwargs): method parse_params (line 97) | def parse_params( function jsma_batch (line 135) | def jsma_batch(*args, **kwargs): function jsma_symbolic (line 141) | def jsma_symbolic(x, y_target, model, theta, gamma, clip_min, clip_max): FILE: cleverhans_v3.1.0/cleverhans/attacks/semantic.py class Semantic (line 7) | class Semantic(Attack): method __init__ (line 27) | def __init__( method generate (line 37) | def generate(self, x, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks/sparse_l1_descent.py class SparseL1Descent (line 16) | class SparseL1Descent(Attack): method __init__ (line 36) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 57) | def generate(self, x, **kwargs): method parse_params (line 170) | def parse_params( function sparse_l1_descent (line 259) | def sparse_l1_descent( FILE: cleverhans_v3.1.0/cleverhans/attacks/spatial_transformation_method.py class SpatialTransformationMethod (line 8) | class SpatialTransformationMethod(Attack): method __init__ (line 13) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 42) | def generate(self, x, **kwargs): method parse_params (line 72) | def parse_params( FILE: cleverhans_v3.1.0/cleverhans/attacks/spsa.py class SPSA (line 19) | class SPSA(Attack): method __init__ (line 37) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 52) | def generate( method generate_np (line 196) | def generate_np(self, x_val, **kwargs): function _project_perturbation (line 227) | def _project_perturbation( class TensorOptimizer (line 258) | class TensorOptimizer(object): method _compute_gradients (line 270) | def _compute_gradients(self, loss_fn, x, unused_optim_state): method _apply_gradients (line 297) | def _apply_gradients(self, grads, x, optim_state): method minimize (line 311) | def minimize(self, loss_fn, x, optim_state): method init_state (line 326) | def init_state(self, x): class TensorGradientDescent (line 338) | class TensorGradientDescent(TensorOptimizer): method __init__ (line 341) | def __init__(self, lr): method init_state (line 344) | def init_state(self, x): method _apply_gradients (line 347) | def _apply_gradients(self, grads, x, optim_state): class TensorAdam (line 354) | class TensorAdam(TensorOptimizer): method __init__ (line 357) | def __init__(self, lr=0.001, beta1=0.9, beta2=0.999, epsilon=1e-9): method init_state (line 363) | def init_state(self, x): method _apply_gradients (line 373) | def _apply_gradients(self, grads, x, optim_state): class SPSAAdam (line 394) | class SPSAAdam(TensorAdam): method __init__ (line 401) | def __init__( method _get_delta (line 416) | def _get_delta(self, x, delta): method _compute_gradients (line 428) | def _compute_gradients(self, loss_fn, x, unused_optim_state): function margin_logit_loss (line 467) | def margin_logit_loss(model_logits, label, nb_classes=10, num_classes=No... function _apply_black_border (line 503) | def _apply_black_border(x, border_size): function _apply_transformation (line 517) | def _apply_transformation(inputs): function spm (line 548) | def spm( function parallel_apply_transformations (line 619) | def parallel_apply_transformations(x, transforms, black_border_size=0): function projected_optimization (line 648) | def projected_optimization( FILE: cleverhans_v3.1.0/cleverhans/attacks/virtual_adversarial_method.py class VirtualAdversarialMethod (line 17) | class VirtualAdversarialMethod(Attack): method __init__ (line 29) | def __init__(self, model, sess=None, dtypestr="float32", **kwargs): method generate (line 43) | def generate(self, x, **kwargs): method parse_params (line 64) | def parse_params( function vatm (line 113) | def vatm( FILE: cleverhans_v3.1.0/cleverhans/attacks_tf.py function fgsm (line 61) | def fgsm(x, predictions, eps=0.3, clip_min=None, clip_max=None): function fgm (line 77) | def fgm(x, preds, *args, **kwargs): function apply_perturbations (line 91) | def apply_perturbations(i, j, X, increase, theta, clip_min, clip_max): function saliency_map (line 119) | def saliency_map(grads_target, grads_other, search_domain, increase): function jacobian (line 171) | def jacobian(sess, x, grads, target, X, nb_features, nb_classes, feed=No... class UnrolledOptimizer (line 206) | class UnrolledOptimizer(TensorOptimizer): method __init__ (line 207) | def __init__(self, *args, **kwargs): class UnrolledGradientDescent (line 215) | class UnrolledGradientDescent(TensorGradientDescent): method __init__ (line 216) | def __init__(self, *args, **kwargs): class UnrolledAdam (line 225) | class UnrolledAdam(TensorAdam): method __init__ (line 226) | def __init__(self, *args, **kwargs): function pgd_attack (line 234) | def pgd_attack(*args, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/attacks_tfe.py class Attack (line 23) | class Attack(attacks.Attack): method __init__ (line 32) | def __init__(self, model, dtypestr="float32"): method construct_graph (line 49) | def construct_graph(self, **kwargs): method generate_np (line 58) | def generate_np(self, x_val, **kwargs): method construct_variables (line 71) | def construct_variables(self, kwargs): class FastGradientMethod (line 81) | class FastGradientMethod(Attack, attacks.FastGradientMethod): method __init__ (line 92) | def __init__(self, model, dtypestr="float32", **kwargs): method generate (line 105) | def generate(self, x, **kwargs): method fgm (line 129) | def fgm(self, x, labels, targeted=False): class BasicIterativeMethod (line 163) | class BasicIterativeMethod(Attack, attacks.BasicIterativeMethod): method __init__ (line 174) | def __init__(self, model, dtypestr="float32"): FILE: cleverhans_v3.1.0/cleverhans/augmentation.py function random_shift (line 19) | def random_shift(x, pad=(4, 4), mode="REFLECT"): function batch_augment (line 28) | def batch_augment(x, func, device="/CPU:0"): function random_crop_and_flip (line 40) | def random_crop_and_flip(x, pad_rows=4, pad_cols=4): FILE: cleverhans_v3.1.0/cleverhans/canary.py function run_canary (line 13) | def run_canary(): FILE: cleverhans_v3.1.0/cleverhans/compat.py function _wrap (line 21) | def _wrap(f): function reduce_function (line 49) | def reduce_function( function softmax_cross_entropy_with_logits (line 80) | def softmax_cross_entropy_with_logits(sentinel=None, labels=None, logits... FILE: cleverhans_v3.1.0/cleverhans/confidence_report.py class ConfidenceReport (line 52) | class ConfidenceReport(OrderedDict): method __init__ (line 63) | def __init__(self, iterable=None): method __setitem__ (line 76) | def __setitem__(self, key, value): class ConfidenceReportEntry (line 88) | class ConfidenceReportEntry(object): method __init__ (line 99) | def __init__(self, correctness, confidence): method __getitem__ (line 112) | def __getitem__(self, key): method __setitem__ (line 123) | def __setitem__(self, key, value): function make_confidence_report_bundled (line 135) | def make_confidence_report_bundled( function print_stats (line 279) | def print_stats(correctness, confidence, name): function make_confidence_report (line 314) | def make_confidence_report( FILE: cleverhans_v3.1.0/cleverhans/dataset.py class Dataset (line 42) | class Dataset(object): method __init__ (line 48) | def __init__(self, kwargs=None): method get_factory (line 55) | def get_factory(self): method get_set (line 60) | def get_set(self, which_set): method to_tensorflow (line 66) | def to_tensorflow(self): method in_memory_dataset (line 70) | def in_memory_dataset(cls, x, y, shuffle=None, repeat=True): class MNIST (line 85) | class MNIST(Dataset): method __init__ (line 90) | def __init__( method to_tensorflow (line 121) | def to_tensorflow(self, shuffle=4096): class CIFAR10 (line 128) | class CIFAR10(Dataset): method __init__ (line 146) | def __init__( method to_tensorflow (line 179) | def to_tensorflow(self, shuffle=4096): class Factory (line 187) | class Factory(object): method __init__ (line 192) | def __init__(self, cls, kwargs): method __call__ (line 196) | def __call__(self): function maybe_download_file (line 201) | def maybe_download_file(url, datadir=None, force=False): function download_and_parse_mnist_file (line 219) | def download_and_parse_mnist_file(file_name, datadir=None, force=False): function data_mnist (line 261) | def data_mnist( function data_cifar10 (line 310) | def data_cifar10(train_start=0, train_end=50000, test_start=0, test_end=... FILE: cleverhans_v3.1.0/cleverhans/devtools/checks.py class CleverHansTest (line 17) | class CleverHansTest(unittest.TestCase): method setUp (line 20) | def setUp(self): method tearDown (line 25) | def tearDown(self): method assertClose (line 28) | def assertClose(self, x, y, *args, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/devtools/list_files.py function list_files (line 6) | def list_files(suffix=""): function _list_files (line 47) | def _list_files(path, suffix=""): FILE: cleverhans_v3.1.0/cleverhans/devtools/mocks.py function random_feed_dict (line 16) | def random_feed_dict(rng, placeholders): class SimpleDataset (line 35) | class SimpleDataset(Dataset): method __init__ (line 41) | def __init__( FILE: cleverhans_v3.1.0/cleverhans/devtools/tests/test_format.py function update_whitelist (line 24) | def update_whitelist(): function test_format_pep8 (line 84) | def test_format_pep8(): FILE: cleverhans_v3.1.0/cleverhans/devtools/version.py function dev_version (line 11) | def dev_version(): function append_dev_version (line 27) | def append_dev_version(release_version): FILE: cleverhans_v3.1.0/cleverhans/evaluation.py function accuracy (line 18) | def accuracy( function class_and_confidence (line 72) | def class_and_confidence( function correctness_and_confidence (line 149) | def correctness_and_confidence( function run_attack (line 222) | def run_attack( function batch_eval_multi_worker (line 273) | def batch_eval_multi_worker( function batch_eval (line 468) | def batch_eval( class _CorrectFactory (line 549) | class _CorrectFactory(object): method __init__ (line 555) | def __init__(self, model, attack=None, attack_params=None): method __hash__ (line 566) | def __hash__(self): method __eq__ (line 571) | def __eq__(self, other): method __call__ (line 578) | def __call__(self): class _ClassAndProbFactory (line 599) | class _ClassAndProbFactory(object): method __init__ (line 607) | def __init__(self, model, attack=None, attack_params=None): method __hash__ (line 618) | def __hash__(self): method __eq__ (line 623) | def __eq__(self, other): method __call__ (line 630) | def __call__(self): class _CorrectAndProbFactory (line 654) | class _CorrectAndProbFactory(object): method __init__ (line 662) | def __init__(self, model, attack=None, attack_params=None): method __hash__ (line 673) | def __hash__(self): method __eq__ (line 678) | def __eq__(self, other): method __call__ (line 685) | def __call__(self): class _AttackFactory (line 707) | class _AttackFactory(object): method __init__ (line 719) | def __init__(self, model, attack, attack_params=None, pass_y=False): method __hash__ (line 738) | def __hash__(self): method __eq__ (line 743) | def __eq__(self, other): method __call__ (line 750) | def __call__(self): function _check_x (line 775) | def _check_x(x): function _check_y (line 786) | def _check_y(y): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/certify.py function main (line 82) | def main(_): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/dual_formulation.py class DualFormulation (line 29) | class DualFormulation(object): method __init__ (line 35) | def __init__( method create_projected_dual (line 184) | def create_projected_dual(self): method construct_lanczos_params (line 238) | def construct_lanczos_params(self): method set_differentiable_objective (line 291) | def set_differentiable_objective(self): method get_h_product (line 354) | def get_h_product(self, vector, dtype=None): method get_psd_product (line 416) | def get_psd_product(self, vector, dtype=None): method get_full_psd_matrix (line 445) | def get_full_psd_matrix(self): method make_m_psd (line 499) | def make_m_psd(self, original_nu, feed_dictionary): method get_lanczos_eig (line 538) | def get_lanczos_eig(self, compute_m=True, feed_dict=None): method compute_certificate (line 561) | def compute_certificate(self, current_step, feed_dictionary): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/nn.py class NeuralNetwork (line 15) | class NeuralNetwork(object): method __init__ (line 20) | def __init__( method forward_pass (line 132) | def forward_pass(self, vector, layer_index, is_transpose=False, is_abs... function load_network_from_checkpoint (line 195) | def load_network_from_checkpoint(checkpoint, model_json, input_shape=None): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/optimization.py class Optimization (line 21) | class Optimization(object): method __init__ (line 24) | def __init__(self, dual_formulation_object, sess, optimization_params): method tf_min_eig_vec (line 58) | def tf_min_eig_vec(self): method tf_smooth_eig_vec (line 66) | def tf_smooth_eig_vec(self): method get_min_eig_vec_proxy (line 84) | def get_min_eig_vec_proxy(self, use_tf_eig=False): method get_scipy_eig_vec (line 117) | def get_scipy_eig_vec(self): method prepare_for_optimization (line 151) | def prepare_for_optimization(self): method run_one_step (line 257) | def run_one_step( method run_optimization (line 363) | def run_optimization(self): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/tests/dual_formulation_test.py class DualFormulationTest (line 16) | class DualFormulationTest(unittest.TestCase): method test_init (line 17) | def test_init(self): method test_set_differentiable_objective (line 62) | def test_set_differentiable_objective(self): method test_get_full_psd_matrix (line 112) | def test_get_full_psd_matrix(self): method test_get_psd_product (line 159) | def test_get_psd_product(self): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/tests/nn_test.py class NeuralNetworkTest (line 15) | class NeuralNetworkTest(unittest.TestCase): method test_init (line 16) | def test_init(self): method test_forward_pass (line 38) | def test_forward_pass(self): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/tests/optimization_test.py class OptimizationTest (line 15) | class OptimizationTest(tf.test.TestCase): method prepare_dual_object (line 18) | def prepare_dual_object(self): method test_init (line 100) | def test_init(self): method test_get_min_eig_vec_proxy (line 122) | def test_get_min_eig_vec_proxy(self): method test_optimization (line 198) | def test_optimization(self): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/tests/utils_test.py class UtilsTest (line 20) | class UtilsTest(tf.test.TestCase): method test_minimum_eigen_vector (line 21) | def test_minimum_eigen_vector(self): method test_tf_lanczos_smallest_eigval (line 37) | def test_tf_lanczos_smallest_eigval(self): FILE: cleverhans_v3.1.0/cleverhans/experimental/certification/utils.py function diag (line 11) | def diag(diag_elements): function initialize_dual (line 23) | def initialize_dual( function eig_one_step (line 138) | def eig_one_step(current_vector, learning_rate, vector_prod_fn): function minimum_eigen_vector (line 206) | def minimum_eigen_vector(x, num_steps, learning_rate, vector_prod_fn): function tf_lanczos_smallest_eigval (line 228) | def tf_lanczos_smallest_eigval( FILE: cleverhans_v3.1.0/cleverhans/initializers.py class HeReLuNormalInitializer (line 8) | class HeReLuNormalInitializer(tf.initializers.random_normal): method __init__ (line 13) | def __init__(self, dtype=tf.float32): method get_config (line 16) | def get_config(self): method __call__ (line 19) | def __call__(self, shape, dtype=None, partition_info=None): FILE: cleverhans_v3.1.0/cleverhans/loss.py class Loss (line 23) | class Loss(object): method __init__ (line 30) | def __init__(self, model, hparams=None, attack=None): method save (line 69) | def save(self, path): method fprop (line 76) | def fprop(self, x, y): class WeightedSum (line 89) | class WeightedSum(Loss): method __init__ (line 94) | def __init__(self, model, terms): method fprop (line 99) | def fprop(self, x, y, **kwargs): class CrossEntropy (line 122) | class CrossEntropy(Loss): method __init__ (line 135) | def __init__( method fprop (line 154) | def fprop(self, x, y, **kwargs): class MixUp (line 187) | class MixUp(Loss): method __init__ (line 193) | def __init__(self, model, beta, **kwargs): method fprop (line 198) | def fprop(self, x, y, **kwargs): class FeaturePairing (line 214) | class FeaturePairing(Loss): method __init__ (line 221) | def __init__(self, model, weight, attack, **kwargs): method fprop (line 226) | def fprop(self, x, y, **kwargs): class WeightDecay (line 244) | class WeightDecay(Loss): method fprop (line 247) | def fprop(self, x, y, **kwargs): class LossCrossEntropy (line 258) | class LossCrossEntropy(Loss): method __init__ (line 264) | def __init__(self, model, smoothing=0.0, attack=None, **kwargs): method fprop (line 276) | def fprop(self, x, y, **kwargs): class LossFeaturePairing (line 301) | class LossFeaturePairing(Loss): method __init__ (line 305) | def __init__(self, model, weight, attack, **kwargs): method fprop (line 315) | def fprop(self, x, y, **kwargs): class LossMixUp (line 334) | class LossMixUp(Loss): method __init__ (line 338) | def __init__(self, model, beta, **kwargs): method fprop (line 347) | def fprop(self, x, y, **kwargs): class SNNLCrossEntropy (line 362) | class SNNLCrossEntropy(CrossEntropy): method __init__ (line 371) | def __init__( method pairwise_euclid_distance (line 402) | def pairwise_euclid_distance(A, B): method pairwise_cos_distance (line 421) | def pairwise_cos_distance(A, B): method fits (line 434) | def fits(A, B, temp, cos_distance): method pick_probability (line 452) | def pick_probability(x, temp, cos_distance): method same_label_mask (line 469) | def same_label_mask(y, y2): method masked_pick_probability (line 479) | def masked_pick_probability(x, y, temp, cos_distance): method SNNL (line 494) | def SNNL(x, y, temp, cos_distance): method optimized_temp_SNNL (line 512) | def optimized_temp_SNNL(x, y, initial_temp, cos_distance): method fprop (line 536) | def fprop(self, x, y, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/model.py class Model (line 12) | class Model(object): method __init__ (line 24) | def __init__( method __call__ (line 40) | def __call__(self, *args, **kwargs): method get_logits (line 63) | def get_logits(self, x, **kwargs): method get_predicted_class (line 77) | def get_predicted_class(self, x, **kwargs): method get_probs (line 84) | def get_probs(self, x, **kwargs): method fprop (line 107) | def fprop(self, x, **kwargs): method get_params (line 116) | def get_params(self): method make_params (line 160) | def make_params(self): method get_layer_names (line 174) | def get_layer_names(self): method get_layer (line 178) | def get_layer(self, x, layer, **kwargs): method make_input_placeholder (line 187) | def make_input_placeholder(self): method make_label_placeholder (line 199) | def make_label_placeholder(self): method __hash__ (line 211) | def __hash__(self): method __eq__ (line 214) | def __eq__(self, other): class CallableModelWrapper (line 218) | class CallableModelWrapper(Model): method __init__ (line 221) | def __init__(self, callable_fn, output_layer): method fprop (line 235) | def fprop(self, x, **kwargs): function wrapper_warning (line 256) | def wrapper_warning(): function wrapper_warning_logits (line 282) | def wrapper_warning_logits(): class NoSuchLayerError (line 303) | class NoSuchLayerError(ValueError): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/all_convolutional.py class ModelAllConvolutional (line 11) | class ModelAllConvolutional(NoRefModel): method __init__ (line 17) | def __init__(self, scope, nb_classes, nb_filters, input_shape, **kwargs): method fprop (line 28) | def fprop(self, x, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/basic_cnn.py class ModelBasicCNN (line 18) | class ModelBasicCNN(Model): method __init__ (line 19) | def __init__(self, scope, nb_classes, nb_filters, **kwargs): method fprop (line 30) | def fprop(self, x, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/deep_k_nearest_neighbors/dknn.py function make_basic_picklable_cnn (line 39) | def make_basic_picklable_cnn( class NearestNeighbor (line 58) | class NearestNeighbor: class BACKEND (line 59) | class BACKEND(enum.Enum): method __init__ (line 63) | def __init__( method _init_falconn (line 85) | def _init_falconn( method _init_faiss (line 117) | def _init_faiss( method _find_knns_falconn (line 130) | def _find_knns_falconn(self, x, output): method _find_knns_faiss (line 154) | def _find_knns_faiss(self, x, output): method add (line 167) | def add(self, x): method find_knns (line 175) | def find_knns(self, x, output): class DkNNModel (line 184) | class DkNNModel(Model): method __init__ (line 185) | def __init__( method init_lsh (line 229) | def init_lsh(self): method find_train_knns (line 261) | def find_train_knns(self, data_activations): method nonconformity (line 304) | def nonconformity(self, knns_labels): method preds_conf_cred (line 329) | def preds_conf_cred(self, knns_not_in_class): method fprop_np (line 357) | def fprop_np(self, data_np): method fprop (line 371) | def fprop(self, x): method calibrate (line 379) | def calibrate(self, cali_data, cali_labels): function plot_reliability_diagram (line 412) | def plot_reliability_diagram(confidence, labels, filepath): function get_tensorflow_session (line 482) | def get_tensorflow_session(): function dknn_tutorial (line 490) | def dknn_tutorial(): function main (line 598) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/madry_lab_challenges/cifar10_model.py class Layer (line 19) | class Layer(object): method get_output_shape (line 20) | def get_output_shape(self): class ResNet (line 24) | class ResNet(NoRefModel): method __init__ (line 27) | def __init__(self, layers, input_shape, scope=None): method get_vars (line 55) | def get_vars(self): method build (line 60) | def build(self, layers, input_shape): method make_input_placeholder (line 80) | def make_input_placeholder(self): method make_label_placeholder (line 83) | def make_label_placeholder(self): method fprop (line 86) | def fprop(self, x, set_ref=False): method _fprop (line 92) | def _fprop(self, x, set_ref=False): method add_internal_summaries (line 103) | def add_internal_summaries(self): function _stride_arr (line 107) | def _stride_arr(stride): class Input (line 112) | class Input(Layer): method __init__ (line 113) | def __init__(self): method set_input_shape (line 116) | def set_input_shape(self, input_shape): method fprop (line 128) | def fprop(self, x): class Conv2D (line 136) | class Conv2D(Layer): method __init__ (line 137) | def __init__(self): method set_input_shape (line 140) | def set_input_shape(self, input_shape): method fprop (line 155) | def fprop(self, x): class Linear (line 206) | class Linear(Layer): method __init__ (line 207) | def __init__(self, num_hid): method set_input_shape (line 210) | def set_input_shape(self, input_shape): method make_vars (line 217) | def make_vars(self): method fprop (line 229) | def fprop(self, x): function _batch_norm (line 234) | def _batch_norm(name, x): function _residual (line 248) | def _residual(x, in_filter, out_filter, stride, activate_before_residual... function _decay (line 287) | def _decay(): function _conv (line 296) | def _conv(name, x, filter_size, in_filters, out_filters, strides): function _relu (line 309) | def _relu(x, leakiness=0.0): function _global_avg_pool (line 314) | def _global_avg_pool(x): class Softmax (line 319) | class Softmax(Layer): method __init__ (line 320) | def __init__(self): method set_input_shape (line 323) | def set_input_shape(self, shape): method fprop (line 327) | def fprop(self, x): class Flatten (line 331) | class Flatten(Layer): method __init__ (line 332) | def __init__(self): method set_input_shape (line 335) | def set_input_shape(self, shape): method fprop (line 343) | def fprop(self, x): function make_wresnet (line 347) | def make_wresnet(nb_classes=10, input_shape=(None, 32, 32, 3), scope=None): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/madry_lab_challenges/make_cifar10_joblib.py function main (line 27) | def main(argv): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/soft_nearest_neighbor_loss/SNNL_regularized_model.py class ModelBasicCNN (line 18) | class ModelBasicCNN(Model): method __init__ (line 19) | def __init__(self, scope, nb_classes, nb_filters, **kwargs): method make_input_placeholder (line 28) | def make_input_placeholder(self): method get_layer_names (line 31) | def get_layer_names(self): method fprop (line 34) | def fprop(self, x, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/model_zoo/soft_nearest_neighbor_loss/SNNL_regularized_train.py function SNNL_example (line 39) | def SNNL_example( function main (line 175) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans/picklable_model.py class PicklableModel (line 25) | class PicklableModel(Model): method __init__ (line 37) | def __init__(self): method get_params (line 41) | def get_params(self): class MLP (line 47) | class MLP(PicklableModel): method __hash__ (line 52) | def __hash__(self): method __init__ (line 55) | def __init__(self, layers, input_shape): method get_params (line 89) | def get_params(self): method fprop (line 95) | def fprop(self, x=None, given=None, **kwargs): method make_input_placeholder (line 139) | def make_input_placeholder(self): method make_label_placeholder (line 142) | def make_label_placeholder(self): class Layer (line 149) | class Layer(PicklableModel): method __init__ (line 150) | def __init__(self, name=None, parent=None): method get_output_shape (line 156) | def get_output_shape(self): class Linear (line 160) | class Linear(Layer): method __init__ (line 170) | def __init__( method set_input_shape (line 186) | def set_input_shape(self, input_shape): method fprop (line 207) | def fprop(self, x, **kwargs): method get_params (line 213) | def get_params(self): class Conv2D (line 220) | class Conv2D(Layer): method __init__ (line 240) | def __init__( method set_input_shape (line 255) | def set_input_shape(self, input_shape): method fprop (line 291) | def fprop(self, x, **kwargs): method get_params (line 300) | def get_params(self): class ReLU (line 307) | class ReLU(Layer): method __init__ (line 308) | def __init__(self, leak=0.0, **kwargs): method set_input_shape (line 312) | def set_input_shape(self, shape): method get_output_shape (line 316) | def get_output_shape(self): method fprop (line 319) | def fprop(self, x, **kwargs): method get_params (line 339) | def get_params(self): class Sigmoid (line 343) | class Sigmoid(Layer): method __init__ (line 344) | def __init__(self, **kwargs): method set_input_shape (line 347) | def set_input_shape(self, shape): method get_output_shape (line 351) | def get_output_shape(self): method fprop (line 354) | def fprop(self, x, **kwargs): method get_params (line 357) | def get_params(self): class Tanh (line 361) | class Tanh(Layer): method __init__ (line 362) | def __init__(self, **kwargs): method set_input_shape (line 365) | def set_input_shape(self, shape): method get_output_shape (line 369) | def get_output_shape(self): method fprop (line 372) | def fprop(self, x, **kwargs): method get_params (line 375) | def get_params(self): class LeakyReLU (line 379) | class LeakyReLU(ReLU): method __init__ (line 380) | def __init__(self, leak=0.2, **kwargs): class ELU (line 384) | class ELU(Layer): method set_input_shape (line 385) | def set_input_shape(self, shape): method get_output_shape (line 389) | def get_output_shape(self): method fprop (line 392) | def fprop(self, x, **kwargs): method get_params (line 395) | def get_params(self): class SELU (line 399) | class SELU(Layer): method set_input_shape (line 400) | def set_input_shape(self, shape): method get_output_shape (line 404) | def get_output_shape(self): method fprop (line 407) | def fprop(self, x, **kwargs): method get_params (line 414) | def get_params(self): class TanH (line 418) | class TanH(Layer): method set_input_shape (line 419) | def set_input_shape(self, shape): method get_output_shape (line 423) | def get_output_shape(self): method fprop (line 426) | def fprop(self, x, **kwargs): class Softmax (line 430) | class Softmax(Layer): method set_input_shape (line 431) | def set_input_shape(self, shape): method fprop (line 435) | def fprop(self, x, **kwargs): method get_params (line 439) | def get_params(self): method make_label_placeholder (line 442) | def make_label_placeholder(self): class Flatten (line 446) | class Flatten(Layer): method set_input_shape (line 447) | def set_input_shape(self, shape): method fprop (line 455) | def fprop(self, x, **kwargs): method get_params (line 458) | def get_params(self): class Print (line 462) | class Print(Layer): method set_input_shape (line 463) | def set_input_shape(self, shape): method get_params (line 467) | def get_params(self): method fprop (line 470) | def fprop(self, x, **kwargs): class Add (line 478) | class Add(Layer): method __hash__ (line 486) | def __hash__(self): method set_input_shape (line 489) | def set_input_shape(self, shape): method __init__ (line 497) | def __init__(self, layers): method get_params (line 516) | def get_params(self): method fprop (line 522) | def fprop(self, x, **kwargs): class PerImageStandardize (line 554) | class PerImageStandardize(Layer): method set_input_shape (line 555) | def set_input_shape(self, shape): method get_params (line 559) | def get_params(self): method fprop (line 562) | def fprop(self, x, **kwargs): class Dropout (line 580) | class Dropout(Layer): method __init__ (line 607) | def __init__(self, include_prob=0.5, **kwargs): method set_input_shape (line 611) | def set_input_shape(self, shape): method get_params (line 615) | def get_params(self): method fprop (line 618) | def fprop(self, x, dropout=False, dropout_dict=None, **kwargs): class ResidualWithGroupNorm (line 644) | class ResidualWithGroupNorm(Layer): method __init__ (line 652) | def __init__( method set_input_shape (line 661) | def set_input_shape(self, shape): method get_params (line 689) | def get_params(self): method fprop (line 697) | def fprop(self, x, **kwargs): class GlobalAveragePool (line 729) | class GlobalAveragePool(Layer): method set_input_shape (line 730) | def set_input_shape(self, shape): method get_params (line 734) | def get_params(self): method fprop (line 737) | def fprop(self, x, **kwargs): class GroupNorm (line 742) | class GroupNorm(Layer): method __init__ (line 749) | def __init__(self, num_groups=32, eps=1e-3, init_gamma=1.0, **kwargs): method set_input_shape (line 755) | def set_input_shape(self, shape): method fprop (line 769) | def fprop(self, x, **kwargs): method get_params (line 779) | def get_params(self): class BatchNorm (line 783) | class BatchNorm(Layer): method __init__ (line 788) | def __init__(self, eps=1e-3, init_gamma=1.0, **kwargs): method set_input_shape (line 793) | def set_input_shape(self, shape): method fprop (line 801) | def fprop(self, x, **kwargs): method get_params (line 807) | def get_params(self): class ResidualWithBatchNorm (line 811) | class ResidualWithBatchNorm(Layer): method __init__ (line 819) | def __init__( method set_input_shape (line 828) | def set_input_shape(self, shape): method get_params (line 856) | def get_params(self): method fprop (line 864) | def fprop(self, x, **kwargs): FILE: cleverhans_v3.1.0/cleverhans/plot/image.py function show (line 14) | def show(ndarray, min_val=None, max_val=None): function save (line 33) | def save(path, ndarray, min_val=None, max_val=None): function as_pil (line 48) | def as_pil(ndarray, min_val=None, max_val=None): function make_grid (line 113) | def make_grid(image_batch): FILE: cleverhans_v3.1.0/cleverhans/plot/pyplot_image.py function pair_visual (line 10) | def pair_visual(original, adversarial, figure=None): function grid_visual (line 53) | def grid_visual(data): function get_logits_over_interval (line 86) | def get_logits_over_interval( function linear_extrapolation_plot (line 137) | def linear_extrapolation_plot( FILE: cleverhans_v3.1.0/cleverhans/plot/save_pdf.py function save_pdf (line 8) | def save_pdf(path): FILE: cleverhans_v3.1.0/cleverhans/plot/success_fail.py function plot_report_from_path (line 19) | def plot_report_from_path( function plot_report (line 69) | def plot_report( function make_curve (line 128) | def make_curve(report, success_name, fail_names): FILE: cleverhans_v3.1.0/cleverhans/serial.py class PicklableVariable (line 19) | class PicklableVariable(object): method __init__ (line 41) | def __init__(self, *args, **kwargs): method __getstate__ (line 44) | def __getstate__(self): method __setstate__ (line 52) | def __setstate__(self, d): class NoRefModel (line 62) | class NoRefModel(Model): method __getstate__ (line 78) | def __getstate__(self): method __setstate__ (line 97) | def __setstate__(self, d): method get_vars (line 153) | def get_vars(self): function save (line 202) | def save(filepath, obj): function load (line 215) | def load(filepath): FILE: cleverhans_v3.1.0/cleverhans/train.py function train (line 38) | def train( function avg_grads (line 301) | def avg_grads(tower_grads): FILE: cleverhans_v3.1.0/cleverhans/utils.py class _ArgsWrapper (line 40) | class _ArgsWrapper(object): method __init__ (line 46) | def __init__(self, args): method __getattr__ (line 51) | def __getattr__(self, name): class AccuracyReport (line 55) | class AccuracyReport(object): method __init__ (line 63) | def __init__(self): function batch_indices (line 76) | def batch_indices(batch_nb, data_length, batch_size): function other_classes (line 98) | def other_classes(nb_classes, class_ind): function to_categorical (line 115) | def to_categorical(y, nb_classes, num_classes=None): function random_targets (line 144) | def random_targets(gt, nb_classes): function pair_visual (line 184) | def pair_visual(*args, **kwargs): function grid_visual (line 196) | def grid_visual(*args, **kwargs): function get_logits_over_interval (line 208) | def get_logits_over_interval(*args, **kwargs): function linear_extrapolation_plot (line 224) | def linear_extrapolation_plot(*args, **kwargs): function set_log_level (line 240) | def set_log_level(level, name="cleverhans"): function get_log_level (line 250) | def get_log_level(name="cleverhans"): class TemporaryLogLevel (line 258) | class TemporaryLogLevel(object): method __init__ (line 267) | def __init__(self, level, name): method __enter__ (line 271) | def __enter__(self): method __exit__ (line 275) | def __exit__(self, type, value, traceback): function create_logger (line 280) | def create_logger(name): function deterministic_dict (line 299) | def deterministic_dict(normal_dict): function ordered_union (line 309) | def ordered_union(l1, l2): function safe_zip (line 325) | def safe_zip(*args): function shell_call (line 339) | def shell_call(command, **kwargs): function deep_copy (line 377) | def deep_copy(numpy_dict): FILE: cleverhans_v3.1.0/cleverhans/utils_keras.py function conv_2d (line 20) | def conv_2d(filters, kernel_shape, strides, padding, input_shape=None): function cnn_model (line 53) | def cnn_model( class KerasModelWrapper (line 110) | class KerasModelWrapper(Model): method __init__ (line 118) | def __init__(self, model): method _get_softmax_name (line 131) | def _get_softmax_name(self): method _get_abstract_layer_name (line 143) | def _get_abstract_layer_name(self): method _get_logits_name (line 156) | def _get_logits_name(self): method get_logits (line 180) | def get_logits(self, x): method get_probs (line 198) | def get_probs(self, x): method get_layer_names (line 207) | def get_layer_names(self): method fprop (line 214) | def fprop(self, x): method get_layer (line 258) | def get_layer(self, x, layer): FILE: cleverhans_v3.1.0/cleverhans/utils_mnist.py function maybe_download_mnist_file (line 20) | def maybe_download_mnist_file(file_name, datadir=None, force=False): function download_and_parse_mnist_file (line 26) | def download_and_parse_mnist_file(file_name, datadir=None, force=False): function data_mnist (line 31) | def data_mnist( FILE: cleverhans_v3.1.0/cleverhans/utils_pytorch.py function _py_func_with_gradient (line 14) | def _py_func_with_gradient(func, inp, Tout, stateful=True, name=None, gr... function convert_pytorch_model_to_tf (line 39) | def convert_pytorch_model_to_tf(model, out_dims=None): FILE: cleverhans_v3.1.0/cleverhans/utils_tf.py function model_loss (line 28) | def model_loss(y, model, mean=True): function initialize_uninitialized_global_variables (line 55) | def initialize_uninitialized_global_variables(sess): function train (line 79) | def train( function model_eval (line 220) | def model_eval(sess, x, y, predictions, X_test=None, Y_test=None, feed=N... function tf_model_load (line 294) | def tf_model_load(sess, file_path=None): function batch_eval (line 312) | def batch_eval(*args, **kwargs): function model_argmax (line 327) | def model_argmax(sess, x, predictions, samples, feed=None): function l2_batch_normalize (line 350) | def l2_batch_normalize(x, epsilon=1e-12, scope=None): function kl_with_logits (line 367) | def kl_with_logits( function clip_eta (line 380) | def clip_eta(eta, ord, eps): function zero_out_clipped_grads (line 443) | def zero_out_clipped_grads(grad, x, clip_min, clip_max): function random_exponential (line 468) | def random_exponential(shape, rate=1.0, dtype=tf.float32, seed=None): function random_laplace (line 481) | def random_laplace(shape, loc=0.0, scale=1.0, dtype=tf.float32, seed=None): function random_lp_vector (line 497) | def random_lp_vector(shape, ord, eps, dtype=tf.float32, seed=None): function model_train (line 547) | def model_train( function infer_devices (line 672) | def infer_devices(devices=None): function get_available_gpus (line 696) | def get_available_gpus(): function silence (line 704) | def silence(): function clip_by_value (line 711) | def clip_by_value(t, clip_value_min, clip_value_max, name=None): function mul (line 734) | def mul(a, b): function div (line 747) | def div(a, b): function op_with_scalar_cast (line 760) | def op_with_scalar_cast(a, b, f): function assert_less_equal (line 800) | def assert_less_equal(*args, **kwargs): function assert_greater_equal (line 810) | def assert_greater_equal(*args, **kwargs): function assert_equal (line 820) | def assert_equal(*args, **kwargs): function jacobian_graph (line 830) | def jacobian_graph(predictions, x, nb_classes): function jacobian_augmentation (line 851) | def jacobian_augmentation( FILE: cleverhans_v3.1.0/cleverhans/utils_tfe.py function train (line 24) | def train( function model_eval (line 135) | def model_eval( function model_argmax (line 207) | def model_argmax(model, samples): FILE: cleverhans_v3.1.0/cleverhans_tutorials/__init__.py function check_installation (line 13) | def check_installation(cur_file): FILE: cleverhans_v3.1.0/cleverhans_tutorials/cifar10_tutorial_tf.py function cifar10_tutorial (line 37) | def cifar10_tutorial( function main (line 228) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/evaluate_pickled_model.py function evaluate_model (line 27) | def evaluate_model( function main (line 108) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_blackbox.py function setup_tutorial (line 47) | def setup_tutorial(): function prep_bbox (line 59) | def prep_bbox( class ModelSubstitute (line 116) | class ModelSubstitute(Model): method __init__ (line 117) | def __init__(self, scope, nb_classes, nb_filters=200, **kwargs): method fprop (line 122) | def fprop(self, x, **kwargs): function train_sub (line 135) | def train_sub( function mnist_blackbox (line 227) | def mnist_blackbox( function main (line 367) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_cw.py function mnist_tutorial_cw (line 41) | def mnist_tutorial_cw( function main (line 254) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_jsma.py function mnist_tutorial_jsma (line 37) | def mnist_tutorial_jsma( function main (line 239) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_keras.py function mnist_tutorial (line 30) | def mnist_tutorial( function get_adversarial_acc_metric (line 192) | def get_adversarial_acc_metric(model, fgsm, fgsm_params): function get_adversarial_loss (line 206) | def get_adversarial_loss(model, fgsm, fgsm_params): function main (line 225) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_keras_tf.py function mnist_tutorial (line 41) | def mnist_tutorial( function main (line 231) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_picklable.py function mnist_tutorial (line 36) | def mnist_tutorial( function main (line 254) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_pytorch.py class PytorchMnistModel (line 44) | class PytorchMnistModel(nn.Module): method __init__ (line 49) | def __init__(self): method forward (line 61) | def forward(self, x): function mnist_tutorial (line 70) | def mnist_tutorial( function main (line 189) | def main(_=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_tf.py function mnist_tutorial (line 38) | def mnist_tutorial( function main (line 214) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/mnist_tutorial_tfe.py function attack_selection (line 51) | def attack_selection(attack_string): function mnist_tutorial (line 76) | def mnist_tutorial( function main (line 268) | def main(argv=None): FILE: cleverhans_v3.1.0/cleverhans_tutorials/tutorial_models.py function make_basic_picklable_cnn (line 14) | def make_basic_picklable_cnn( FILE: cleverhans_v3.1.0/cleverhans_tutorials/tutorial_models_tfe.py class ModelBasicCNNTFE (line 13) | class ModelBasicCNNTFE(Model): method __init__ (line 18) | def __init__( method fprop (line 62) | def fprop(self, x): method get_layer_params (line 81) | def get_layer_params(self, layer_name): method get_params (line 104) | def get_params(self): method get_layer_names (line 119) | def get_layer_names(self): FILE: cleverhans_v3.1.0/docs/_static/doctools.js function highlight (line 69) | function highlight(node, addItems) { FILE: cleverhans_v3.1.0/docs/_static/jquery-3.5.1.js function DOMEval (line 103) | function DOMEval( code, node, doc ) { function toType (line 133) | function toType( obj ) { function isArrayLike (line 503) | function isArrayLike( obj ) { function Sizzle (line 755) | function Sizzle( selector, context, results, seed ) { function createCache (line 903) | function createCache() { function markFunction (line 923) | function markFunction( fn ) { function assert (line 932) | function assert( fn ) { function addHandle (line 956) | function addHandle( attrs, handler ) { function siblingCheck (line 971) | function siblingCheck( a, b ) { function createInputPseudo (line 997) | function createInputPseudo( type ) { function createButtonPseudo (line 1008) | function createButtonPseudo( type ) { function createDisabledPseudo (line 1019) | function createDisabledPseudo( disabled ) { function createPositionalPseudo (line 1075) | function createPositionalPseudo( fn ) { function testContext (line 1098) | function testContext( context ) { function setFilters (line 2309) | function setFilters() {} function toSelector (line 2383) | function toSelector( tokens ) { function addCombinator (line 2393) | function addCombinator( matcher, combinator, base ) { function elementMatcher (line 2460) | function elementMatcher( matchers ) { function multipleContexts (line 2474) | function multipleContexts( selector, contexts, results ) { function condense (line 2483) | function condense( unmatched, map, filter, context, xml ) { function setMatcher (line 2504) | function setMatcher( preFilter, selector, matcher, postFilter, postFinde... function matcherFromTokens (line 2604) | function matcherFromTokens( tokens ) { function matcherFromGroupMatchers (line 2667) | function matcherFromGroupMatchers( elementMatchers, setMatchers ) { function nodeName (line 3025) | function nodeName( elem, name ) { function winnow (line 3035) | function winnow( elements, qualifier, not ) { function sibling (line 3330) | function sibling( cur, dir ) { function createOptions (line 3423) | function createOptions( options ) { function Identity (line 3648) | function Identity( v ) { function Thrower (line 3651) | function Thrower( ex ) { function adoptValue (line 3655) | function adoptValue( value, resolve, reject, noValue ) { function resolve (line 3748) | function resolve( depth, deferred, handler, special ) { function completed (line 4113) | function completed() { function fcamelCase (line 4208) | function fcamelCase( _all, letter ) { function camelCase (line 4215) | function camelCase( string ) { function Data (line 4232) | function Data() { function getData (line 4401) | function getData( data ) { function dataAttr (line 4426) | function dataAttr( elem, key, data ) { function adjustCSS (line 4738) | function adjustCSS( elem, prop, valueParts, tween ) { function getDefaultDisplay (line 4806) | function getDefaultDisplay( elem ) { function showHide (line 4829) | function showHide( elements, show ) { function getAll (line 4961) | function getAll( context, tag ) { function setGlobalEval (line 4986) | function setGlobalEval( elems, refElements ) { function buildFragment (line 5002) | function buildFragment( elems, context, scripts, selection, ignored ) { function returnTrue (line 5097) | function returnTrue() { function returnFalse (line 5101) | function returnFalse() { function expectSync (line 5111) | function expectSync( elem, type ) { function safeActiveElement (line 5118) | function safeActiveElement() { function on (line 5124) | function on( elem, types, selector, data, fn, one ) { function leverageNative (line 5612) | function leverageNative( el, type, expectSync ) { function manipulationTarget (line 5976) | function manipulationTarget( elem, content ) { function disableScript (line 5987) | function disableScript( elem ) { function restoreScript (line 5991) | function restoreScript( elem ) { function cloneCopyEvent (line 6001) | function cloneCopyEvent( src, dest ) { function fixInput (line 6034) | function fixInput( src, dest ) { function domManip (line 6047) | function domManip( collection, args, callback, ignored ) { function remove (line 6139) | function remove( elem, selector, keepData ) { function computeStyleTests (line 6453) | function computeStyleTests() { function roundPixelMeasures (line 6497) | function roundPixelMeasures( measure ) { function curCSS (line 6571) | function curCSS( elem, name, computed ) { function addGetHookIf (line 6624) | function addGetHookIf( conditionFn, hookFn ) { function vendorPropName (line 6649) | function vendorPropName( name ) { function finalPropName (line 6664) | function finalPropName( name ) { function setPositiveNumber (line 6690) | function setPositiveNumber( _elem, value, subtract ) { function boxModelAdjustment (line 6702) | function boxModelAdjustment( elem, dimension, box, isBorderBox, styles, ... function getWidthOrHeight (line 6770) | function getWidthOrHeight( elem, dimension, extra ) { function Tween (line 7146) | function Tween( elem, options, prop, end, easing ) { function schedule (line 7269) | function schedule() { function createFxNow (line 7282) | function createFxNow() { function genFx (line 7290) | function genFx( type, includeWidth ) { function createTween (line 7310) | function createTween( value, prop, animation ) { function defaultPrefilter (line 7324) | function defaultPrefilter( elem, props, opts ) { function propFilter (line 7496) | function propFilter( props, specialEasing ) { function Animation (line 7533) | function Animation( elem, properties, options ) { function stripAndCollapse (line 8248) | function stripAndCollapse( value ) { function getClass (line 8254) | function getClass( elem ) { function classesToArray (line 8258) | function classesToArray( value ) { function buildParams (line 8885) | function buildParams( prefix, obj, traditional, add ) { function addToPrefiltersOrTransports (line 9039) | function addToPrefiltersOrTransports( structure ) { function inspectPrefiltersOrTransports (line 9073) | function inspectPrefiltersOrTransports( structure, options, originalOpti... function ajaxExtend (line 9102) | function ajaxExtend( target, src ) { function ajaxHandleResponses (line 9122) | function ajaxHandleResponses( s, jqXHR, responses ) { function ajaxConvert (line 9180) | function ajaxConvert( s, response, jqXHR, isSuccess ) { function done (line 9696) | function done( status, nativeStatusText, responses, headers ) { FILE: cleverhans_v3.1.0/docs/_static/jquery.js function b (line 2) | function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e... function w (line 2) | function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof... function p (line 2) | function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e... function se (line 2) | function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeTy... function ue (line 2) | function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cac... function le (line 2) | function le(e){return e[S]=!0,e} function ce (line 2) | function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(... function fe (line 2) | function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[... function pe (line 2) | function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourc... function de (line 2) | function de(t){return function(e){return"input"===e.nodeName.toLowerCase... function he (line 2) | function he(n){return function(e){var t=e.nodeName.toLowerCase();return(... function ge (line 2) | function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.... function ve (line 2) | function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,... function ye (line 2) | function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e} function me (line 2) | function me(){} function xe (line 2) | function xe(e){for(var t=0,n=e.length,r="";tb.cac... function le (line 2) | function le(e){return e[S]=!0,e} function ce (line 2) | function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(... function fe (line 2) | function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[... function pe (line 2) | function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourc... function de (line 2) | function de(t){return function(e){return"input"===e.nodeName.toLowerCase... function he (line 2) | function he(n){return function(e){var t=e.nodeName.toLowerCase();return(... function ge (line 2) | function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.... function ve (line 2) | function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,... function ye (line 2) | function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e} function me (line 2) | function me(){} function xe (line 2) | function xe(e){for(var t=0,n=e.length,r="";t