thunlp / LEGENT

Open Platform for Embodied Agents
https://docs.legent.ai
Apache License 2.0
244 stars 15 forks source link

When the render engine is to open source? #9

Open generatemotion opened 3 months ago

generatemotion commented 3 months ago

Hi

I find the renderer engine is downloaded from repo, when this part is to open source?

chengzl18 commented 3 months ago

Because the client incorporates assets and code that cannot be redistributed according to their EULAs, it is currently not released as raw assets and code but rather as executables. The executables are permanently free to use. We are considering reimplementing the restricted code or making the client open source in a modular way. The specific timeline has not yet been determined.

If you currently need certain features for the client, you can request a new feature. If you want to contribute to the client code, you can contact us. If you want to learn about the rendering part, it is extended from Unity URP, you can learn about it.

generatemotion commented 2 months ago

thanks too much. The client start too slow, I find the server use gRPC , that means the client will poll, is that?

generatemotion commented 2 months ago

could you share the client code to me, i want to study the implementation details

chengzl18 commented 1 month ago

The communication of gRPC is efficient, it should not be the reason. I calculated the startup time with the following script:

from legent import Environment, ResetInfo, generate_scene
import time

start_time = time.time()
env = Environment(env_path="auto")
print(f"Launch Time: {time.time() - start_time:.2f}s")

scene = generate_scene()

start_time = time.time()
env.reset(ResetInfo(scene=scene))
print(f"Reset Time: {time.time() - start_time:.2f}s")

start_time = time.time()
for i in range(10):
    env.step()
print(f"Step Time: {(time.time() - start_time)/10:.2f}s/step")

env.close()

And the results are as follows:

Launch Time: 2.04s
Reset Time: 0.83s
Step Time: 0.02s/step

I would like to know how long it took to start on your machine? 2s is a normal startup time for a 3D environment, considering that the environment will be used for a long time after it starts, this should not be too much of an impact.