{"blog_url":"https://python-remrin.hatenadiary.jp/","description":"NumPy\u306e\u7e70\u308a\u8fd4\u3057repeat()\u3001tile()\u306b\u3064\u3044\u3066\u3002 np.repeat() \u914d\u5217\u306e\u8981\u7d20\u3092\u7e70\u308a\u8fd4\u3059\u3002 axis\u3092\u7701\u7565\u3059\u308b\u30681\u6b21\u5143\u306bflatten\u3055\u308c\u308b\u3002 import numpy as np a1 = np.arange(4) print(a1.repeat(2)) # [0 0 1 1 2 2 3 3] print(a1.repeat([3, 2, 1, 0])) # [0 0 0 1 1 2] a2 = np.arange(6).reshape(2, 3) print(a2.repeat(2, axis=0)) # [[0 1 2] # [0 1 2] # [3 4 5] # [3\u2026","image_url":null,"width":"100%","published":"2017-05-13 22:15:30","version":"1.0","title":"NumPy\u306e\u4f7f\u3044\u65b9\uff08\uff11\uff14\uff09\u3000\u7e70\u308a\u8fd4\u3057","url":"https://python-remrin.hatenadiary.jp/entry/2017/05/13/221530","type":"rich","author_name":"rare_Remrin","author_url":"https://blog.hatena.ne.jp/rare_Remrin/","provider_name":"Hatena Blog","blog_title":"Remrin\u306epython\u653b\u7565\u65e5\u8a18","height":"190","categories":["numpy","\u30e9\u30a4\u30d6\u30e9\u30ea","python"],"html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fpython-remrin.hatenadiary.jp%2Fentry%2F2017%2F05%2F13%2F221530\" title=\"NumPy\u306e\u4f7f\u3044\u65b9\uff08\uff11\uff14\uff09\u3000\u7e70\u308a\u8fd4\u3057 - Remrin\u306epython\u653b\u7565\u65e5\u8a18\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","provider_url":"https://hatena.blog"}