afcd2b86b198a6e548ba43ac5cd135a9ccc86ec6,src/utils/grad_cam.py,,,#,128

Before Change


    guided_model = modify_backprop(model, "GuidedBackProp")
    get_saliency = compile_saliency_function(guided_model)
    saliency = get_saliency([preprocessed_input, 0])
    gradCAM = saliency[0] * heatmap[..., np.newaxis]
    cv2.imwrite("guided_gradcam.jpg", deprocess_image(gradCAM))

After Change



if __name__ == "__main__":
    import pickle
    faces = pickle.load(open("faces.pkl","rb"))
    face = faces[0]
    model_filename = "../../trained_models/emotion_models/mini_XCEPTION.523-0.65.hdf5"
    //reset_optimizer_weights(model_filename)
    model = load_model(model_filename)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: oarriaga/face_classification
Commit Name: afcd2b86b198a6e548ba43ac5cd135a9ccc86ec6
Time: 2017-07-04
Author: arriaga.camargo@gmail.com
File Name: src/utils/grad_cam.py
Class Name:
Method Name:


Project Name: erikbern/ann-benchmarks
Commit Name: be3c3b145f9c25d5629a96d616040ff652522a87
Time: 2017-05-11
Author: alef@itu.dk
File Name: plot.py
Class Name:
Method Name:


Project Name: hanxiao/bert-as-service
Commit Name: 2bfe5bfcec7759ae022b1a479411aa7d1b8401f1
Time: 2019-05-06
Author: zyn2122@gmail.com
File Name: example/example7.py
Class Name:
Method Name: