Example on README doesn't work
See original GitHub issueHi,
The following example on top level README doesn’t work:
from sources import MicrophoneAudioSource
from functional import FrameWiseModel, ChunkWiseModel, OverlappedSpeechPenalty, EmbeddingNormalization
mic = MicrophoneAudioSource(sample_rate=16000)
# Initialize independent modules
segmentation = FrameWiseModel("pyannote/segmentation")
embedding = ChunkWiseModel("pyannote/embedding")
osp = OverlappedSpeechPenalty(gamma=3, beta=10)
normalization = EmbeddingNormalization(norm=1)
# Branch the microphone stream to calculate segmentation
segmentation_stream = mic.stream.pipe(ops.map(segmentation))
# Join audio and segmentation stream to calculate speaker embeddings
embedding_stream = rx.zip(mic.stream, segmentation_stream).pipe(
ops.starmap(lambda wave, seg: (wave, osp(seg))),
ops.starmap(embedding),
ops.map(normalization)
)
embedding_stream.suscribe(on_next=lambda emb: print(emb.shape))
mic.read()
First of all there is a type in declaring variable ops
(it’s been declared as osp
).
Secondly, in line segmentation_stream = mic.stream.pipe(ops.map(segmentation))
, there is no method named map
in variable ops
.
Thanks!
Issue Analytics
- State:
- Created 2 years ago
- Comments:11 (3 by maintainers)
Top Results From Across the Web
Example in readme doesn't work · Issue #2 · qualweb/core
Hi! The code example in README.md doesn't seem to work properly. Firstly (and trivially), the constant earlReports is declared, ...
Read more >What is README.md File? - GeeksforGeeks
A README file is an essential guide that gives other developers a detailed description of your GitHub project. You may be wondering, ...
Read more >Doxygen: How to reference a README.md file from my main ...
The "../README.md" doesn't constitute a valid name The "README.md" would work when it is a local file (i.e. local to the doc directory)....
Read more >Homework: Writing a README
README: A file located in a project's repository that provides detailed information about a project. · Markdown: A simple language that uses marking...
Read more >How to write a detailed README File - Carimus, LLC
When a project doesn't have a README file, it means nobody can know anything about it unless they dive into its code to...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks, it works!
@KannebTo would you mind creating a separate issue for this? Thanks!