 
   public init(emptyLike example: Self, withCapacity capacity: Int) {
     self = example
+    for kp in recursivelyAllWritableKeyPaths(to: Tensor<UInt8>.self) {
+      self[keyPath: kp] = Tensor(emptyLike: example[keyPath: kp], withCapacity: capacity)
+    }
     for kp in recursivelyAllWritableKeyPaths(to: Tensor<Int32>.self) {
       self[keyPath: kp] = Tensor(emptyLike: example[keyPath: kp], withCapacity: capacity)
     }

  }
}

// public protocol Updatable {
//   mutating func update(using other: Self, forgetFactor: Float)
// }

extension Tensor where Scalar: TensorFlowFloatingPoint {
  public mutating func update(using other: Tensor, forgetFactor: Float) {
    let forgetFactor = Scalar(forgetFactor)


  public func unstacked() -> [Self] {
    var result = [Self]()
    for kp in recursivelyAllWritableKeyPaths(to: Tensor<UInt8>.self) {
      let unstacked = self[keyPath: kp].unstacked()
      if result.isEmpty {
        result = [Self](repeating: self, count: unstacked.count)
      }
      for i in result.indices {
        result[i][keyPath: kp] = unstacked[i]
      }
    }
    for kp in recursivelyAllWritableKeyPaths(to: Tensor<Int32>.self) {
      let unstacked = self[keyPath: kp].unstacked()
      if result.isEmpty {
