config [CLI] in jupyter nb flag #3850
-
I created a config file in my project path. When I run the code from the terminal, the configuration is applied, but when I run the jupyter.nb file in the same path, the configuration is not applied. Should I use a specific flag in jupyter? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You can add all the config options directly into your script cell using the import timeit
config.quality = "medium_quality"
config.disable_caching = True
class SpeedTest(Scene):
def construct(self):
start = timeit.default_timer()
ax = Axes()
pl = ax.plot(lambda x: 3*np.sin(x))
sq = Square()
circ = Circle()
self.play(Create(ax))
self.play(Create(pl))
self.play(Create(sq))
self.play(Transform(sq,circ))
self.wait()
stop = timeit.default_timer()
execution_time = stop - start
print(f"Program executed in {execution_time*1000:.0f} ms")
self.add(Text(f"Program executed in {execution_time*1000:.0f} ms").to_corner(UR))
self.wait() and no, I have no idea how to access a config file from within a notebook... |
Beta Was this translation helpful? Give feedback.
-
ok, you should be able to use the command line setting |
Beta Was this translation helpful? Give feedback.
ok, you should be able to use the command line setting
--config_file TEXT
to include a specific config file:https://docs.manim.community/en/stable/reference/manim.utils.ipython_magic.ManimMagic.html#manim.utils.ipython_magic.ManimMagic.manim