A small backup script in Python
I can't think of any way the file size could change without the mtime
changing too. On the other hand, it does no harm to check, aside from
making the code a little more complex.

You use the expression backup_loc + subpath quite often, so I would do
this:

subpath = root.replace('/home/prahlad/','')   # note extra slash
backup_path = os.path.join(backup_loc, subpath)
...
dfilename = os.path.join(backup_path, f)
...
if not os.path.exists(backup_path):
    os.makedirs(backup_path)
    print 'creating directory: ' + backup_path


For these lines, I would do one thing per line, and move the complex
expression into a function:

sz = os.path.getsize(filename); lm = datetime.fromtimestamp(os.path.getmtime(filename)).timetuple()
dsz = os.path.getsize(dfilename); dlm = datetime.fromtimestamp(os.path.getmtime(dfilename)).timetuple()


As follows:

def file_mtime(path):
    return datetime.fromtimestamp(os.path.getmtime(path)).timetuple()
...
sz = os.path.getsize(filename)
lm = file_mtime(filename)
dsz = os.path.getsize(dfilename);
dlm = file_mtime(dfilename)


However, since you're only comparing one timestamp to another, and not
doing anything else with the timestamps, I don't see why you couldn't
just do this:

lm = os.path.getmtime(filename)
...
dlm = os.path.getmtime(dfilename)


time.clock() returns time in seconds, not minutes; and num is
already an int; so:

mins = round((time.clock() - start) / 60)
print "{0} files copied in {1} minutes".format(num, int(mins))