     
     static var itemsRatioCache = [Int : CGFloat]()
 
+    static func clearCache() {
+        itemsRatioCache.removeAll(keepCapacity: false)
+    }
+    
     static func itemSizeForType(type: BRNImagePickerSheetItemSize, asset: ALAsset?, indexPath: NSIndexPath?) -> CGSize {
         var ratio: CGFloat = 1.0
 


    static func ratioForAsset(asset: ALAsset?, indexPath: NSIndexPath) -> CGFloat {

        if let ratio = itemsRatioCache[indexPath.section] {
            return ratio
        }

            self.overlayView.alpha = 0.0
            self.tableView.frame.origin.y += CGRectGetHeight(self.tableView.frame)
            }, completion: { (finished: Bool) -> Void in
                BRNImagePickerSheetItemSize.clearCache()
                self.delegate?.imagePickerSheet?(self, didDismissWithButtonIndex: buttonIndex)
                self.removeFromSuperview()
        })
