MCPcopy
hub / github.com/OpenMotionLab/MotionGPT / init_axis

Function init_axis

mGPT/render/anim.py:12–32  ·  view source on GitHub ↗
(fig, title, radius=1.5, dist=10)

Source from the content-addressed store, hash-verified

10
11
12def init_axis(fig, title, radius=1.5, dist=10):
13 ax = fig.add_subplot(1, 1, 1, projection='3d')
14 ax.view_init(elev=20., azim=-60)
15
16 fact = 2
17 ax.set_xlim3d([-radius / fact, radius / fact])
18 ax.set_ylim3d([-radius / fact, radius / fact])
19 ax.set_zlim3d([0, radius])
20
21 ax.set_aspect('auto')
22 ax.set_xticklabels([])
23 ax.set_yticklabels([])
24 ax.set_zticklabels([])
25
26 ax.set_axis_off()
27
28 ax.dist = dist
29 ax.grid(b=False)
30
31 ax.set_title(title, loc='center', wrap=True)
32 return ax
33
34
35def plot_floor(ax, minx, maxx, miny, maxy, minz):

Callers 1

render_animationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected