Learning/Pytorch 썸네일형 리스트형 BUILD THE NEURAL NETWORK Neural networks comprise of layers/modules that perform operations on data. The torch.nn namespace provides all the building blocks you need to build your own neural network. Every module in PyTorch subclasses the nn.Module. A neural network is a module itself that consists of other modules (layers). This nested structure allows for building and managing complex architectures easily. In the foll.. 더보기 TRANSFORMS Data does not always come in its final processed form that is required for training machine learning algorithms. We use transforms to perform some manipulation of the data and make it suitable for training. All TorchVision datasets have two parameters -transform to modify the features and target_transform to modify the labels - that accept callables containing the transformation logic. The torch.. 더보기 DATASETS & DATALOADERS Code for processing data samples can get messy and hard to maintain; we ideally want our dataset code to be decoupled(분리된) from our model training code for better readability and modularity. PyTorch provides two data primitives: torch.utils.data.DataLoader and torch.utils.data.Dataset that allow you to use pre-loaded datasets as well as your own data. Dataset stores the samples and their corresp.. 더보기 Tensors Tensors are a specialized data structure that are very similar to arrays and matrices. In PyTorch, we use tensors to encode the inputs and outputs of a model, as well as the model’s parameters. ("encode" means to represent data in a standardized way using tensors, encoding data as tensors allows us to represent a wide variety of data in a standardized format that can be efficiently processed by .. 더보기 이전 1 다음