CoolMind


If you cannot measure it, you cannot improve it.

Who passes the additional argument to my `fn` ?

Recently in an implementation of a functionality, following error keeps showing and drives me crazy. Traceback (most recent call last): File "te...

GeoHash algorithm

最近遇到一个问题:K 个距离最近商铺问题。用户实时汇报其坐标,需要返回距离其最近的 K 个商铺 问题。 方法一 方法二 在 8 个方向移动 参考 商铺的量很大,如果每次都遍历计算一遍计算复杂度很高。 class Shop { Pos pos; // ...

Merge tensorflow models

Sometimes you want to transfer certain weights from multiple models into a single model or just want to merge multiple models. There are at least t...

Estimator core in evaluator

记录另外一次 Estimator 的 core 排查。 背景 复现代码 Lessons learned 参考 背景 我们用户使用 Estimator 都是使用 chief + worker + ps + evaluator 的形式。在线上偶发的 evaluator 这...

Estimator OOM after export model frequently

最近用户反馈一个 Estimator 的问题,OOM (out of memory)。由于完全使用的是 Estimator 的逻辑,出错问题 排查了很久。最终使用多个工具找到问题的根源。ps_util 打印内存,objgraph 寻找内存泄露。 背景 序列化问题 模型导出 ...

Feature column a tutorial

特征列 feature column 深度神经网络输入 Feature columns 引入 Tensorflow 和其它库 构造示例数据 示例数据 演示几种不同类型的特征列 数值列 (Numeric columns) 分桶列 (Bucketized co...

Estimator a tutorial

介绍 Estiamtor 相关知识。 背景 非 Estimator 基于 Parameter server 架构的分布式学习 Estimator 行为控制 构造 Estimator 使用创建的 Estimator ...

Python unittest and unittest.mock

Each language has its own known testing framework which makes writing test cases easier. In Python, the standard and built-in are unittest module. ...