gcp upload file

PHOTO EMBED

Wed Feb 16 2022 07:55:18 GMT+0000 (Coordinated Universal Time)

Saved by @aurora1625 #gcp

storage_client = storage.Client()
 
data_bucket = storage_client.bucket(BUCKET_NAME)

destination_blob_name = 'abstract/kpi_cluster.tsv'
source_file_name = 'kpi_cluster.tsv'
blob = data_bucket.blob(destination_blob_name)

blob.upload_from_filename(source_file_name)

print('File {} uploaded to {}.'.format(
  source_file_name,
  destination_blob_name))
content_copyCOPY