摘要: 问题:在使用keras-bert 导入预训练的模型时, 报错Layer model_1 expects 3 inputs, but it received 2 input tensors 导入代码: bert_model = load_trained_model_from_checkpoint(co 阅读全文
posted @ 2020-10-30 11:00 liangxinxin 阅读(2563) 评论(0) 推荐(0) 编辑
摘要: cypher MATCH path =(n:实体标签)--(m) WHERE n.name='aa' with m.type as mtype,collect(path)[..m] as paths return paths; MATCH(n:实体标签{name:'aa'})-[r]-(m) wit 阅读全文
posted @ 2020-08-11 16:47 liangxinxin 阅读(525) 评论(0) 推荐(0) 编辑
摘要: 1.安装好neo4j数据库 2.安装apoc 3.python调用apoc from py2neo import Graph from neo4j import GraphDatabase class Neo4jSearch(): def __init__(self): self.driver = 阅读全文
posted @ 2020-08-10 14:34 liangxinxin 阅读(1121) 评论(0) 推荐(0) 编辑
摘要: 查看代码提交日志 git log 查看代码的远程地址 git remote -v 代码下载: git clone url 文件添加到git git add file 代码提交 git commit -m '说明' 代码push到远程仓库 git push 代码回退 HEAD^ 与 HEAD~1等价, 阅读全文
posted @ 2020-07-30 16:36 liangxinxin 阅读(99) 评论(0) 推荐(0) 编辑
摘要: 背景:需要对neo4j 查询结果,这里返回的是path做解析,返回json给前端,前端展示到页面,类似neo4j浏览器方式。 给出一个实体标签,及实体name,查询与该节点有一度关系的节点m,并且限制m的条数。 分析 1.需要查询一度关系 2.限制返回条数 3.返回结果如何将path解析为json数 阅读全文
posted @ 2020-07-30 11:15 liangxinxin 阅读(742) 评论(3) 推荐(0) 编辑
摘要: python filter():用于过滤序列,返回符合条件的结果 filter(function, iterable) def is_odd(n): return n % 2 == 1 newlist = filter(is_odd, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]) 阅读全文
posted @ 2020-07-29 18:02 liangxinxin 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 刚知道postman可以在发送请求前执行js脚本,因为接口是加密的,之前每次测试都是先将加密代码注释掉,上线时再放开,所以就想是否能直接用postman发送带加密的请求。 加密请求需求 需要对一段json直接做加密,而非一个字段,如直接对 {"sign":{"action":"query","nam 阅读全文
posted @ 2020-07-28 11:58 liangxinxin 阅读(3408) 评论(0) 推荐(0) 编辑
摘要: batch_x=[1,2,3,4,5,6,7,8,9] indices = np.random.permutation(len(batch_x)) batch_x = batch_x[indices]发生错误:TypeError:only integer scalar arrays can be c 阅读全文
posted @ 2020-06-08 17:20 liangxinxin 阅读(4328) 评论(0) 推荐(0) 编辑
摘要: 详细见:https://zhuanlan.zhihu.com/p/34408181 在知乎上看到的可以把标注偏置讲的比较明白的一篇讲解 阅读全文
posted @ 2020-06-04 14:06 liangxinxin 阅读(410) 评论(0) 推荐(0) 编辑
摘要: 情感分析_情感词典合集:链接: https://pan.baidu.com/s/1urqLnI1X-hWbH3Kq8QGmMg 提取码: bpjh 注:本人mac电脑,下载下来有一些文件因为编码格式看不了,发到苹果手机目前能看 import chardetf = open(file, 'rb').r 阅读全文
posted @ 2020-05-26 17:30 liangxinxin 阅读(461) 评论(0) 推荐(0) 编辑