티스토리 뷰

반응형

Pytorch 신간에서 다루고 있는 기술에 대해 공부하고자 한다.

Packt홈페이지에서 무료로 동영상을 6일 동안 볼 수 있다.

Mastering-Image-Segmentation-With-PyTorch-using-Real-World-Projects

https://github.com/PacktPublishing/Mastering-Image-Segmentation-With-PyTorch-using-Real-World-Projects/

 

GitHub - PacktPublishing/Mastering-Image-Segmentation-With-PyTorch-using-Real-World-Projects

Contribute to PacktPublishing/Mastering-Image-Segmentation-With-PyTorch-using-Real-World-Projects development by creating an account on GitHub.

github.com

020_TensorIntro

# %% simple calculations
y = x + 10
print(y)

# %% automatic gradient calculation
print(x.requires_grad)  # check if requires_grad is true, false if not directly specified

x.requires_grad_() # set requires grad to true, default True

#%% or set the flag directly during creation
x = torch.tensor(2.0, requires_grad=True)
print(x.requires_grad)
#%% function for showing automatic gradient calculation
def y_function(val):
    return (val-3) * (val-6) * (val-4)

x_range = np.linspace(0, 10, 101)
x_range
y_range = [y_function(i) for i in x_range]
sns.lineplot(x = x_range, y = y_range)

# %% define y as function of x
y = (x-3) * (x-6) * (x-4)
print(y)
# %%

# %% x -> y
# create a tensor with gradients enabled
x = torch.tensor(1.0, requires_grad=True)
# create second tensor depending on first tensor
y = (x-3) * (x-6) * (x-4)
# calculate gradients
y.backward()
# show gradient of first tensor
print(x.grad)
# %% x -> y -> z
x = torch.tensor(1.0, requires_grad=True)
y = x**3
z = 5*y - 4

# %%
z.backward()
print(x.grad)  # should be equal 5*3x**2
# %% more complex network
x11 = torch.tensor(2.0, requires_grad=True)
x21 = torch.tensor(3.0, requires_grad=True)
x12 = 5 * x11 - 3 * x21
x22 = 2 * x11**2 + 2 * x21
y = 4 * x12 + 3 * x22
y.backward()
print(x11.grad)
print(x21.grad)
# %%

autograd - https://tutorials.pytorch.kr/beginner/blitz/autograd_tutorial.html

 

torch.autograd 에 대한 간단한 소개

torch.autograd 는 신경망 학습을 지원하는 PyTorch의 자동 미분 엔진입니다. 이 단원에서는 autograd가 신경망 학습을 어떻게 돕는지에 대한 개념적 이해를 할 수 있습니다. 배경(Background): 신경망(NN; Neur

tutorials.pytorch.kr

030_ModelingIntroduction

https://www.udemy.com/course/mastering-image-segmentation-with-pytorch/?utm_source=adwords&utm_medium=udemyads&utm_campaign=Webindex_Catchall_la.EN_cc.KR&utm_term=_._ag_149093701617_._ad_665676441086_._kw__._de_c_._dm__._pl__._ti_dsa-19959388920_._li_1009893_._pd__._&matchtype=&gad_source=1&gclid=CjwKCAiAyp-sBhBSEiwAWWzTntbZf6IQMKCPbMCodUVcdwmqB5J_klI_M0nAO19siN-qUdpVYBAwchoCiC4QAvD_BwE

https://www.packtpub.com/product/mastering-image-segmentation-with-pytorch-using-real-world-projects-video/9781801817356

이미지 분할은 컴퓨터 비전 분야의 핵심 기술로, 컴퓨터가 이미지의 내용을 픽셀 수준에서 이해할 수 있도록 해줍니다. 

자율주행차, 의료영상, 증강현실 등 다양한 애플리케이션을 갖고 있다. 먼저 텐서 처리, autograd를 사용한 자동 기울기 계산, PyTorch 모델 교육의 기본 사항을 살펴보겠습니다. 

진행하면서 데이터세트 작업, 하이퍼파라미터 최적화, 모델 저장 및 배포 기술과 같은 중요한 주제를 다루는 강력한 기반을 구축하게 됩니다. 

PyTorch에 대한 탄탄한 이해를 바탕으로 과정의 핵심인 의미론적 분할에 대해 자세히 알아보세요.
UNet 및 FPN과 같은 인기 모델의 아키텍처를 탐색하고,
업샘플링의 복잡성을 이해하고,
다양한 손실 함수의 미묘한 차이를 파악하고,
필수 평가 지표에 능숙해집니다. 

또한 이 지식을 실제 시나리오에 적용하여 사용자 정의 데이터세트에서 의미론적 분할 모델을 훈련하는 방법을 배우게 됩니다. 이러한 실제 경험을 통해 이론만 배우는 것이 아니라 자신감을 가지고 실제 프로젝트를 진행할 수 있는 기술을 습득할 수 있습니다. 과정이 끝나면 실제 데이터세트에서 다중 클래스 의미론적 분할을 수행할 수 있는 능력을 갖추게 됩니다.
Image segmentation is a key technology in the field of computer vision, which enables computers to understand the content of an image at a pixel level. It has numerous applications, including autonomous vehicles, medical imaging, and augmented reality. You will start by exploring tensor handling, automatic gradient calculation with autograd, and the fundamentals of PyTorch model training. As you progress, you will build a strong foundation, covering critical topics such as working with datasets, optimizing hyperparameters, and the art of saving and deploying your models. With a robust understanding of PyTorch, you will dive into the heart of the course—semantic segmentation. You will explore the architecture of popular models such as UNet and FPN, understand the intricacies of upsampling, grasp the nuances of various loss functions, and become fluent in essential evaluation metrics. Moreover, you will apply this knowledge in real-world scenarios, learning how to train a semantic segmentation model on a custom dataset. This practical experience ensures that you are not just learning theory but gaining the skills to tackle actual projects with confidence. By course end, you will wield the power to perform multi-class semantic segmentation on real-world datasets.

 

main libraries

https://pytorch.org/docs/stable/data.html

 

torch.utils.data — PyTorch 2.1 documentation

torch.utils.data At the heart of PyTorch data loading utility is the torch.utils.data.DataLoader class. It represents a Python iterable over a dataset, with support for These options are configured by the constructor arguments of a DataLoader, which has si

pytorch.org

https://github.com/qubvel/segmentation_models.pytorch

 

GitHub - qubvel/segmentation_models.pytorch: Segmentation models with pretrained backbones. PyTorch.

Segmentation models with pretrained backbones. PyTorch. - GitHub - qubvel/segmentation_models.pytorch: Segmentation models with pretrained backbones. PyTorch.

github.com

 

반응형

'딥러닝' 카테고리의 다른 글

chatGPT4 using open ai  (0) 2023.12.31
u-net  (0) 2023.12.30
LLM  (1) 2023.12.23
RF  (0) 2023.11.23
RFL books  (0) 2023.11.15
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/07   »
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31
글 보관함