| 1 | import SwiftUI |
| 2 | import Demucs |
| 3 | |
| 4 | @main |
| 5 | struct DemucsExampleApp: App { |
| 6 | init() { |
| 7 | // Keep the weights inside the app container. |
| 8 | let caches = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)[0] |
| 9 | DemucsEngine.configureCacheDirectory(caches.appendingPathComponent("demucs", isDirectory: true)) |
| 10 | } |
| 11 | |
| 12 | var body: some Scene { |
| 13 | WindowGroup { |
| 14 | ContentView() |
| 15 | } |
| 16 | } |
| 17 | } |