Upload¶
Upload models.
Upload the scene’s configuration file and asset file.
-
class
rayvision_sync.upload.
RayvisionUpload
(api, db_config_path=None, transports_json='', transmitter_exe='')¶ Bases:
object
Upload files.
Upload configuration files and asset files.
-
check_transfer_log_path
(transfer_log_path)¶ Check the log location of the transport engine.
-
create_db_ini
(upload_json_path)¶ Create the database configuration file.
Parameters: upload_json_path (str) – Upload json path. Returns: Configuration file path. Return type: str
-
load_db_config
(db_config_path=None)¶
-
thread_pool_upload
(upload_pool, pool_size=10, **kwargs)¶ Thread pool upload.
Parameters:
-
upload
(task_id, task_json_path, tips_json_path, asset_json_path, upload_json_path, max_speed=None, transmit_type='upload_json', engine_type='aspera', server_ip=None, server_port=None)¶ Run the cmd command to upload the configuration file.
Parameters: - task_id (str, optional) – Task id.
- task_json_path (str, optional) – task.json file absolute path.
- tips_json_path (str, optional) – tips.json file absolute path.
- asset_json_path (str, optional) – asset.json file absolute path.
- upload_json_path (str, optional) – upload.json file absolute path.
- max_speed (str) – Maximum transmission speed, default value is 1048576 KB/S.
- transmit_type (str) – transmit type: 1. upload_json: upload from json file,in this type, next remote will not used. 2. upload_list: upload from file list.
- engine_type (str, optional) – set engine type, support “aspera” and “raysync”, Default “aspera”.
- server_ip (str, optional) – transmit server host, if not set, it is obtained from the default transport profile.
- server_port (str, optional) – transmit server port, if not set, it is obtained from the default transport profile.
Returns: True is success, False is failure.
Return type:
-
upload_asset
(**kwargs)¶ Handle.
-
upload_config
(task_id, config_file_list, max_speed=None, engine_type='aspera', server_ip=None, server_port=None)¶ Run the cmd command to upload configuration profiles.
Parameters: - task_id (str) – Task id.
- config_file_list (list) – Configuration file path list.
- max_speed (str) – Maximum transmission speed, default value is 1048576 KB/S.
- engine_type (str, optional) – set engine type, support “aspera” and “raysync”, Default “aspera”.
- server_ip (str, optional) – transmit server host, if not set, it is obtained from the default transport profile.
- server_port (str, optional) – transmit server port, if not set, it is obtained from the default transport profile.
Returns: True is success, False is failure.
Return type:
-