コード例 #1
0
def upload_from_parser(args):
    upload(user=args.user,
           source_path=args.source,
           destination_path=args.dest,
           metadata_path=args.metadata,
           multipart_upload=args.large,
           nodata_value=args.nodata)
コード例 #2
0
def test_upload_with_nodata_multipart(monkeypatch, setup_testfolder):
    username = get_username()
    monkeypatch.setattr(getpass, 'getpass', mockreturn_pass)
    source = os.path.join(os.path.dirname(__file__), 'images')
    dest = setup_testfolder + '/test_upload_with_nodata_multipart'
    multipart = True
    nodata = 42
    logging.info('Testing upload with nodata and multipart option')
    upload(user=username, source_path=source, destination_path=dest, multipart_upload=multipart, nodata_value=nodata)
コード例 #3
0
ファイル: geebam.py プロジェクト: tracek/gee_asset_manager
def upload_from_parser(args):
    upload(user=args.user,
           source_path=args.source,
           destination_path=args.dest,
           metadata_path=args.metadata,
           multipart_upload=args.large,
           nodata_value=args.nodata,
           bucket_name=args.bucket,
           band_names=args.bands)
コード例 #4
0
 def run_upload_task(self, *args):
     upload(user=args.user,
         source_path=self._filename,
         destination_path=self._asset_id,
         metadata_path=None,
         multipart_upload=None,
         nodata_value=None,
         bucket_name=None,
         band_names=None)
コード例 #5
0
def test_upload_with_metadata(monkeypatch, setup_testfolder):
    logging.info('Upload test. WARNING. Requires user name and password, which will be passed in open text.')
    username = get_username()
    monkeypatch.setattr(getpass, 'getpass', mockreturn_pass)
    source = os.path.join(os.path.dirname(__file__), 'images')
    metadata = os.path.join(os.path.dirname(__file__), 'images', 'metadata.csv')
    dest = setup_testfolder + '/test_upload_with_metadata'
    multipart = False
    nodata = None
    logging.info('Testing upload with metadata')
    upload(user=username, source_path=source, destination_path=dest, metadata_path=metadata, multipart_upload=multipart, nodata_value=nodata)
コード例 #6
0
ファイル: turbine.py プロジェクト: ktaylora/Turbine
 def run_upload_task(self, *args):
     upload(
         user=args.user,
         source_path=self._filename,
         destination_path=self._asset_id,
         metadata_path=None,
         multipart_upload=None,
         nodata_value=None,
         bucket_name=None,
         band_names=None,
     )
コード例 #7
0
def upload_from_parser(args):
    upload(user=args.user,
           source_path=args.source,
           destination_path=args.dest,
           metadata_path=args.metadata,
           multipart_upload=args.large,
           nodata_value=args.nodata,
           bucket_name=args.bucket,
           band_names=args.bands,
           signal_if_error=args.upload_catch_error,
           tolerate_assets_already_exist=args.tolerate_assets_already_exist,
           headless=args.headless)
コード例 #8
0
def ee_ingest(*args, **kwargs):
    """punt"""
    upload(
        user=kwargs.user,
        source_path=kwargs.get("filename", None),
        destination_path=kwargs.get("asset_id", None),
        metadata_path=None,
        multipart_upload=None,
        nodata_value=None,
        bucket_name=None,
        band_names=None,
    )