Skip to main content

批量自动化工具和包

项目描述

批量自动化

图片 下载

Batch Automation 是一个 Python 库,具有用于处理 3d 和非 3d 相关内容的各种函数和 API。

几个例子:

  • AWS Thinkbox 截止日期 API
  • 黑魔法API
  • 谷歌服务 API
  • MongoDB API
  • 自定义工具

更多功能将超时添加

安装

使用包管理器pip安装 Batch Automation。

pip install batch_automation

用法

AWS Thinkbox 截止日期 API

from batch_automation.deadline.custom.custom import *

# Returns all jobs in selected repository.
print (Repository('WebServiceName', Port).GetJobs())

# Returns all jobs in selected repository.
print (Repository('WebServiceName', Port).GetJobByName('Job-Name'))

# Returns a job details.
# you can search by "job_name" or "job_id", job_id method is a lot quicker
print (Repository('WebServiceName', Port).GetJobDetails('Job-Name'))

# Create the info_file and plugin_file and submit them to deadline
info_file = Repository().JobInfo(Name='Job-Name', 
                                UserName='UserName', 
                                Frames='1', 
                                Plugin='VraySpawner')
plugin_file = Repository().PluginInfo(Version='Max2023')
print(Repository('WebServiceName', Port).SubmitJob(info_file, plugin_file))

还包括所有标准 api 调用

from batch_automation.deadline.api.DeadlineConnect import DeadlineCon as Connect

repo = Connect('WebServiceName', Port)

#The list of Group names.
print (repo.Groups.GetGroupNames())

# The list of Jobs
print (repo.Jobs.GetJobs())

Blackmagic API 完整功能列表 Link

from batch_automation.davinci.MediaPool import MediaPool
from batch_automation.davinci.ProjectManager import ProjectManager

# Returns currently selected Folder
print (MediaPool.GetCurrentFolder())

# Adds new timeline with given name
print (MediaPool.CreateEmptyTimeline('New-Timeline'))

# Imports specified file/folder paths into current Media Pool folder.
# Input is an array of file/folder paths. Returns a list of the MediaPoolItems created.
print (MediaPool.ImportMedia(['/mdeia/clip.mov']))

# Creates and returns a project if projectName (string) is unique, and None if it is not.
print(ProjectManager.CreateProject('New-Project'))

# Returns a list of dictionary items (with keys 'DbType', 'DbName' and optional 'IpAddress')
# corresponding to all the databases added to Resolve
print(ProjectManager.GetDatabaseList())

# Loads and returns the project
print(ProjectManager.LoadProject('Project-Name'))
...

谷歌 API

from batch_automation.google.api import create_service

# Creates an Google Service
print (create_service('https://www.googleapis.com/auth/spreadsheets', 'sheets', 'v4', '/cred/OAuth.json'))

贡献

欢迎请求请求。对于重大更改,请先打开一个问题讨论您想要更改的内容。

请确保根据需要更新测试。

执照

Apache 软件许可证 2.0

项目详情


下载文件

下载适用于您平台的文件。如果您不确定要选择哪个,请了解有关安装包的更多信息。

源分布

batch_automation-0.0.3.tar.gz (33.0 kB 查看哈希)

已上传 source

内置分布

batch_automation-0.0.3-py3-none-any.whl (50.1 kB 视图哈希)

已上传 py3