{"id":50750,"date":"2021-09-24T00:00:00","date_gmt":"2021-09-24T07:00:00","guid":{"rendered":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/"},"modified":"2025-11-14T07:54:44","modified_gmt":"2025-11-14T15:54:44","slug":"neural-networks-with-python-and-griddb","status":"publish","type":"post","link":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/","title":{"rendered":"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af"},"content":{"rendered":"<p>\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed\u30dc\u30c3\u30c8\u5de5\u5b66\u307e\u3067\u3001\u3055\u307e\u3056\u307e\u306a\u5206\u91ce\u3067\u305d\u306e\u52b9\u679c\u304c\u78ba\u8a8d\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u4eba\u9593\u306e\u8133\u306b\u30d2\u30f3\u30c8\u3092\u5f97\u305f\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u3042\u308b\u30cb\u30e5\u30fc\u30ed\u30f3\u304b\u3089\u5225\u306e\u30cb\u30e5\u30fc\u30ed\u30f3\u3078\u306e\u4fe1\u53f7\u4f1d\u9054\u306e\u539f\u7406\u3067\u52d5\u4f5c\u3057\u307e\u3059\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u4e3b\u306b3\u7a2e\u985e\u306e\u30ce\u30fc\u30c9\u5c64\uff08\u5165\u529b\u5c64\u30011\u3064\u307e\u305f\u306f\u8907\u6570\u306e\u96a0\u308c\u5c64\u3001\u51fa\u529b\u5c64\uff09\u3067\u69cb\u6210\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u5404\u30ce\u30fc\u30c9\u306f\u3001\u975e\u7dda\u5f62\u95a2\u6570\u3092\u7528\u3044\u3066\u4ed6\u306e\u30ce\u30fc\u30c9\u306b\u63a5\u7d9a\u3059\u308b\u4eba\u5de5\u7684\u306a\u30cb\u30e5\u30fc\u30ed\u30f3\u3067\u3001\u91cd\u307f\u3068\u3057\u304d\u3044\u5024\u304c\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u307e\u3059\u3002\u30cb\u30e5\u30fc\u30ed\u30f3\u306f\u3001\u51fa\u529b\u304c\u6307\u5b9a\u3055\u308c\u305f\u3057\u304d\u3044\u5024\u3092\u8d85\u3048\u305f\u5834\u5408\u306b\u306e\u307f\u6d3b\u6027\u5316\u3055\u308c\u308b\u3002\u3053\u306e\u3088\u3046\u306b\u3057\u3066\u3001\u30c7\u30fc\u30bf\u306f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u6b21\u306e\u5c64\u306b\u6e21\u3055\u308c\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/nn.png\"><img fetchpriority=\"high\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/nn.png\" alt=\"\" width=\"1200\" height=\"1443\" class=\"aligncenter size-full wp-image-27758\" srcset=\"\/wp-content\/uploads\/2021\/09\/nn.png 1200w, \/wp-content\/uploads\/2021\/09\/nn-249x300.png 249w, \/wp-content\/uploads\/2021\/09\/nn-852x1024.png 852w, \/wp-content\/uploads\/2021\/09\/nn-768x924.png 768w, \/wp-content\/uploads\/2021\/09\/nn-600x722.png 600w\" sizes=\"(max-width: 1200px) 100vw, 1200px\" \/><\/a><\/p>\n<p>\u6771\u829dGridDB\u306f\u3001IoT\u3084\u30d3\u30c3\u30b0\u30c7\u30fc\u30bf\u306b\u6700\u9069\u5316\u3055\u308c\u305f\u30b9\u30b1\u30fc\u30e9\u30d6\u30eb\u306a\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3067\u3059\u3002GridDB\u306f\u3001\u5927\u91cf\u306e\u30c7\u30fc\u30bf\u3092\u7c21\u5358\u306b\u53ce\u96c6\u3001\u4fdd\u5b58\u3001\u7167\u4f1a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3055\u3089\u306b\u3001GridDB\u306f\u9ad8\u3044\u30b9\u30b1\u30fc\u30e9\u30d3\u30ea\u30c6\u30a3\u3068\u4fe1\u983c\u6027\u3092\u5099\u3048\u3066\u3044\u308b\u305f\u3081\u3001\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u5b66\u7fd2\u30fb\u63a8\u8ad6\u7528\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3068\u3057\u3066\u3082\u6700\u9069\u3067\u3059\u3002GridDB\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f\u975e\u5e38\u306b\u7c21\u5358\u3067\u3001<a href=\"https:\/\/docs.griddb.net\/ja\/gettingstarted\/python\/\">\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8<\/a>\u3082\u5145\u5b9f\u3057\u3066\u3044\u307e\u3059\u3002\u307e\u305f\u3001python-gridDB\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u3064\u3044\u3066\u306f\u3001<a href=\"https:\/\/www.youtube.com\/watch?v=yWCVfLoV9_0&amp;t=61s\">\u3053\u306e\u30d3\u30c7\u30aa<\/a>\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u3053\u306e\u8a18\u4e8b\u3067\u306f\u3001Python\u3067GridDB\u3092\u4f7f\u3063\u3066\u3001\u30b7\u30f3\u30d7\u30eb\u306a\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u30d9\u30fc\u30b9\u306e\u5206\u985e\u30e2\u30c7\u30eb\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002\u3053\u3053\u3067\u306f\u3001\u30c7\u30a3\u30fc\u30d7\u30e9\u30fc\u30cb\u30f3\u30b0\u30e2\u30c7\u30eb\u306e\u958b\u767a\u3068\u8a55\u4fa1\u306e\u305f\u3081\u306b\u3001\u4f7f\u3044\u3084\u3059\u3044\u7121\u6599\u306e\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9Python\u30e9\u30a4\u30d6\u30e9\u30ea\u3067\u3042\u308bKeras\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<h2>\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/h2>\n<p>\u307e\u305a\u306f\u3001GridDB\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3057\u307e\u3057\u3087\u3046\u3002<\/p>\n<h3>Ubuntu 20.04\u3067\u306eGridDB Python\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306e\u30af\u30a4\u30c3\u30af\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/h3>\n<ul>\n<li>GridDB\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/li>\n<\/ul>\n<p><a href=\"https:\/\/griddb.net\/ja\/downloads\/\">\u3053\u3053<\/a>\u304b\u3089deb\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li>GridDB C\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/li>\n<\/ul>\n<p><a href=\"https:\/\/software.opensuse.org\/download\/package?project=home:knonomura&amp;package=griddb-c-client\">\u3053\u3053<\/a>\u304b\u3089Ubuntu\u5411\u3051\u306egriddb-c-client\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li>\u305d\u306e\u4ed6\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/li>\n<\/ul>\n<p>1) Swig\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-bash\">\nwget https:\/\/github.com\/swig\/swig\/archive\/refs\/tags\/v4.0.2.tar.gz\ntar xvfz v4.0.2.tar.gz\ncd swig-4.0.2\n.\/autogen.sh\n.\/configure\nmake\n  <\/code><\/pre>\n<\/div>\n<p>2) python\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-bash\">\nwget https:\/\/github.com\/griddb\/python_client\/archive\/refs\/tags\/0.8.4.zip\nunzip 0.8.4.zip\ncd python_client-0.8.4\nmake\n  <\/code><\/pre>\n<\/div>\n<p>\u5bfe\u5fdc\u3059\u308bpython\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u306epython-dev\u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u3053\u306e\u8a18\u4e8b\u3067\u306fpython 3.8\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<p>3) \u74b0\u5883\u5909\u6570\u306e\u8a2d\u5b9a<\/p>\n<p>\u74b0\u5883\u5909\u6570\u306b\u6b63\u3057\u3044\u4f4d\u7f6e\u3092\u793a\u3059\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-bash\">\nexport CPATH=$CPATH:&lt;python header file directory path>\nexport LIBRARY_PATH=$LIBRARY_PATH:&lt;c client library file directory path>\n  <\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/ja\/blog\/running-griddb-in-docker\/\">\u3053\u3061\u3089<\/a>\u306e\u3088\u3046\u306b\u3001docker\u3067GridDB\u3092\u5229\u7528\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<h3>Python \u30e9\u30a4\u30d6\u30e9\u30ea<\/h3>\n<p>\u6b21\u306bpython\u306e\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002matplotlib\u3001numpy\u3001keras\u3001tensorflow\u3001pandas\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306fpip\u3067\u7c21\u5358\u306b\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-bash\">\npip install keras\npip install numpy\npip install tensorflow\npip install matplotlib\npip install pandas\n  <\/code><\/pre>\n<\/div>\n<h2>\u4e88\u6e2c<\/h2>\n<h3>\u30b9\u30c6\u30c3\u30d7 1: \u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3059\u308b<\/h3>\n<p>\u4eca\u56de\u306f\u3001Kaggle\u304b\u3089\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002\u4eca\u56de\u306f\u3001<a href=\"https:\/\/www.kaggle.com\/iabhishekofficial\/mobile-price-classification?select=train.csv\">\u643a\u5e2f\u96fb\u8a71\u306e\u4fa1\u683c\u5206\u985e<\/a>\u3092\u9078\u3073\u307e\u3057\u305f\u3002\u76ee\u7684\u306f\u3001\u643a\u5e2f\u96fb\u8a71\u30924\u3064\u306e\u4fa1\u683c\u30ab\u30c6\u30b4\u30ea\u30fc\u306b\u5206\u985e\u3059\u308b\u3053\u3068\u3067\u3059\u3002\u4ee5\u4e0b\u306f\u3001\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u306e\u8aac\u660e\u3067\u3059\u3002<\/p>\n<table>\n<thead>\n<tr>\n<th>\u30ab\u30e9\u30e0<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>battery_power<\/td>\n<td>\u96fb\u6c60\u304c\u4e00\u5ea6\u306b\u84c4\u3048\u308b\u3053\u3068\u306e\u3067\u304d\u308b\u30a8\u30cd\u30eb\u30ae\u30fc\u306e\u7dcf\u91cf\u3002\u5358\u4f4d\u306fmAh\u3002<\/td>\n<\/tr>\n<tr>\n<td>blue<\/td>\n<td>Bluetooth\u306e\u6709\u7121<\/td>\n<\/tr>\n<tr>\n<td>clock_speed<\/td>\n<td>\u30de\u30a4\u30af\u30ed\u30d7\u30ed\u30bb\u30c3\u30b5\u304c\u547d\u4ee4\u3092\u5b9f\u884c\u3059\u308b\u901f\u5ea6<\/td>\n<\/tr>\n<tr>\n<td>dual_sim<\/td>\n<td>\u30c7\u30e5\u30a2\u30ebSIM\u306b\u5bfe\u5fdc\u3057\u3066\u3044\u308b\u304b\u3069\u3046\u304b<\/td>\n<\/tr>\n<tr>\n<td>fc<\/td>\n<td>\u30d5\u30ed\u30f3\u30c8\u30ab\u30e1\u30e9\u306e\u753b\u7d20\u6570<\/td>\n<\/tr>\n<tr>\n<td>four_g<\/td>\n<td>4G\u3092\u642d\u8f09\u3057\u3066\u3044\u308b\u304b\u3069\u3046\u304b<\/td>\n<\/tr>\n<tr>\n<td>int_memory<\/td>\n<td>\u5185\u8535\u30e1\u30e2\u30ea\uff08\u30ae\u30ac\u30d0\u30a4\u30c8\uff09<\/td>\n<\/tr>\n<tr>\n<td>m_dep<\/td>\n<td>\u643a\u5e2f\u96fb\u8a71\u306e\u539a\u307f\u3002\u5358\u4f4d\u306fcm\u3002<\/td>\n<\/tr>\n<tr>\n<td>mobile_wt<\/td>\n<td>\u643a\u5e2f\u96fb\u8a71\u306e\u91cd\u91cf<\/td>\n<\/tr>\n<tr>\n<td>n_cores<\/td>\n<td>\u30d7\u30ed\u30bb\u30c3\u30b5\u306e\u30b3\u30a2\u6570<\/td>\n<\/tr>\n<tr>\n<td>pc<\/td>\n<td>\u30e1\u30a4\u30f3\u30ab\u30e1\u30e9\u306e\u753b\u7d20\u6570<\/td>\n<\/tr>\n<tr>\n<td>px_height<\/td>\n<td>\u753b\u9762\u306e\u89e3\u50cf\u5ea6\uff08\u7e26\uff09<\/td>\n<\/tr>\n<tr>\n<td>px_width<\/td>\n<td>\u753b\u9762\u306e\u89e3\u50cf\u5ea6\uff08\u6a2a\uff09<\/td>\n<\/tr>\n<tr>\n<td>ram<\/td>\n<td>RAM\uff08\u5358\u4f4d\uff1a\u30e1\u30ac\u30d0\u30a4\u30c8\uff09<\/td>\n<\/tr>\n<tr>\n<td>sc_h<\/td>\n<td>\u753b\u9762\u306e\u30b5\u30a4\u30ba\uff08\u7e26\uff09\u3002\u5358\u4f4d\u306fcm\u3002<\/td>\n<\/tr>\n<tr>\n<td>sc_w<\/td>\n<td>\u753b\u9762\u306e\u30b5\u30a4\u30ba\uff08\u6a2a\uff09\u3002\u5358\u4f4d\u306fcm\u3002<\/td>\n<\/tr>\n<tr>\n<td>talk_time<\/td>\n<td>1\u56de\u306e\u5145\u96fb\u3067\u306e\u6700\u9577\u901a\u8a71\u6642\u9593<\/td>\n<\/tr>\n<tr>\n<td>three_g<\/td>\n<td>3G\u3092\u642d\u8f09\u3057\u3066\u3044\u308b\u304b\u3069\u3046\u304b<\/td>\n<\/tr>\n<tr>\n<td>touch_screen<\/td>\n<td>\u30bf\u30c3\u30c1\u30b9\u30af\u30ea\u30fc\u30f3\u306e\u6709\u7121<\/td>\n<\/tr>\n<tr>\n<td>wifi<\/td>\n<td>\u7121\u7ddaLAN\u306e\u6709\u7121<\/td>\n<\/tr>\n<tr>\n<td>price_range<\/td>\n<td>0\uff08\u4f4e\u30b3\u30b9\u30c8\uff09\u30011\uff08\u4e2d\u30b3\u30b9\u30c8\uff09\u30012\uff08\u9ad8\u30b3\u30b9\u30c8\uff09\u30013\uff08\u975e\u5e38\u306b\u9ad8\u30b3\u30b9\u30c8\uff09<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\u30b9\u30c6\u30c3\u30d7 2: \u30e9\u30a4\u30d6\u30e9\u30ea\u30fc\u306e\u30a4\u30f3\u30dd\u30fc\u30c8<\/h3>\n<p>\u307e\u305a\u3001\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u8aad\u307f\u8fbc\u3080\u305f\u3081\u306epandas\u3001\u30d3\u30b8\u30e5\u30a2\u30eb\u5316\u306e\u305f\u3081\u306ematplotlib\u3001\u6df1\u5c64\u5b66\u7fd2\u30e2\u30c7\u30eb\u306e\u305f\u3081\u306etensorflow\u306a\u3069\u3001\u95a2\u9023\u3059\u308b\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u30a4\u30f3\u30dd\u30fc\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nimport tensorflow as tf\nimport numpy as np\nimport pandas as pd\nfrom tensorflow import keras\nfrom tensorflow.keras import layers\n  <\/code><\/pre>\n<\/div>\n<h3>\u30b9\u30c6\u30c3\u30d7 3: \u30c7\u30fc\u30bf\u306e\u8aad\u307f\u8fbc\u307f\u3068\u51e6\u7406<\/h3>\n<h4>\u30c7\u30fc\u30bf\u8aad\u307f\u8fbc\u307f<\/h4>\n<p>\u307e\u305a\u3001\u30c7\u30fc\u30bf\u3092\u8aad\u307f\u8fbc\u307f\u307e\u3059\u3002\u3053\u308c\u306b\u306fpandas\u306eread_csv\u6a5f\u80fd\u3092\u4f7f\u3044\u307e\u3059\u3002\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u306b\u306f\u3001\u30c6\u30b9\u30c8\u3068\u30c8\u30ec\u30fc\u30cb\u30f3\u30b0\u304c\u3059\u3067\u306b2\u3064\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u5206\u3051\u3089\u308c\u3066\u3044\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">dataframe = pd.read_csv('train.csv')<\/code><\/pre>\n<\/div>\n<p>\u3042\u308b\u3044\u306f\u3001GridDB\u3092\u4f7f\u3063\u3066\u3053\u306e\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<h4>\u7279\u5fb4\u91cf\u306e\u30a8\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0<\/h4>\n<p>\u307e\u305a\u3001\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u30ab\u30c6\u30b4\u30ea\u30fc\u3068\u6570\u5024\u306e\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u306b\u30a8\u30f3\u30b3\u30fc\u30c9\u3057\u307e\u3059\u3002\u6570\u5024\u306e\u5834\u5408\u306f\u30c7\u30fc\u30bf\u3092\u6b63\u898f\u5316\u3057\u3001\u30ab\u30c6\u30b4\u30ea\u30ab\u30eb\u306e\u5834\u5408\u306f\u30c7\u30fc\u30bf\u30bf\u30a4\u30d7\u3092\u5909\u63db\u3057\u307e\u3059\u3002\u307e\u305f\u3001\u7279\u5fb4\u91cf\u306e\u30bb\u30c3\u30c8\u3092\u4f5c\u6210\u3057\u3001\u7279\u5fb4\u91cf\u306e\u30bb\u30c3\u30c8\u304b\u3089\u30bf\u30fc\u30b2\u30c3\u30c8\u3092\u524a\u9664\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nnumeric_feats = [\"mobile_wt\", \"m_dep\", \"int_memory\", \"fc\", \"clock_speed\", \"talk_time\",\"n_cores\", \"sc_w\", \"sc_h\", \"ram\", \"px_width\",\"px_height\",\"pc\", \"battery_power\"]\n\ndataframe[numeric_feats] = dataframe[numeric_feats].apply(lambda x: (x - np.mean(x)) \/ (np.max(x) - np.min(x)))\n\ncategorical_feats = [\"blue\", \"four_g\", \"dual_sim\", \"wifi\", \"touch_screen\", \"three_g\",\"price_range\"]\ndataframe[categorical_feats] =  dataframe[categorical_feats].astype(\"category\")\n\nfeatures = numeric_feats + categorical_feats \nfeatures.remove(\"price_range\")\n  <\/code><\/pre>\n<\/div>\n<p>\u3053\u308c\u3067\u3001\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u3092\u8a18\u8ff0\u3057\u3001\u5206\u5e03\u3092\u78ba\u8a8d\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">dataframe[numeric_feats].describe()<\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/num.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/num.png\" alt=\"\" width=\"617\" height=\"256\" class=\"aligncenter size-full wp-image-27767\" srcset=\"\/wp-content\/uploads\/2021\/09\/num.png 617w, \/wp-content\/uploads\/2021\/09\/num-300x124.png 300w, \/wp-content\/uploads\/2021\/09\/num-600x249.png 600w\" sizes=\"(max-width: 617px) 100vw, 617px\" \/><\/a><\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">dataframe[categorical_feats].describe()<\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/cat.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/cat.png\" alt=\"\" width=\"617\" height=\"140\" class=\"aligncenter size-full wp-image-27769\" srcset=\"\/wp-content\/uploads\/2021\/09\/cat.png 617w, \/wp-content\/uploads\/2021\/09\/cat-300x68.png 300w, \/wp-content\/uploads\/2021\/09\/cat-600x136.png 600w\" sizes=\"(max-width: 617px) 100vw, 617px\" \/><\/a><\/p>\n<h4>\u30c7\u30fc\u30bf\u3092\u691c\u8a3c\u7528\u3068\u5b66\u7fd2\u7528\u306b\u5206\u3051\u308b<\/h4>\n<p>\u6b21\u306b\u3001\u5b66\u7fd2\u4e2d\u306b\u30c7\u30fc\u30bf\u3092\u30c6\u30b9\u30c8\u3059\u308b\u305f\u3081\u306e\u5c0f\u3055\u306a\u691c\u8a3c\u30bb\u30c3\u30c8\u3092\u4f5c\u6210\u3057\u3001\u30c7\u30fc\u30bf\u306b\u904e\u5270\u9069\u5408\u3057\u3066\u3044\u306a\u3044\u3053\u3068\u3092\u78ba\u8a8d\u3057\u307e\u3059\u3002\u3053\u3053\u3067\u306f\u3001\u30c7\u30fc\u30bf\u306e20\uff05\u3092\u691c\u8a3c\u30bb\u30c3\u30c8\u3068\u3057\u3066\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nval_dataframe = dataframe.sample(frac=0.2, random_state=1337)\ntrain_dataframe = dataframe.drop(val_dataframe.index)\n\nprint(\"Number of training samples:\", len(train_dataframe))\nprint(\"Number of validation samples:\", len(val_dataframe))\n  <\/code><\/pre>\n<\/div>\n<h4>Keras\u7528\u306e\u30c7\u30fc\u30bf\u306e\u6e96\u5099<\/h4>\n<p>\u3053\u308c\u306f\u30de\u30eb\u30c1\u30af\u30e9\u30b9\u306e\u5206\u985e\u554f\u984c\u306a\u306e\u3067 \u30bf\u30fc\u30b2\u30c3\u30c8\u3092\u30ef\u30f3\u30b7\u30e7\u30c3\u30c8\u30a8\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u306b\u5909\u63db\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u308c\u306b\u306f <code>tf.keras.utils.to_categorical<\/code> \u3092\u4f7f\u7528\u3057\u307e\u3059\u3002keras\u306fnumpy\u306e\u914d\u5217\u3092\u53d6\u308a\u8fbc\u3080\u306e\u3067\u3001pandas\u306e\u30c7\u30fc\u30bf\u30d5\u30ec\u30fc\u30e0\u3092numpy\u306b\u5909\u63db\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nY_train = tf.keras.utils.to_categorical(train_dataframe[\"price_range\"], num_classes=4)\nY_val = tf.keras.utils.to_categorical(val_dataframe[\"price_range\"], num_classes=4)\n\nX_train = train_dataframe[features].values\nX_val = val_dataframe[features].values\n  <\/code><\/pre>\n<\/div>\n<h3>\u30b9\u30c6\u30c3\u30d7 4: \u4e88\u6e2c<\/h3>\n<p>\u6b21\u306b\u3001\u4e88\u6e2c\u306e\u30d7\u30ed\u30bb\u30b9\u3092\u958b\u59cb\u3057\u307e\u3059\u3002<\/p>\n<h4>\u521d\u671f\u5316\u306b\u3064\u3044\u3066<\/h4>\n<p>\u4e88\u6e2c\u306e\u305f\u3081\u306e\u7c21\u5358\u306a\u30e2\u30c7\u30eb\u3092\u4f5c\u6210\u3057\u307e\u3059\u300212\u5c64\u306e\u9ad8\u5bc6\u5ea6\u306e\u5c64\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002\u306a\u304a\u3001\u5165\u529b\u6b21\u5143\u306f20\u3068\u3057\u3066\u3044\u307e\u3059\u3002\u305d\u3057\u3066\u3001\u30aa\u30fc\u30d0\u30fc\u30d5\u30a3\u30c3\u30c6\u30a3\u30f3\u30b0\u3092\u52a9\u3051\u308b\u30c9\u30ed\u30c3\u30d7\u30a2\u30a6\u30c8\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002\u6700\u5f8c\u306b\u3001\u3055\u3089\u306b\u3044\u304f\u3064\u304b\u306e\u96a0\u308c\u5c64\u3092\u8ffd\u52a0\u3057\u3001\u30bd\u30d5\u30c8\u30de\u30c3\u30af\u30b9\u3067\u7d42\u4e86\u3057\u307e\u3059\u3002\u30bd\u30d5\u30c8\u30de\u30c3\u30af\u30b9\u3067\u306f\u30014\u3064\u306e\u30af\u30e9\u30b9\u306b\u5bfe\u3059\u308b4\u3064\u306e\u78ba\u7387\u30b9\u30b3\u30a2\u304c\u5f97\u3089\u308c\u307e\u3059\u3002\u30e2\u30c7\u30eb\u306e\u69cb\u6210\u306f\u3001\u5c64\u3092\u8ffd\u52a0\u3057\u305f\u308a\u524a\u9664\u3057\u305f\u308a\u3057\u3066\u81ea\u7531\u306b\u5909\u66f4\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\n# define the keras model\nmodel =  keras.Sequential()\nmodel.add(layers.Dense(12, input_dim=20, activation='relu'))\nmodel.add(layers.Dropout(0.5))\nmodel.add(layers.Dense(8, activation='relu'))\nmodel.add(layers.Dense(4, activation='softmax'))\n  <\/code><\/pre>\n<\/div>\n<h4>\u5b66\u7fd2<\/h4>\n<p>\u6b21\u306b\u3001\u30e2\u30c7\u30eb\u3092\u30b3\u30f3\u30d1\u30a4\u30eb\u3057\u307e\u3059\u3002\u640d\u5931\u3068\u3057\u3066\u30ab\u30c6\u30b4\u30ea\u30ab\u30eb\u30af\u30ed\u30b9\u30a8\u30f3\u30c8\u30ed\u30d4\u30fc\u3092\u4f7f\u7528\u3057\u3001\u7cbe\u5ea6\u3067\u8a55\u4fa1\u3057\u307e\u3059\u3002\u7406\u60f3\u7684\u306b\u306f\u3001AUC\u3084\u305d\u306e\u4ed6\u306e\u9069\u5207\u3068\u601d\u308f\u308c\u308b\u6307\u6a19\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">model.compile(loss='categorical_crossentropy', optimizer='adam', metrics=['accuracy'])<\/code><\/pre>\n<\/div>\n<p>\u6b21\u306b\u3001200\u56de\u306e\u30a8\u30dd\u30c3\u30af\u3067\u30e2\u30c7\u30eb\u3092\u5b66\u7fd2\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nnum_epochs = 200 \nhistory = model.fit(X_train,\n                   Y_train,\n                   epochs=num_epochs ,\n                   validation_data=(X_val, Y_val))\n  <\/code><\/pre>\n<\/div>\n<div class=\"clipboard\">\n<pre><code class=\"language-bash\">\nEpoch 1\/200\n50\/50 [==============================] - 0s 2ms\/step - loss: 0.1648 - accuracy: 0.9431 - val_loss: 0.2359 - val_accuracy: 0.9125\nEpoch 2\/200\n50\/50 [==============================] - 0s 2ms\/step - loss: 0.1871 - accuracy: 0.9388 - val_loss: 0.1986 - val_accuracy: 0.9175\nEpoch 3\/200\n....\nEpoch 199\/200\n50\/50 [==============================] - 0s 1ms\/step - loss: 0.1245 - accuracy: 0.9575 - val_loss: 0.4880 - val_accuracy: 0.8075\nEpoch 200\/200\n50\/50 [==============================] - 0s 1ms\/step - loss: 0.1267 - accuracy: 0.9600 - val_loss: 0.4585 - val_accuracy: 0.8150\n  <\/code><\/pre>\n<\/div>\n<h4>\u8a55\u4fa1<\/h4>\n<p>\u6b21\u306b\u3001\u8a13\u7df4\u3068\u691c\u8a3c\u306e\u640d\u5931\u3068\u7cbe\u5ea6\u3092\u30d7\u30ed\u30c3\u30c8\u3057\u307e\u3059\u3002\u7406\u60f3\u7684\u306b\u306f\u3001\u640d\u5931\u304c\u6e1b\u5c11\u3057\u3001\u7cbe\u5ea6\u304c\u5411\u4e0a\u3059\u308b\u306f\u305a\u3067\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">history = history.history<\/code><\/pre>\n<\/div>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nimport matplotlib.pyplot as plt\n%matplotlib inline\nepochs = list(range(num_epochs))\nloss = history[\"loss\"]\nval_loss = history[\"val_loss\"]\nplt.plot(epochs, loss, 'bo', label=\"Training Loss\")\nplt.plot(epochs, val_loss, 'b', label=\"Validation Loss\")\n\nplt.title('Training and Validation Loss')\nplt.xlabel('Epochs')\nplt.ylabel('Loss Value')\nplt.legend()\nplt.show()\n  <\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/loss.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/loss.png\" alt=\"\" width=\"392\" height=\"278\" class=\"aligncenter size-full wp-image-27756\" srcset=\"\/wp-content\/uploads\/2021\/09\/loss.png 392w, \/wp-content\/uploads\/2021\/09\/loss-300x213.png 300w\" sizes=\"(max-width: 392px) 100vw, 392px\" \/><\/a><\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\nepochs = list(range(num_epochs))\naccuracy = history[\"accuracy\"]\nval_accuracy = history[\"val_accuracy\"]\nplt.plot(epochs, accuracy, 'bo', label=\"Accuracy\")\nplt.plot(epochs, val_accuracy, 'b', label=\"Val Accuracy\")\n\nplt.title('Training and Validation Accuracy')\nplt.xlabel('Epochs')\nplt.ylabel('Loss Value')\nplt.legend()\nplt.show()\n  <\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/accuracy.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/accuracy.png\" alt=\"\" width=\"398\" height=\"278\" class=\"aligncenter size-full wp-image-27768\" srcset=\"\/wp-content\/uploads\/2021\/09\/accuracy.png 398w, \/wp-content\/uploads\/2021\/09\/accuracy-300x210.png 300w\" sizes=\"(max-width: 398px) 100vw, 398px\" \/><\/a><\/p>\n<p>\u3053\u308c\u306f\u3001\u30e2\u30c7\u30eb\u304c\u30aa\u30fc\u30d0\u30fc\u30d5\u30a3\u30c3\u30c8\u3057\u3066\u3044\u308b\u3053\u3068\u3092\u610f\u5473\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u5834\u5408\u3001\u30a8\u30dd\u30c3\u30af\u6570\u3092\u6e1b\u3089\u3059\u3001\u5225\u306e\u640d\u5931\u95a2\u6570\u3092\u4f7f\u7528\u3059\u308b\u3001\u30c7\u30fc\u30bf\u3092\u8b70\u8ad6\u3059\u308b\u306a\u3069\u3001\u3044\u304f\u3064\u304b\u306e\u6226\u7565\u3092\u8a66\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h4>\u4e88\u6e2c<\/h4>\n<div class=\"clipboard\">\n<pre><code class=\"language-python\">\n# evaluate the keras model\ntest = pd.read_csv('test.csv')\ntest[numeric_feats] = test[numeric_feats].apply(lambda x: (x - np.mean(x)) \/ (np.max(x) - np.min(x)))\n\nif \"price_range\" in categorical_feats:\n  categorical_feats.remove(\"price_range\")\n\ntest[categorical_feats] =  test[categorical_feats].astype(\"category\")\nfeats = test[features].values\npredictions = model.predict(feats)\npredictions = np.argmax(predictions, axis=1)\n  <\/code><\/pre>\n<\/div>\n<p>\u6700\u5f8c\u306b\u30c6\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u30ed\u30fc\u30c9\u3057\u3066\u4e88\u6e2c\u3057\u307e\u3059\u3002keras\u306f\u5404\u30af\u30e9\u30b9\u306e\u78ba\u7387\u3092\u8fd4\u3059\u306e\u3067\u3001\u30af\u30e9\u30b9\u3092\u5f97\u308b\u305f\u3081\u306bargmax\u3092\u53d6\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h2>\u307e\u3068\u3081<\/h2>\n<p>\u3053\u306e\u8a18\u4e8b\u3067\u306f\u3001\u5206\u985e\u30bf\u30b9\u30af\u306e\u305f\u3081\u306b\u30b7\u30f3\u30d7\u30eb\u306a\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u8a13\u7df4\u3059\u308b\u65b9\u6cd5\u3092\u5b66\u3073\u307e\u3057\u305f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed\u30dc\u30c3\u30c8\u5de5\u5b66\u307e\u3067\u3001\u3055\u307e\u3056\u307e\u306a\u5206\u91ce\u3067\u305d\u306e\u52b9\u679c\u304c\u78ba\u8a8d\u3055\u308c\u3066\u3044\u307e\u3059\u3002 [&hellip;]<\/p>\n","protected":false},"author":41,"featured_media":49303,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1005],"tags":[],"class_list":["post-50750","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-1005"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT<\/title>\n<meta name=\"description\" content=\"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.griddb.net\/ja\/\u672a\u5206\u985e\/neural-networks-with-python-and-griddb\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"og:description\" content=\"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.griddb.net\/ja\/\u672a\u5206\u985e\/neural-networks-with-python-and-griddb\/\" \/>\n<meta property=\"og:site_name\" content=\"GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/griddbcommunity\/\" \/>\n<meta property=\"article:published_time\" content=\"2021-09-24T07:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-11-14T15:54:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"1920\" \/>\n\t<meta property=\"og:image:height\" content=\"1280\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"griddb-admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:site\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"griddb-admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"3\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/\"},\"author\":{\"name\":\"griddb-admin\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233\"},\"headline\":\"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\",\"datePublished\":\"2021-09-24T07:00:00+00:00\",\"dateModified\":\"2025-11-14T15:54:44+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/\"},\"wordCount\":100,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/griddb.net\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/\",\"url\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/\",\"name\":\"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT\",\"isPartOf\":{\"@id\":\"https:\/\/griddb.net\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg\",\"datePublished\":\"2021-09-24T07:00:00+00:00\",\"dateModified\":\"2025-11-14T15:54:44+00:00\",\"description\":\"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage\",\"url\":\"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg\",\"contentUrl\":\"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg\",\"width\":1920,\"height\":1280},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/griddb.net\/en\/#website\",\"url\":\"https:\/\/griddb.net\/en\/\",\"name\":\"GridDB: Open Source Time Series Database for IoT\",\"description\":\"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL\",\"publisher\":{\"@id\":\"https:\/\/griddb.net\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/griddb.net\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ja\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/griddb.net\/en\/#organization\",\"name\":\"Fixstars\",\"url\":\"https:\/\/griddb.net\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"contentUrl\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"width\":200,\"height\":83,\"caption\":\"Fixstars\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/griddbcommunity\/\",\"https:\/\/x.com\/GridDBCommunity\",\"https:\/\/www.linkedin.com\/company\/griddb-by-toshiba\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233\",\"name\":\"griddb-admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/en\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g\",\"caption\":\"griddb-admin\"},\"url\":\"https:\/\/griddb.net\/ja\/author\/griddb-admin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT","description":"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.griddb.net\/ja\/\u672a\u5206\u985e\/neural-networks-with-python-and-griddb\/","og_locale":"ja_JP","og_type":"article","og_title":"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT","og_description":"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed","og_url":"https:\/\/www.griddb.net\/ja\/\u672a\u5206\u985e\/neural-networks-with-python-and-griddb\/","og_site_name":"GridDB: Open Source Time Series Database for IoT","article_publisher":"https:\/\/www.facebook.com\/griddbcommunity\/","article_published_time":"2021-09-24T07:00:00+00:00","article_modified_time":"2025-11-14T15:54:44+00:00","og_image":[{"width":1920,"height":1280,"url":"https:\/\/griddb.net\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg","type":"image\/jpeg"}],"author":"griddb-admin","twitter_card":"summary_large_image","twitter_creator":"@GridDBCommunity","twitter_site":"@GridDBCommunity","twitter_misc":{"\u57f7\u7b46\u8005":"griddb-admin","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"3\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#article","isPartOf":{"@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/"},"author":{"name":"griddb-admin","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233"},"headline":"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af","datePublished":"2021-09-24T07:00:00+00:00","dateModified":"2025-11-14T15:54:44+00:00","mainEntityOfPage":{"@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/"},"wordCount":100,"commentCount":0,"publisher":{"@id":"https:\/\/griddb.net\/en\/#organization"},"image":{"@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg","inLanguage":"ja","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/","url":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/","name":"Python\u3068GridDB\u306b\u3088\u308b\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af | GridDB: Open Source Time Series Database for IoT","isPartOf":{"@id":"https:\/\/griddb.net\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage"},"image":{"@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg","datePublished":"2021-09-24T07:00:00+00:00","dateModified":"2025-11-14T15:54:44+00:00","description":"\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u904e\u53bb5\u5e74\u9593\u3067\u6a5f\u68b0\u5b66\u7fd2\u3068\u4e88\u6e2c\u30e2\u30c7\u30ea\u30f3\u30b0\u306e\u4e16\u754c\u3092\u5e2d\u5dfb\u3057\u307e\u3057\u305f\u3002\u30cb\u30e5\u30fc\u30e9\u30eb\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3001\u30c7\u30fc\u30bf\u306e\u8907\u96d1\u306a\u95a2\u4fc2\u3092\u5b66\u7fd2\u3059\u308b\u80fd\u529b\u3092\u6301\u3061\u3001\u91d1\u878d\u304b\u3089\u30ed","inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/"]}]},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/neural-networks-with-python-and-griddb\/#primaryimage","url":"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg","contentUrl":"\/wp-content\/uploads\/2021\/09\/board-game_1920x1280.jpeg","width":1920,"height":1280},{"@type":"WebSite","@id":"https:\/\/griddb.net\/en\/#website","url":"https:\/\/griddb.net\/en\/","name":"GridDB: Open Source Time Series Database for IoT","description":"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL","publisher":{"@id":"https:\/\/griddb.net\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/griddb.net\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ja"},{"@type":"Organization","@id":"https:\/\/griddb.net\/en\/#organization","name":"Fixstars","url":"https:\/\/griddb.net\/en\/","logo":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/","url":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","contentUrl":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","width":200,"height":83,"caption":"Fixstars"},"image":{"@id":"https:\/\/griddb.net\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/griddbcommunity\/","https:\/\/x.com\/GridDBCommunity","https:\/\/www.linkedin.com\/company\/griddb-by-toshiba"]},{"@type":"Person","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233","name":"griddb-admin","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/en\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g","caption":"griddb-admin"},"url":"https:\/\/griddb.net\/ja\/author\/griddb-admin\/"}]}},"_links":{"self":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50750","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/users\/41"}],"replies":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/comments?post=50750"}],"version-history":[{"count":1,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50750\/revisions"}],"predecessor-version":[{"id":51587,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50750\/revisions\/51587"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media\/49303"}],"wp:attachment":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media?parent=50750"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/categories?post=50750"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/tags?post=50750"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}