summaryrefslogtreecommitdiff
path: root/megapixels/commands/faiss/sync_metadata.py
blob: b01211b4760001e8f5ffc375d8f3d26ac0890453 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
"""
Sync the FAISS metadata
"""

import subprocess
import click

from app.settings import app_cfg as cfg

@click.command()
@click.pass_context
def cli(ctx):
  """synchronize metadata files from s3"""
  sts = subprocess.call([
    "s3cmd", "sync",
    "s3://megapixels/v1/metadata/",
    cfg.DIR_FAISS_METADATA + '/',
  ])