টেনসরশেপ

@frozen
public struct TensorShape : ExpressibleByArrayLiteral
extension TensorShape: Collection, MutableCollection
extension TensorShape: RandomAccessCollection
extension TensorShape: RangeReplaceableCollection
extension TensorShape: Equatable
extension TensorShape: Codable
extension TensorShape: CustomStringConvertible

টেনসরের আকৃতির প্রতিনিধিত্বকারী একটি কাঠামো।

TensorShape হল পূর্ণসংখ্যার একটি অ্যারের চারপাশে একটি পাতলা মোড়ক যা আকৃতির মাত্রা উপস্থাপন করে। সমস্ত টেনসর প্রকার তাদের আকৃতি উপস্থাপন করতে TensorShape ব্যবহার করে।

  • আকৃতির মাত্রা।

    ঘোষণা

    public var dimensions: [Int]
  • মাত্রার একটি অ্যারে দিয়ে শুরু করুন। টেনসরের র‌্যাঙ্ক হল অ্যারের দৈর্ঘ্য।

    ঘোষণা

    public init(_ dimensions: [Int])

    পরামিতি

    dimensions

    আকৃতির মাত্রা।

  • মাত্রার একটি সংগ্রহ দিয়ে শুরু করুন। টেনসরের র্যাঙ্ক হল সংগ্রহের দৈর্ঘ্য।

    ঘোষণা

    public init<C>(_ dimensions: C) where C : Collection, C.Element == Int

    পরামিতি

    dimensions

    আকৃতির মাত্রা।

  • আকৃতির মাত্রা উপস্থাপন করে একটি অ্যারে আক্ষরিক দিয়ে শুরু করুন। টেনসরের র্যাঙ্ক হল মাত্রার সংখ্যা।

    ঘোষণা

    public init(arrayLiteral elements: Int...)

    পরামিতি

    dimensions

    আকৃতির মাত্রা।

  • আকৃতির মাত্রার প্রতিনিধিত্বকারী বৈচিত্র্যময় উপাদান দিয়ে শুরু করুন। টেনসরের র্যাঙ্ক হল উপাদানের সংখ্যা।

    ঘোষণা

    public init(_ elements: Int...)

    পরামিতি

    dimensions

    আকৃতির মাত্রা।

  • ঘোষণা

    public init(repeating repeatedValue: Int, count: Int)
  • আকৃতির র‍্যাঙ্ক (অর্থাৎ মাত্রার সংখ্যা)।

    ঘোষণা

    public var rank: Int { get }
  • একটি সংরক্ষিত অ্যারে হিসাবে আকৃতির আকার।

    ঘোষণা

    public var contiguousSize: Int { get }
  • ঘোষণা

    public typealias Element = Int
  • ঘোষণা

    public typealias Index = Int
  • ঘোষণা

    public typealias Indices = Range<Int>
  • আকৃতির র‍্যাঙ্ক (অর্থাৎ মাত্রার সংখ্যা)।

    ঘোষণা

    public var count: Int { get }
  • ঘোষণা

    public var indices: Indices { get }
  • ঘোষণা

    public var startIndex: Index { get }
  • ঘোষণা

    public var endIndex: Index { get }
  • ঘোষণা

    public func index(after i: Index) -> Index
  • i-th মাত্রার আকার অ্যাক্সেস করুন।

    ঘোষণা

    public subscript(position: Index) -> Element { get set }

    পরামিতি

    position

    একটি মাত্রার সূচক।

  • i-th মাত্রার আকার অ্যাক্সেস করুন।

    ঘোষণা

    public subscript(bounds: Range<Int>) -> TensorShape { get set }

    পরামিতি

    index

    একটি মাত্রার সূচক।

  • ঘোষণা

    public func index(_ i: Int, offsetBy distance: Int) -> Int
  • ঘোষণা

    public func distance(from start: Int, to end: Int) -> Int
  • ঘোষণা

    public typealias SubSequence = `Self`
  • ঘোষণা

    public init()
  • ঘোষণা

    public mutating mutating func append(_ newElement: Element)
  • ঘোষণা

    public mutating mutating func append(contentsOf newElements: TensorShape)
  • ঘোষণা

    public mutating mutating func append<S>(contentsOf newElements: S) where S : Sequence, S.Element == TensorShape.Element
  • ঘোষণা

    public mutating func replaceSubrange<C>(
      _ subrange: Range<Index>, with newElements: C
    ) where C: Collection, Element == C.Element
  • ঘোষণা

    public static func == (lhs: TensorShape, rhs: TensorShape) -> Bool
  • ঘোষণা

    public func encode(to encoder: Encoder) throws
  • ঘোষণা

    public init(from decoder: Decoder) throws
  • ঘোষণা

    public var description: String { get }