In [12]:
from google.colab import drive
drive.mount('/content/drive')


Drive already mounted at /content/drive; to attempt to forcibly remount, call drive.mount("/content/drive", force_remount=True).

In [0]:
from os import listdir
from os.path import isfile, join

In [14]:
%cd "//content/drive/My Drive/kontext/deold/"


/content/drive/My Drive/kontext/deold

In [0]:
from shutil import copyfile

In [16]:
for vid in ['szf2']:
    !mkdir {'4/'+vid}
    print(vid)
    mypath='./4/colorized_auto/'
    onlyfiles1 = [mypath+f for f in listdir(mypath) if (isfile(join(mypath, f)) and (vid in f))]
    mypath='./4/colorized_ref/'
    onlyfiles2 = [mypath+f for f in listdir(mypath) if (isfile(join(mypath, f)) and (vid in f))]
    mypath='./3/goodscenes/'
    onlyfiles3 = [mypath+f for f in listdir(mypath) if (isfile(join(mypath, f)) and (vid in f))]
    for f in onlyfiles1+onlyfiles2+onlyfiles3:
        copyfile(f, './4/'+vid+'/'+f.split('/')[-1])


szf2