Created
February 14, 2021 22:39
-
-
Save islem-esi/a55ed7dfcae2280f058d39573dc23aa7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Change the parameters to whatever suits you | |
batch_size = 512 | |
epochs = 100 | |
labels = [0 for _ in benign_images] + [1 for _ in malicious_images] | |
model.fit(benign_images+malicious_images, labels, | |
batch_size = batch_size, | |
epochs = epochs, | |
validation_split = 0.25, | |
shuffle = True) |
Hello Islem,
I try this code, but the benign_images and malicious_images aren't defined, and couldn't see the gist that you mention above. Can you please provide the full script?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Check out my medium post: https://medium.com/analytics-vidhya/cnn-based-malware-detection-python-and-tensorflow-717f8de84ee , section EXE file to Image. Using the gist in that section you are supposed to extract images for both benign and malicious exe_files. The variable in that gist is called images, but once you extract images of an exe you should either put the images in benign_images (initially an empty list) or malicious_images (also initially an empty list).