You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The examples (in the function definition and in the docs) for the clip.fl_time( ... ) function aren't correct, and it led me to an error that I spent several hours on before I figured out what was wrong (I haven't used python in a while, so someone else would probably have fixed it sooner).
Current example code
>>> # plays the clip (and its mask and sound) twice faster
>>> newclip = clip.fl_time(lambda: 2*t, apply_to=['mask', 'audio'])
>>>
>>> # plays the clip starting at t=3, and backwards:
>>> newclip = clip.fl_time(lambda: 3-t)
Corrected example code
>>> # plays the clip (and its mask and sound) twice faster
>>> newclip = clip.fl_time(lambda t: 2*t, apply_to=['mask', 'audio'])
>>>
>>> # plays the clip starting at t=3, and backwards:
>>> newclip = clip.fl_time(lambda t: 3-t)
(the difference is the addition of t as the bound variable in the lambda functions)
The text was updated successfully, but these errors were encountered:
Very sorry that you spent so much time tracking the bug down! Funnily enough I found this yesterday as well. It will definitely be corrected in the next release.
The examples (in the function definition and in the docs) for the
clip.fl_time( ... )
function aren't correct, and it led me to an error that I spent several hours on before I figured out what was wrong (I haven't used python in a while, so someone else would probably have fixed it sooner).Current example code
Corrected example code
(the difference is the addition of
t
as the bound variable in the lambda functions)The text was updated successfully, but these errors were encountered: