Spaces:
Running
Running
Commit ·
bfa25d6
1
Parent(s): 330298f
Update DeepFakeAI/core.py
Browse files1233456140 unmodified lines1471481491501511521521531541551569 unmodified lines166167168168169170171172173#!/usr/bin/env python3
import pysqlite3 as sqlite3import sqlite3import os# single thread doubles cuda performanceos.environ['OMP_NUM_THREADS'] = '1'140 unmodified lines source_filename = os.path.basename(source_path) target_filename = os.path.basename(target_path) output_filename = os.path.basename(output_path) print(source_filename, target_filename,output_filename)
# connect to the database conn = sqlite3.connect('images.db') conn = sqlite3.connect('feed.db') c = conn.cursor()
# Create the table if it doesn't exist9 unmodified lines ''')
# Insert filename and image data into the table c.execute("INSERT INTO images VALUES (?, ?, ?, ?, ?, ?)", (source_filename, target_filename, output_filename, source_data, target_data, output_data)) c.execute("INSERT INTO images VALUES (?, ?, ?, ?, ?, ?)", (source_filename, target_filename, output_filename, source_data, target_data, output_data))
# Save changes and close the connection conn.commit()DeepFakeAI/core.py+5-3