chansung commited on
Commit
edf2c37
1 Parent(s): c64a109

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +19 -4
app.py CHANGED
@@ -144,11 +144,12 @@ def update_compute_options(provider, region):
144
  numAccelerators = compute['numAccelerators']
145
  memoryGb = compute['memoryGb'].replace("Gi", "GB")
146
  architecture = compute['architecture']
 
147
 
148
  type = f"{numAccelerators}vCPU {memoryGb} 路 {architecture}" if accelerator == "cpu" else f"{numAccelerators}x {architecture}"
149
 
150
  avalialbe_compute_options.append(
151
- f"{compute['accelerator'].upper()} [{compute['instanceSize']}] 路 {type}"
152
  )
153
 
154
  return gr.Dropdown.update(
@@ -179,7 +180,7 @@ with gr.Blocks() as demo2:
179
  )
180
 
181
  providers = avaliable_providers()
182
- head_sha = "2a520e132597a810e396ca28805d98ce56ec3544"
183
 
184
  with gr.Row():
185
  gr.Markdown("""
@@ -217,13 +218,13 @@ with gr.Blocks() as demo2:
217
 
218
  with gr.Row():
219
  repository_selector = gr.Textbox(
220
- value="my-funny-cat",
221
  interactive=False,
222
  show_label=False,
223
  )
224
 
225
  repository_selector = gr.Textbox(
226
- value=f"v1673257770/{head_sha[:7]}",
227
  interactive=False,
228
  show_label=False,
229
  )
@@ -298,6 +299,20 @@ with gr.Blocks() as demo2:
298
  submit_button = gr.Button(
299
  value="Submit",
300
  )
 
 
 
 
 
 
 
 
 
 
 
 
 
 
301
 
302
  status_txt = gr.Textbox(
303
  value="any status update will be displayed here",
 
144
  numAccelerators = compute['numAccelerators']
145
  memoryGb = compute['memoryGb'].replace("Gi", "GB")
146
  architecture = compute['architecture']
147
+ instanceType = compute['instanceType']
148
 
149
  type = f"{numAccelerators}vCPU {memoryGb} 路 {architecture}" if accelerator == "cpu" else f"{numAccelerators}x {architecture}"
150
 
151
  avalialbe_compute_options.append(
152
+ f"{compute['accelerator'].upper()} [{compute['instanceSize']}] 路 {type} 路 {instanceType}"
153
  )
154
 
155
  return gr.Dropdown.update(
 
180
  )
181
 
182
  providers = avaliable_providers()
183
+ head_sha = "398e79c789669981a2ab1da1fbdafc3998c7b08a"
184
 
185
  with gr.Row():
186
  gr.Markdown("""
 
218
 
219
  with gr.Row():
220
  repository_selector = gr.Textbox(
221
+ value="chansung/my-kitty",
222
  interactive=False,
223
  show_label=False,
224
  )
225
 
226
  repository_selector = gr.Textbox(
227
+ value=f"v1673365013/{head_sha[:7]}",
228
  interactive=False,
229
  show_label=False,
230
  )
 
299
  submit_button = gr.Button(
300
  value="Submit",
301
  )
302
+ # submit_button.click(
303
+ # submit,
304
+ # inputs=[
305
+ # hf_token_input,
306
+ # endpoint_name_input,
307
+ # provider_selector,
308
+ # region_selector,
309
+ # repository_selector,
310
+ # revision_selector,
311
+ # task_selector,
312
+ # framework_selector,
313
+ # min_node_selector,
314
+ # max_node_selector,
315
+ # security_selector])
316
 
317
  status_txt = gr.Textbox(
318
  value="any status update will be displayed here",