def calc_md5(filename):
if not isfile(filename):<EOL><INDENT>return None<EOL><DEDENT>hash_md5 = hashlib.md5()<EOL>with open(filename, "<STR_LIT:rb>") as f:<EOL><INDENT>for chunk in iter(lambda: f.read(<NUM_LIT>), b"<STR_LIT>"):<EOL><INDENT>hash_md5.update(chunk)<EOL><DEDENT><DEDENT>return hash_md5.hexdigest()<EOL>
Computes the md5 sum of the given filename.

Args:
    filename (str): Filename to calculate the sum of
Returns:
    str: md5 sum hex string