Add KL/Entorpy Fn #78
Annotations
12 errors
|
unittest
Process completed with exit code 1.
|
|
Failed Test: tests/explorer/explorer_test.py::TestExplorerCountdownNoEval::test_explorer
tests/explorer/explorer_test.py::TestExplorerCountdownNoEval::test_explorer: The test failed in the call phase - self = <tests.explorer.explorer_test.TestExplorerCountdownNoEval testMethod=test_explorer>
def test_explorer(self):
self.config.buffer.explorer_input.taskset = get_unittest_dataset_config("countdown")
self.config.name = f"explore-no-eval-{datetime.now().strftime('%Y%m%d%H%M%S')}"
self.config.explorer.rollout_model.use_v1 = False
> self.config.check_and_update()
tests/explorer/explorer_test.py:61:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/explorer/explorer_test.py::TestExplorerCountdownEval::test_explorer
tests/explorer/explorer_test.py::TestExplorerCountdownEval::test_explorer: The test failed in the call phase - self = <tests.explorer.explorer_test.TestExplorerCountdownEval testMethod=test_explorer>
def test_explorer(self):
self.config.buffer.explorer_input.taskset = get_unittest_dataset_config("countdown")
self.config.buffer.explorer_input.eval_tasksets.append(
get_unittest_dataset_config("countdown", "test")
)
self.config.name = f"explore-eval-{datetime.now().strftime('%Y%m%d%H%M%S')}"
self.config.explorer.rollout_model.use_v1 = True
> self.config.check_and_update()
tests/explorer/explorer_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestAPIServer::test_api
tests/common/vllm_test.py::TestAPIServer::test_api: The test failed in the call phase - self = <tests.common.vllm_test.TestAPIServer testMethod=test_api>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm_async"
self.config.explorer.rollout_model.engine_num = 1
self.config.explorer.rollout_model.tensor_parallel_size = 1
self.config.explorer.rollout_model.use_v1 = True
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
self.config.explorer.rollout_model.enable_openai_api = True
> self.config.check_and_update()
tests/common/vllm_test.py:222:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestModelWrapperAsyncV1::test_generate
tests/common/vllm_test.py::TestModelWrapperAsyncV1::test_generate: The test failed in the call phase - self = <tests.common.vllm_test.TestModelWrapperAsyncV1 testMethod=test_generate>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm_async"
self.config.explorer.rollout_model.engine_num = 2
self.config.explorer.rollout_model.tensor_parallel_size = 1
self.config.explorer.rollout_model.use_v1 = True
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
> self.config.check_and_update()
tests/common/vllm_test.py:206:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestModelWrapperAsyncTPV1::test_generate
tests/common/vllm_test.py::TestModelWrapperAsyncTPV1::test_generate: The test failed in the call phase - self = <tests.common.vllm_test.TestModelWrapperAsyncTPV1 testMethod=test_generate>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm_async"
self.config.explorer.rollout_model.engine_num = 2
self.config.explorer.rollout_model.tensor_parallel_size = 2
self.config.explorer.rollout_model.use_v1 = True
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
self.config.algorithm.repeat_times = 2
> self.config.check_and_update()
tests/common/vllm_test.py:191:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestModelWrapperAsyncTPV0::test_generate
tests/common/vllm_test.py::TestModelWrapperAsyncTPV0::test_generate: The test failed in the call phase - self = <tests.common.vllm_test.TestModelWrapperAsyncTPV0 testMethod=test_generate>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm_async"
self.config.explorer.rollout_model.engine_num = 2
self.config.explorer.rollout_model.tensor_parallel_size = 2
self.config.explorer.rollout_model.use_v1 = False
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
> self.config.check_and_update()
tests/common/vllm_test.py:175:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestModelWrapperAsyncV0::test_generate
tests/common/vllm_test.py::TestModelWrapperAsyncV0::test_generate: The test failed in the call phase - self = <tests.common.vllm_test.TestModelWrapperAsyncV0 testMethod=test_generate>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm_async"
self.config.explorer.rollout_model.engine_num = 2
self.config.explorer.rollout_model.tensor_parallel_size = 1
self.config.explorer.rollout_model.use_v1 = False
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
self.config.algorithm.repeat_times = 2
> self.config.check_and_update()
tests/common/vllm_test.py:160:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/vllm_test.py::TestModelWrapperSyncV0::test_generate
tests/common/vllm_test.py::TestModelWrapperSyncV0::test_generate: The test failed in the call phase - self = <tests.common.vllm_test.TestModelWrapperSyncV0 testMethod=test_generate>
def setUp(self):
self.config = get_template_config()
self.config.mode = "explore"
self.config.model.model_path = get_model_path()
self.config.explorer.rollout_model.engine_type = "vllm"
self.config.explorer.rollout_model.tensor_parallel_size = 1
self.config.explorer.rollout_model.engine_num = 2
self.config.explorer.rollout_model.use_v1 = False
self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE
self.config.algorithm.repeat_times = 2
> self.config.check_and_update()
tests/common/vllm_test.py:144:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/config_test.py::TestConfig::test_load_default_config
tests/common/config_test.py::TestConfig::test_load_default_config: The test failed in the call phase - self = <tests.common.config_test.TestConfig testMethod=test_load_default_config>
def test_load_default_config(self):
config = get_template_config()
config.buffer.batch_size = 8
config.algorithm.repeat_times = 10
config.model.model_path = "Qwen/Qwen3-1.7B"
config.cluster.gpu_per_node = 8
config.cluster.node_num = 2
config.explorer.rollout_model.engine_num = 2
config.explorer.rollout_model.tensor_parallel_size = 2
config.explorer.auxiliary_models.append(
InferenceModelConfig(model_path="Qwen/Qwen3-32B", tensor_parallel_size=4, engine_num=1),
)
> config.check_and_update()
tests/common/config_test.py:23:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
Failed Test: tests/common/config_test.py::TestConfig::test_all_examples_are_valid
tests/common/config_test.py::TestConfig::test_all_examples_are_valid: The test failed in the call phase due to an exception - self = <tests.common.config_test.TestConfig testMethod=test_all_examples_are_valid>
def test_all_examples_are_valid(self):
example_dir = os.path.join(os.path.dirname(__file__), "..", "..", "examples")
for example_name in os.listdir(example_dir):
for filename in os.listdir(os.path.join(example_dir, example_name)):
if filename.endswith(".yaml") and not (
filename.startswith("train_") or filename.startswith("verl_")
):
print(f"Checking config: {filename}")
config_path = os.path.join(example_dir, example_name, filename)
try:
config = load_config(config_path)
config.check_and_update()
except Exception as e:
print(f"Error loading config {config_path}: {e}")
> raise e
tests/common/config_test.py:53:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
tests/common/config_test.py:50: in test_all_examples_are_valid
config.check_and_update()
trinity/common/config.py:549: in check_and_update
self._check_algorithm()
trinity/common/config.py:488: in _check_algorithm
from trinity.algorithm import (
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
from trinity.algorithm.advantage_fn import ADVANTAGE_FN, AdvantageFn
> from trinity.algorithm.entropy_loss_fn import ENTROPY_LOSS_FN, EntropyLossFn
E ModuleNotFoundError: No module named 'trinity.algorithm.entropy_loss_fn'
trinity/algorithm/__init__.py:2: ModuleNotFoundError
|
|
unittest
Process completed with exit code 1.
|