관측치 = N 차원 공간의 한점
변수의 개수 = 공간의 차원수
배열의 깊이 = 차원수
import numpy as np
x1 = np.array([1,2,3,4])
print(x1.shape , x1.ndim)
x2 = np.array([1,2,3,4])
x3 = np.array([1,2,3,4])
iris = np.array([x1,x2,x3])
print(iris.shape , iris.ndim)
img1 = np.array([[1,2],[3,4]])
print(img1.shape , img1.ndim)
img2 = np.array([[1,2],[3,4]])
img3 = np.array([[1,2],[3,4]])
imgs = np.array([img1 , img2 , img3])
print(imgs.shape , imgs.ndim)
import tensorflow as tf
(x_train , y_train) , (x_test , y_test) = tf.keras.datasets.mnist.load_data()
print(x_train.shape , y_train.shape)
print(x_test.shape , y_test.shape)
import matplotlib.pyplot as plt
print(y_train[0])
plt.imshow(x_train[0])
plt.show()
import pandas as pd
pd.set_option('display.max_columns' , None)
pd.DataFrame(x_train[0])