# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     name: python3
# ---

# + id="BZh1ahGxkeqk" colab_type="code" colab={}
import torch

# + id="PVl2XLOZklbf" colab_type="code" colab={"base_uri": "https://localhost:8080/", "height": 153} outputId="ff6d9313-bf63-45b2-d9e5-4d56cdbe789b"
x = torch.arange(18).view(3,2,3)
x

# + id="hyDXBOG0ktAn" colab_type="code" colab={"base_uri": "https://localhost:8080/", "height": 34} outputId="4d51eac9-e172-43d7-e32d-5bdfb6699a00"
x[1,1,1]

# + id="vKl6O-qCk31q" colab_type="code" colab={"base_uri": "https://localhost:8080/", "height": 51} outputId="f23c5d41-14d3-4409-9592-60b6dd891858"
# Slicing 3D tensors
x[1, 0:2, 0:3]

# + id="QMxkqA4jlGlq" colab_type="code" colab={}


StarcoderdataJupyterScriptsDedupFiltered