MLContext
in package
FinalYes
Manages a legacy ML-Agents Python environment for Unity training runs.
Legacy ML-Agents automation should not be used for new code.
Tags
Table of Contents
Constants
- ADDITIONAL_PACKAGES : mixed = ['0.16' => 'numpy~=1.18.0', '0.17' => 'numpy~=1...
- ADDITIONAL_REPOSITORIES : mixed = '-f https://download.pytorch.org/whl/torch_stab...
- LOCK_EXTENSION : mixed = '.lock'
- PACKAGE_MAPPING : mixed = ['1.7.0-preview' => '0.23', '1.6.0-preview' =>...
- ROOT_PATH : mixed = 'python'
- UPGRADE_PIP : mixed = 'python.exe -m pip install --upgrade pip'
Properties
- $version : string
Methods
- __construct() : mixed
- determineContexts() : iterable<string|int, mixed>
- freeze() : void
- install() : void
- learn() : int
- loadLock() : void
- loadPath() : void
- lockExists() : bool
- pathExists() : bool
- setup() : void
- update() : void
Constants
ADDITIONAL_PACKAGES
public
mixed
ADDITIONAL_PACKAGES
= ['0.16' => 'numpy~=1.18.0', '0.17' => 'numpy~=1.18.0', '0.18' => 'numpy~=1.18.0', '0.19' => 'numpy~=1.18.0', '0.20' => 'numpy~=1.18.0', '0.21' => 'numpy~=1.18.0', '0.22' => 'numpy~=1.18.0 torch===1.7.1+cpu torchvision===0.8.2+cpu torchaudio===0.7.2', '0.23' => 'torch===1.7.1+cpu torchvision===0.8.2+cpu torchaudio===0.7.2']
ADDITIONAL_REPOSITORIES
public
mixed
ADDITIONAL_REPOSITORIES
= '-f https://download.pytorch.org/whl/torch_stable.html'
LOCK_EXTENSION
public
mixed
LOCK_EXTENSION
= '.lock'
PACKAGE_MAPPING
public
mixed
PACKAGE_MAPPING
= ['1.7.0-preview' => '0.23', '1.6.0-preview' => '0.22', '1.5.0-preview' => '0.21', '1.4.0-preview' => '0.20', '1.3.0-preview' => '0.19', '1.2.0-preview' => '0.18', '1.1.0-preview' => '0.17', '1.0.3' => '0.16', '1.0.2' => '0.16']
ROOT_PATH
public
mixed
ROOT_PATH
= 'python'
UPGRADE_PIP
public
mixed
UPGRADE_PIP
= 'python.exe -m pip install --upgrade pip'
Properties
$version
public
string
$version
Methods
__construct()
public
__construct(string $workDirectory, string $version) : mixed
Parameters
- $workDirectory : string
- $version : string
determineContexts()
public
static determineContexts(string $serverPath) : iterable<string|int, mixed>
Parameters
- $serverPath : string
Return values
iterable<string|int, mixed>freeze()
public
freeze() : void
install()
public
install() : void
learn()
public
learn(string $workDirectory, string $arguments) : int
Parameters
- $workDirectory : string
- $arguments : string
Return values
intloadLock()
public
loadLock() : void
loadPath()
public
loadPath() : void
lockExists()
public
lockExists() : bool
Return values
boolpathExists()
public
pathExists() : bool
Return values
boolsetup()
public
setup() : void
update()
public
update() : void