sail-sg / envpool

C++-based high-performance parallel environment execution engine (vectorized env) for general RL environments.
https://envpool.readthedocs.io
Apache License 2.0
1.1k stars 100 forks source link

fix: removing .encode() in call to register_custom_call_target #310

Open cyprienc opened 4 months ago

cyprienc commented 4 months ago

The function envpool.python.xla_template._make_xla_function wrongfully passes bytes instead of str for the name parameter when calling xla_client.register_custom_call_target.

This leads to errors when calling envs.xla().

Removing .encode() fixes the issue.

cyprienc commented 4 months ago

The lint issue is not related to this change.