Question: import csv import re # Read Baselight _ export.txt file file _ baselight = open ( ' / Users / sayrareyes / Python - Projects
import csv
import re
# Read Baselightexport.txt file
filebaselight openUserssayrareyesPythonProjectsCOMPAssignmentBaselightexport.txtr
# printfilebaselight.read
# Read Xytech.txt file
with openXytechtxtr as f:
# xytechfile
xytechdata freadsplitlines
# Baselightexport.txt file
baselightdata
for currentReadline in filebaselight:
if not currentReadline.strip:
continue
printCurrent read:
currentReadline
parseline currentReadline.split
if not parseline:
continue
printBaselight file: parseline
currentfolder parseline.pop
parsefolder currentfolder.split
parsefolder.pop
newfolder joinparsefolder
printParse Folder: parsefolder
printNew Folder: newfolder
print
for xytechfile in xytechdata:
isVerbose True
if newfolder in xytechfile:
# printFound: newfolder xytechfile
currentfolder xytechfile.strip
# Process frames and ranges
def processframeslocation:
frames
for entry in xytechdata:
if entry.startswithlocation:
frames.extendrefindallrbdb entry
frames intframe for frame in frames
frames.sort
return frames
printxytechdata
print
# Export CSV File
with openbaselightandxytech.csvw newline as csvfile:
writer csvwritercsvfile
writer.writerowProducer 'Operator', 'Job', 'Notes'
writer.writerowOlivia Rodrigo', 'Johnny Bananas', Dirtfixing', 'Please clean files noted per Colorist Brock
'Purdy'
writer.writerow # Empty row
writer.writerowShow Location', 'Frame to fix'
writer.writerow
writer.writerow # Empty rowImport file created from baselight Baselightexport.txt
Import xytech work order Xytechtxt
Script will parse data
Computation done to match shareholder request, to replace file system from local baselight to facility storage
remember color correcter's prefer local storage for bandwidth issues
Remember we are dealing with rd party data, so some errors in the data might occur and you have to deal
Xytech Workorder
Producer: Olivia Rodrigo
Operator: Johnny Bananas
Job: Dirtfixing
Location:
hpsansproductionDunereelpartAx
hpsansproductionDunereelVFXHydraulx
hpsansproductionDunereelVFXFramestore
hpsansproductionDunereelVFXAnimalLogic
hpsansproductionDunereelpartBx
hpsansproductionDunepickupsshotabx
hpsansproductionDunepickupsshotbx
hpsansproductionDunereelpartCx
Notes:
Please clean files noted per Colorist Brock Purdy
baselightfilesystemDunereelpartAx
baselightfilesystemDunereelVFXHydraulx
baselightfilesystemDunereelpartAx
baselightfilesystemDunepickupsshotabx
baselightfilesystemDunereelpartAx
baselightfilesystemDunereelVFXFramestore
baselightfilesystemDunereelVFXHydraulx
baselightfilesystemDunereelpartAx
baselightfilesystemDunereelpartBx
baselightfilesystemDunereelVFXAnimalLogic
baselightfilesystemDunereelpartBx
baselightfilesystemDunereelVFXHydraulx
baselightfilesystemDunereelVFXFramestore
baselightfilesystemDunepickupsshotbx
baselightfilesystemDunereelpartBx
