Skip to content

Commit 36b312a

Browse files
Bumped versions. (#6155)
* Bumped versions. * Bumped versions. * Updated unity projects. * Updated version validation. * Fixed failing GPU test.
1 parent 057e264 commit 36b312a

File tree

11 files changed

+20
-17
lines changed

11 files changed

+20
-17
lines changed

DevProject/Packages/packages-lock.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@
7979
"depth": 0,
8080
"source": "local",
8181
"dependencies": {
82-
"com.unity.ml-agents": "3.0.0-exp.1",
82+
"com.unity.ml-agents": "3.0.0",
8383
"com.unity.modules.physics": "1.0.0"
8484
}
8585
},

DevProject/ProjectSettings/EditorBuildSettings.asset

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ EditorBuildSettings:
99
path: Assets/ML-Agents/Scripts/Tests/Runtime/AcademyTest/AcademyStepperTestScene.unity
1010
guid: 9bafc50b1e55b43b2b1ae9620f1f8311
1111
m_configObjects:
12-
com.unity.ml-agents.settings: {fileID: 11400000, guid: b176c44294f5e434bb5109ddfc43274e,
12+
com.unity.ml-agents.settings: {fileID: 11400000, guid: b9540ad82945942dd852207c48989240,
1313
type: 2}
1414
m_UseUCBPForAssetBundles: 0

Project/Packages/packages-lock.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
"depth": 0,
9797
"source": "local",
9898
"dependencies": {
99-
"com.unity.ml-agents": "3.0.0-exp.1",
99+
"com.unity.ml-agents": "3.0.0",
100100
"com.unity.modules.physics": "1.0.0"
101101
}
102102
},

com.unity.ml-agents.extensions/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"unity": "2023.2",
66
"description": "A source-only package for new features based on ML-Agents",
77
"dependencies": {
8-
"com.unity.ml-agents": "3.0.0-exp.1",
8+
"com.unity.ml-agents": "3.0.0",
99
"com.unity.modules.physics": "1.0.0"
1010
}
1111
}

com.unity.ml-agents/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
},
1313
"samples": [
1414
{
15-
"displayName":"3D Ball",
16-
"description":"The 3D Ball sample is a simple environment that is a great for jumping into ML-Agents to see how things work.",
15+
"displayName": "3D Ball",
16+
"description": "The 3D Ball sample is a simple environment that is a great for jumping into ML-Agents to see how things work.",
1717
"path": "Samples~/3DBall"
1818
}
1919
]
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Version of the library that will be used to upload to pypi
2-
__version__ = "1.1.0.dev0"
2+
__version__ = "1.2.0.dev0"
33

44
# Git tag that will be checked to determine whether to trigger upload to pypi
55
__release_tag__ = None

ml-agents/mlagents/torch_utils/torch.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def set_torch_config(torch_settings: TorchSettings) -> None:
5353

5454
if _device.type == "cuda":
5555
torch.set_default_device(_device.type)
56-
torch.set_default_dtype(torch.cuda.FloatTensor)
56+
torch.set_default_dtype(torch.float32)
5757
else:
5858
torch.set_default_dtype(torch.float32)
5959
logger.debug(f"default Torch device: {_device}")
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Version of the library that will be used to upload to pypi
2-
__version__ = "1.1.0.dev0"
2+
__version__ = "1.2.0.dev0"
33

44
# Git tag that will be checked to determine whether to trigger upload to pypi
55
__release_tag__ = None

ml-agents/mlagents/trainers/tests/test_torch_utils.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
"device_str, expected_type, expected_index, expected_tensor_type",
1212
[
1313
("cpu", "cpu", None, torch.float32),
14-
("cuda", "cuda", None, torch.cuda.FloatTensor),
15-
("cuda:42", "cuda", 42, torch.cuda.FloatTensor),
14+
("cuda", "cuda", None, torch.float32),
15+
("cuda:42", "cuda", 42, torch.float32),
1616
("opengl", "opengl", None, torch.float32),
1717
],
1818
)

ml-agents/mlagents/trainers/tests/torch_entities/test_attention.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import pytest
2-
from mlagents.torch_utils import torch
2+
from mlagents.torch_utils import torch, default_device
33
import numpy as np
44

55
from mlagents.trainers.torch_entities.utils import ModelUtils
@@ -217,7 +217,7 @@ def test_predict_minimum_training():
217217
argmin = argmin.squeeze()
218218
argmin = argmin.detach()
219219
sliced_oh = onehots[:, : num + 1]
220-
inp = torch.cat([inp, sliced_oh], dim=2)
220+
inp = torch.cat([inp, sliced_oh.to(default_device())], dim=2)
221221

222222
embeddings = entity_embedding(inp, inp)
223223
masks = get_zero_entities_mask([inp])

utils/validate_versions.py

+7-4
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@
2525

2626
def _escape_non_none(s: Optional[str]) -> str:
2727
"""
28-
Returns s escaped in quotes if it is non-None, else "None"
28+
Returns s escaped in quotes if it is non-None, els e "None"
29+
Returns s escaped in quotes if it is non-None, els e "None"
2930
:param s:
3031
:return:
3132
"""
@@ -81,11 +82,13 @@ def set_version(
8182
f.write(new_contents)
8283

8384
if csharp_version is not None:
84-
package_version = f"{csharp_version}-exp.1"
85+
# removed exp.1 tag from version strings since MLA package is a supported package again
86+
# package_version = f"{csharp_version}-exp.1"
87+
package_version = f"{csharp_version}"
8588
if csharp_extensions_version is not None:
8689
# since this has never been promoted we need to keep
8790
# it in preview forever or CI will fail
88-
extension_version = f"{csharp_extensions_version}-exp.1"
91+
extension_version = f"{csharp_extensions_version}-preview"
8992
print(
9093
f"Setting package version to {package_version} in {MLAGENTS_PACKAGE_JSON_PATH}"
9194
f" and {MLAGENTS_EXTENSIONS_PACKAGE_JSON_PATH}"
@@ -178,7 +181,7 @@ def print_release_tag_commands(
178181
print(f"Updating C# package to version {args.csharp_version}")
179182
if args.csharp_extensions_version:
180183
print(
181-
f"Updating C# extensions package to version {args.csharp_extensions_version}"
184+
f"Updating C# extensions package to version {args.csharp_extensions_version}-exp.1"
182185
)
183186
set_version(
184187
args.python_version,

0 commit comments

Comments
 (0)