Mercurial > hg > ugly-duckling
comparison src/app/services/feature-extraction/FeatureExtractionWorker.ts @ 321:89208e8af8cc
Load only pYin
author | Lucas Thompson <dev@lucas.im> |
---|---|
date | Tue, 16 May 2017 00:28:27 +0100 |
parents | a16d968d646e |
children | 38886ce7e2e5 |
comparison
equal
deleted
inserted
replaced
320:a16d968d646e | 321:89208e8af8cc |
---|---|
35 class AggregateStreamingService implements StreamingService { | 35 class AggregateStreamingService implements StreamingService { |
36 private services: Map<LibraryKey, PiperStreamingService>; | 36 private services: Map<LibraryKey, PiperStreamingService>; |
37 | 37 |
38 constructor() { | 38 constructor() { |
39 this.services = new Map<LibraryKey, PiperStreamingService>(); | 39 this.services = new Map<LibraryKey, PiperStreamingService>(); |
40 this.services.set( | 40 // this.services.set( |
41 'vamp-example-plugins', | 41 // 'vamp-example-plugins', |
42 new PiperStreamingService(new PiperVampService(VampExamplePlugins())) | 42 // new PiperStreamingService(new PiperVampService(VampExamplePlugins())) |
43 ); | 43 // ); |
44 } | 44 } |
45 | 45 |
46 addService(key: LibraryKey, service: PiperStreamingService): void { | 46 addService(key: LibraryKey, service: PiperStreamingService): void { |
47 this.services.set(key, service); | 47 this.services.set(key, service); |
48 } | 48 } |
110 | 110 |
111 constructor(workerScope: DedicatedWorkerGlobalScope, | 111 constructor(workerScope: DedicatedWorkerGlobalScope, |
112 private requireJs: RequireJs) { | 112 private requireJs: RequireJs) { |
113 this.workerScope = workerScope; | 113 this.workerScope = workerScope; |
114 this.remoteLibraries = new Map<LibraryKey, LibraryUri>([ | 114 this.remoteLibraries = new Map<LibraryKey, LibraryUri>([ |
115 ['nnls-chroma', 'assets/extractors/NNLSChroma.js'], | 115 // ['nnls-chroma', 'assets/extractors/NNLSChroma.js'], |
116 ['pyin', 'assets/extractors/PYin.umd.js'], | 116 ['pyin', 'assets/extractors/PYin.umd.js'], |
117 ]); | 117 ]); |
118 this.service = new ThrottledReducingAggregateService(); | 118 this.service = new ThrottledReducingAggregateService(); |
119 this.setupImportLibraryListener(); | 119 this.setupImportLibraryListener(); |
120 this.server = new WebWorkerStreamingServer( | 120 this.server = new WebWorkerStreamingServer( |