<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 15.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 8.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SoundAnalysis",
  "identifier" : "/documentation/SoundAnalysis/SNClassifySoundRequest/windowDuration",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Sound Analysis"
    ],
    "preciseIdentifier" : "c:objc(cs)SNClassifySoundRequest(py)windowDuration"
  },
  "title" : "windowDuration"
}
-->

# windowDuration

The duration of the audio buffer the request sends to the underlying sound classifier for each prediction.

```
var windowDuration: CMTime { get set }
```

## Discussion

Configure the window duration with a value that satisfies the request’s [`windowDurationConstraint`](/documentation/SoundAnalysis/SNClassifySoundRequest/windowDurationConstraint-5no60).

The request sends larger audio buffer windows less frequently, which can make the classifications more accurate, but less precise in indicating when they occur. Requests with smaller buffer window durations sharpen the time resolution of each prediction, but send smaller audio buffers to the sound classifier.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)