Skip to content

Instantly share code, notes, and snippets.

View OttomanZ's full-sized avatar
🎯
Focusing

Muneeb Ahmad OttomanZ

🎯
Focusing
View GitHub Profile
@OttomanZ
OttomanZ / vizualization.py
Created September 3, 2022 09:39
Vizualize Heatmaps on Images and Videos (Practical Deep Learning for Cloud, Mobile & Edge)
import numpy as np
import tensorflow
from tensorflow.keras.preprocessing import image
from tensorflow.keras.utils import get_file
from tensorflow.keras.applications.vgg16 import VGG16, preprocess_input
from tf_explain.core.grad_cam import GradCAM
import PIL
from PIL import Image, ImageDraw, ImageFont