JunchuanYu commited on
Commit
ecbfde3
1 Parent(s): 3381189

Update run.py

Browse files
Files changed (1) hide show
  1. run.py +7 -1
run.py CHANGED
@@ -6,6 +6,12 @@ from osgeo import gdal
6
  from matplotlib import pyplot as plt
7
  from tqdm import tqdm
8
 
 
 
 
 
 
 
9
  title=(""" # <p align="center"> Remote Sensing Tile Dataset Creator 🛰️ <b>
10
  ### <p align="center"> yujunchuan (yujunchuna@mail.cgs.gov.cn)<b>""")
11
 
@@ -144,4 +150,4 @@ with gr.Blocks(theme=gr.themes.Soft(),css="footer {visibility: hidden}") as demo
144
  brun_button.click(batch_clip_data,[binput_img,bdatatype,bcropsize,bstride,bclipmode,npatch,bthresh,boutpath],[boriginal_img,boriginal_lab,bresult],show_progress=True)
145
 
146
  demo.queue()
147
- demo.launch(debug=True,show_api=False,show_tips=False)
 
6
  from matplotlib import pyplot as plt
7
  from tqdm import tqdm
8
 
9
+ from huggingface_hub import hf_hub_download
10
+ token = os.environ['HUB_TOKEN']
11
+ loc =hf_hub_download(repo_id="JunchuanYu/file_for_rs-tile-creator", filename="utils.py",repo_type="dataset",local_dir='.',token=token)
12
+ sys.path.append(loc)
13
+ from utils import *
14
+
15
  title=(""" # <p align="center"> Remote Sensing Tile Dataset Creator 🛰️ <b>
16
  ### <p align="center"> yujunchuan (yujunchuna@mail.cgs.gov.cn)<b>""")
17
 
 
150
  brun_button.click(batch_clip_data,[binput_img,bdatatype,bcropsize,bstride,bclipmode,npatch,bthresh,boutpath],[boriginal_img,boriginal_lab,bresult],show_progress=True)
151
 
152
  demo.queue()
153
+ demo.launch(debug=False,show_api=False,show_tips=False)