user_wwq
3 years ago
| 2 | 2 | { |
| 3 | 3 | "cell_type": "code", |
| 4 | 4 | "execution_count": 2, |
| 5 | "id": "aa198a5c", | |
| 5 | "id": "dc3b490c", | |
| 6 | 6 | "metadata": {}, |
| 7 | 7 | "outputs": [ |
| 8 | 8 | { |
| 9 | 9 | "name": "stderr", |
| 10 | 10 | "output_type": "stream", |
| 11 | 11 | "text": [ |
| 12 | "2022-07-11 18:02:37.037995: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory\n", | |
| 13 | "2022-07-11 18:02:37.038035: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.\n" | |
| 12 | "2022-07-21 21:07:47.961364: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory\n", | |
| 13 | "2022-07-21 21:07:47.961398: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.\n" | |
| 14 | 14 | ] |
| 15 | 15 | }, |
| 16 | 16 | { |
| 38 | 38 | }, |
| 39 | 39 | { |
| 40 | 40 | "cell_type": "code", |
| 41 | "execution_count": 4, | |
| 42 | "id": "0edef439", | |
| 43 | "metadata": {}, | |
| 44 | "outputs": [], | |
| 45 | "source": [ | |
| 46 | "model_PATH='./src/output/models/model2000.ckpt'\n", | |
| 41 | "execution_count": 3, | |
| 42 | "id": "b3725e89", | |
| 43 | "metadata": {}, | |
| 44 | "outputs": [], | |
| 45 | "source": [ | |
| 46 | "model_PATH='./src/output/models/model227000.ckpt'\n", | |
| 47 | 47 | "out_PATH='./results/test_output.png'\n", |
| 48 | 48 | "IMAGE_SZ = 128" |
| 49 | 49 | ] |
| 50 | 50 | }, |
| 51 | 51 | { |
| 52 | 52 | "cell_type": "code", |
| 53 | "execution_count": 5, | |
| 54 | "id": "2b461a3a", | |
| 53 | "execution_count": 4, | |
| 54 | "id": "db355c13", | |
| 55 | 55 | "metadata": {}, |
| 56 | 56 | "outputs": [], |
| 57 | 57 | "source": [ |
| 67 | 67 | }, |
| 68 | 68 | { |
| 69 | 69 | "cell_type": "code", |
| 70 | "execution_count": 12, | |
| 71 | "id": "57ac9ea3", | |
| 70 | "execution_count": 5, | |
| 71 | "id": "921f7ee4", | |
| 72 | 72 | "metadata": {}, |
| 73 | 73 | "outputs": [], |
| 74 | 74 | "source": [ |
| 80 | 80 | }, |
| 81 | 81 | { |
| 82 | 82 | "cell_type": "code", |
| 83 | "execution_count": 7, | |
| 84 | "id": "41670ee1", | |
| 83 | "execution_count": 6, | |
| 84 | "id": "e654a93b", | |
| 85 | 85 | "metadata": {}, |
| 86 | 86 | "outputs": [], |
| 87 | 87 | "source": [ |
| 94 | 94 | }, |
| 95 | 95 | { |
| 96 | 96 | "cell_type": "code", |
| 97 | "execution_count": 8, | |
| 98 | "id": "93bb30e9", | |
| 97 | "execution_count": 7, | |
| 98 | "id": "c7c78bd4", | |
| 99 | 99 | "metadata": {}, |
| 100 | 100 | "outputs": [], |
| 101 | 101 | "source": [ |
| 116 | 116 | }, |
| 117 | 117 | { |
| 118 | 118 | "cell_type": "code", |
| 119 | "execution_count": 10, | |
| 120 | "id": "0c3712cb", | |
| 119 | "execution_count": 8, | |
| 120 | "id": "112cb0a2", | |
| 121 | 121 | "metadata": {}, |
| 122 | 122 | "outputs": [], |
| 123 | 123 | "source": [ |
| 140 | 140 | }, |
| 141 | 141 | { |
| 142 | 142 | "cell_type": "code", |
| 143 | "execution_count": 13, | |
| 144 | "id": "720ed042", | |
| 143 | "execution_count": 9, | |
| 144 | "id": "bd28ad9e", | |
| 145 | 145 | "metadata": {}, |
| 146 | 146 | "outputs": [ |
| 147 | 147 | { |
| 157 | 157 | "WARNING:tensorflow:From /home/jovyan/work/src/model.py:79: conv2d_transpose (from tensorflow.python.keras.legacy_tf_layers.convolutional) is deprecated and will be removed in a future version.\n", |
| 158 | 158 | "Instructions for updating:\n", |
| 159 | 159 | "Use `tf.keras.layers.Conv2DTranspose` instead.\n", |
| 160 | "INFO:tensorflow:Restoring parameters from ./src/output/models/model2000.ckpt\n" | |
| 160 | "INFO:tensorflow:Restoring parameters from ./src/output/models/model227000.ckpt\n" | |
| 161 | 161 | ] |
| 162 | 162 | }, |
| 163 | 163 | { |
| 164 | 164 | "name": "stderr", |
| 165 | 165 | "output_type": "stream", |
| 166 | 166 | "text": [ |
| 167 | "2022-07-11 18:03:35.362439: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory\n", | |
| 168 | "2022-07-11 18:03:35.362468: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)\n", | |
| 169 | "2022-07-11 18:03:35.362489: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (notebook): /proc/driver/nvidia/version does not exist\n", | |
| 170 | "2022-07-11 18:03:35.362763: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations: AVX2 AVX512F FMA\n", | |
| 167 | "2022-07-21 21:07:52.404094: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory\n", | |
| 168 | "2022-07-21 21:07:52.404122: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)\n", | |
| 169 | "2022-07-21 21:07:52.404144: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (notebook): /proc/driver/nvidia/version does not exist\n", | |
| 170 | "2022-07-21 21:07:52.404443: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations: AVX2 AVX512F FMA\n", | |
| 171 | 171 | "To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.\n", |
| 172 | "2022-07-11 18:03:35.385100: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2500000000 Hz\n", | |
| 173 | "2022-07-11 18:03:35.399501: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x60885a0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| 174 | "2022-07-11 18:03:35.399527: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n" | |
| 172 | "2022-07-21 21:07:52.426464: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2500000000 Hz\n", | |
| 173 | "2022-07-21 21:07:52.440496: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x441b180 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| 174 | "2022-07-21 21:07:52.440522: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n" | |
| 175 | 175 | ] |
| 176 | 176 | }, |
| 177 | 177 | { |
| 178 | 178 | "name": "stdout", |
| 179 | 179 | "output_type": "stream", |
| 180 | 180 | "text": [ |
| 181 | "Runned time: 4.791 s\n" | |
| 181 | "Runned time: 0.204 s\n" | |
| 182 | 182 | ] |
| 183 | 183 | }, |
| 184 | 184 | { |
| 187 | 187 | "{'Output': './results/test_output.png'}" |
| 188 | 188 | ] |
| 189 | 189 | }, |
| 190 | "execution_count": 13, | |
| 190 | "execution_count": 9, | |
| 191 | 191 | "metadata": {}, |
| 192 | 192 | "output_type": "execute_result" |
| 193 | 193 | } |
| 1 | 1 | Photo: |
| 2 | 2 | name: Photo |
| 3 | 3 | value_type: img |
| 4 | description: 请传入128*128的图片 | |
| 4 | description: 请传入128*128的待扩展图片 | |
| 5 | 5 | output: |
| 6 | 6 | Output: |
| 7 | 7 | name: Output |
| 7 | 7 | import os |
| 8 | 8 | import sys |
| 9 | 9 | |
| 10 | model_PATH='./src/output/models/model2000.ckpt' | |
| 10 | model_PATH='./src/output/models/model227000.ckpt' | |
| 11 | 11 | out_PATH='./results/test_output.png' |
| 12 | 12 | IMAGE_SZ = 128 |
| 13 | 13 |
Binary diff not shown
Binary diff not shown
Binary diff not shown
Binary diff not shown
Binary diff not shown