|
|
|
|
|
|
} |
|
|
|
|
|
|
|
var modelApiVersion = (int)model.GetTensorByName(TensorNames.VersionNumber)[0]; |
|
|
|
var memorySize = (int)model.GetTensorByName(TensorNames.MemorySize)[0]; |
|
|
|
var isContinuousInt = (int)model.GetTensorByName(TensorNames.IsContinuousControl)[0]; |
|
|
|
var isContinuous = GetActionType(isContinuousInt); |
|
|
|
var actionSize = (int)model.GetTensorByName(TensorNames.ActionOutputShape)[0]; |
|
|
|
if (modelApiVersion == -1) |
|
|
|
{ |
|
|
|
failedModelChecks.Add( |
|
|
|
|
|
|
|
|
|
|
if (modelApiVersion > k_ApiVersion) |
|
|
|
{ |
|
|
|
var minTrainerVersion = PythonTrainerVersions.s_MinSupportedVersion; |
|
|
|
var maxTrainerVersion = PythonTrainerVersions.s_MaxSupportedVersion; |
|
|
|
|
|
|
|
"Either retrain with an older trainer, or update to a newer version of com.unity.ml-agents.\n" + |
|
|
|
$"Either retrain with an older trainer (between versions {minTrainerVersion} and {maxTrainerVersion}), " + |
|
|
|
$"or update to a newer version of com.unity.ml-agents.\n" + |
|
|
|
|
|
|
|
var memorySize = (int)model.GetTensorByName(TensorNames.MemorySize)[0]; |
|
|
|
var isContinuousInt = (int)model.GetTensorByName(TensorNames.IsContinuousControl)[0]; |
|
|
|
var isContinuous = GetActionType(isContinuousInt); |
|
|
|
var actionSize = (int)model.GetTensorByName(TensorNames.ActionOutputShape)[0]; |
|
|
|
|
|
|
|
failedModelChecks.AddRange( |
|
|
|
CheckIntScalarPresenceHelper(new Dictionary<string, int>() |
|
|
|