{"author_url":"https://blog.hatena.ne.jp/derwind/","height":"190","url":"https://randommemory.hatenablog.com/entry/2021/03/14/023313","blog_title":"\u3089\u3093\u3060\u3080\u306a\u8a18\u61b6","title":"\u884c\u5217\u306e\u7a4d","provider_name":"Hatena Blog","width":"100%","type":"rich","author_name":"derwind","version":"1.0","categories":["machine_learning"],"provider_url":"https://hatena.blog","blog_url":"https://randommemory.hatenablog.com/","description":"PyTorch \u3092\u7528\u3044\u305f\u30d0\u30c3\u30c1\u3078\u306e\u884c\u5217\u306e\u7a4d\u304c\u30d6\u30ed\u30fc\u30c9\u30ad\u30e3\u30b9\u30c8\u3055\u308c\u305f\u7d50\u679c\u3063\u3066\u3069\u3046\u306a\u3093\u3060\u3063\u3051\uff1f\u3068\u3044\u3046\u306e\u304c\u4eca\u66f4\u306b\u4e0d\u5b89\u306b\u306a\u3063\u305f\u306e\u3067\u5b9f\u9a13\u3002numpy \u3082\u4f7f\u3046\u3002 #! /usr/bin/env python # -*- coding: utf-8 -*- import torch def main(): batch = torch.Tensor([ [ [0, -1], [1, 0] ], [ [1, 0], [0, 1] ], [ [1, 2], [3, 4] ], ]) W = torch.Tensor([ [1, -1], [-1, 1] ]) print(W @ batch) if __name_\u2026","image_url":null,"published":"2021-03-14 02:33:13","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Frandommemory.hatenablog.com%2Fentry%2F2021%2F03%2F14%2F023313\" title=\"\u884c\u5217\u306e\u7a4d - \u3089\u3093\u3060\u3080\u306a\u8a18\u61b6\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>"}