<jupyter_start><jupyter_text>The recorder widget has button to record, playback, and download the video, but this is also possible programmatically.<jupyter_code>recorder.recording = True
time.sleep(3)
recorder.recording = False
# Save to a different file in a different format
recorder.save('video.mp4')<jupyter_output><empty_output><jupyter_text>In addition to recording, playing back, and downloading videos (shown above), it is possible to take and save screenshots.<jupyter_code>image_recorder = webrtc.ImageRecorder(stream=viewer, filename='widget_image', autosave=True)
image_recorder<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.0853462157809984, 'fraction_numerical': 0.00322061191626409, 'mean_word_length': 8.424242424242424, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '573666', 'license': 'Apache-2.0', 'n_tokens_mistral': 194, 'n_tokens_neox': 187, 'n_words': 54, 'path': 'examples/RecordAVideo.ipynb', 'repo_name': 'alex-treebeard/itkwidgets', 'size': '621'}