Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
yujincheng08 committed Nov 24, 2024
1 parent 56fd9f9 commit be0e39d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/app_sana.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
ENABLE_CPU_OFFLOAD = os.getenv("ENABLE_CPU_OFFLOAD", "0") == "1"
DEMO_PORT = int(os.getenv("DEMO_PORT", "15432"))
os.environ["GRADIO_EXAMPLES_CACHE"] = "./.gradio/cache"
COUNTER_DB = os.getenv('COUNTER_DB', '.count.db')
COUNTER_DB = os.getenv("COUNTER_DB", ".count.db")

device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")

Expand Down Expand Up @@ -117,7 +117,7 @@

def open_db():
db = sqlite3.connect(COUNTER_DB)
db.execute('CREATE TABLE IF NOT EXISTS counter(app CHARS PRIMARY KEY UNIQUE, value INTEGER)')
db.execute("CREATE TABLE IF NOT EXISTS counter(app CHARS PRIMARY KEY UNIQUE, value INTEGER)")
db.execute('INSERT OR IGNORE INTO counter(app, value) VALUES("Sana", 0)')
return db

Expand Down Expand Up @@ -338,7 +338,7 @@ def generate(
.gradio-container{max-width: 640px !important}
h1{text-align:center}
"""
with gr.Blocks(css=css, title='Sana') as demo:
with gr.Blocks(css=css, title="Sana") as demo:
gr.Markdown(title)
gr.HTML(DESCRIPTION)
gr.DuplicateButton(
Expand Down

0 comments on commit be0e39d

Please sign in to comment.