1、函数 matmul(a,b,name=None): 功能: 矩阵乘运算"""Multiplies matrix `a` by matrix `b`, producing `a` * `b`. tf.square(error) 功能:平方 tf.reduce_mean(error) 功能:均值 t ...
分类:
其他好文 时间:
2020-07-11 21:02:11
阅读次数:
68
使用bazel编译了tensorflow1.13.1,还差一个demo测试,在网上找了一个例程,但是不全,自己辛苦补全了,供大家参考学习。 #define COMPILER_MSVC #define NOMINMAX #define PLATFORM_WINDOWS // 指定使用tensorflo ...
分类:
编程语言 时间:
2020-07-10 21:11:12
阅读次数:
95
numpy、tensorflow手写SkipGram(没有negative sampling)和cbow: http://www.claudiobellei.com/2018/01/07/backprop-word2vec-python/ 这两种实现都需要动手算梯度,手动实现梯度下降,且不没有使用n ...
分类:
其他好文 时间:
2020-07-10 18:47:16
阅读次数:
53
# coding: utf-8 import tensorflow as tf import os os.environ["CUDA_VISIBLE_DEVICES"] = "-1" print(tf.__version__) print(tf.test.is_gpu_available()) fr ...
分类:
其他好文 时间:
2020-07-10 10:00:02
阅读次数:
62
# coding: utf-8 get_ipython().run_line_magic('matplotlib', 'notebook') import matplotlib.pyplot as plt import tensorflow as tf import tensorflow.contr ...
分类:
其他好文 时间:
2020-07-10 09:31:57
阅读次数:
78
启动远程服务 pip install --ignore-installed --upgrade tensorflow==1.10 pip install bert-serving-server pip install bert-serving-client #下载模型 mkdir model cd ...
分类:
其他好文 时间:
2020-07-09 15:21:36
阅读次数:
138
问题背景:python通过grpc调用tfserving报错, 提示:AttributeError: module 'tensorflow_serving.apis.prediction_service_pb2' has no attribute 'beta_create_PredictionSer ...
分类:
编程语言 时间:
2020-07-09 12:12:29
阅读次数:
130
官网:https://tensorflow.google.cn/tfx/guide/serving 步骤1:保存pb模型 # 为模型每一个参数添加name # ner demo: https://github.com/buppt/ChineseNER self.input_x = tf.placeh ...
分类:
Web程序 时间:
2020-07-08 15:34:47
阅读次数:
153
1,bazel编译时间过长,且最终显示不完全成功 问题原因,g++版本过新 把自己7.5版本的改为4.8.5版本。 参考链接:https://blog.csdn.net/sinat_35496345/article/details/80478622 ...
分类:
其他好文 时间:
2020-07-08 01:42:13
阅读次数:
86
// conda配置安装pytorch 1、新建环境,避免与基础环境出现冲突 conda create -n pytorch_gpu python=3.7 2、切换到pytorch环境 conda activate pytorch_gpu 3、安装基本框架 conda install pandasc ...
分类:
其他好文 时间:
2020-07-07 09:46:35
阅读次数:
117