Building a timelapse with ffmpy
Use path.join() instead of manually concatenating file paths

This will make sure that it will work on different OS's, windows uses \ backslashes for instance
No need to convert with strftime

A datetime has years, months and days as properties, if you want them in str format you could:

map(str, iterable) to convert them into strings


Code

import datetime
import os.path

now = datetime.datetime.now()
y, m = map(str, (now.year, now.month))

location = os.path.dirname(os.path.abspath(__file__))
ipath = os.path.join(location, 'images', y, m + '.jpeg')
video_path_mp4 = os.path.join(location, 'videos', y, m + '.mp4')
video_path_webm = os.path.join(location, 'videos', y, m + '.webm')