{"id":22283733,"url":"https://github.com/veaba/tensorflow-docs","last_synced_at":"2025-03-25T19:51:28.508Z","repository":{"id":104582229,"uuid":"211214211","full_name":"veaba/tensorflow-docs","owner":"veaba","description":":cn:  Tensorflow python新版本（2.0） 的API中文文档，自己用的（开始时间：2019年9月27日09:56:10，优秀：原来的超过24小时的爬取2.5k个文件提高到现在44~47分钟完成）","archived":false,"fork":false,"pushed_at":"2020-01-01T10:06:07.000Z","size":17412,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-30T17:39:38.234Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://veaba.github.io/tensorflow-docs/tf/Overview.html","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/veaba.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-09-27T01:49:28.000Z","updated_at":"2021-03-17T01:59:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"90ad1235-0dbc-4676-8b6c-2c371d62e983","html_url":"https://github.com/veaba/tensorflow-docs","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veaba%2Ftensorflow-docs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veaba%2Ftensorflow-docs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veaba%2Ftensorflow-docs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/veaba%2Ftensorflow-docs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/veaba","download_url":"https://codeload.github.com/veaba/tensorflow-docs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245535427,"owners_count":20631293,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-03T16:41:56.338Z","updated_at":"2025-03-25T19:51:28.484Z","avatar_url":"https://github.com/veaba.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tensorflow-docs\npython 的 RC 2.0 版本 中文API文档,进行中，基于vuepress 作为静态驱动器主题、python作为项目脚本通过自动化Selenium爬取内容、百度翻译API  \n\n## 关于本项目\n- 基于python+vuepress搭建 Google Tensorflow 最新版本 2.0 API 中文文档\n- 直接copy 自己用过的vuepress theme\n- 所有开发文档见`/scripts` 目录\n- 内容可通过脚本一键填充\n- 用到爬虫工具等手段，需要一点python 编程知识\n- 用到机器翻译，本项目用到百度翻译API 作为翻译支撑（因为：free~~哈哈）\n- 完全很方便的可将本项目拓展到i18n项目，只要你想的话可以很快\n    - 写i18n字典，见`/script/i18n.py`\n    - 新起docs目录\n    - 调整`docs/.vupress`里面的配置文件即可\n### 统计\n\n|类别|统计|\n|---|---|\n|tensorflow 文档文件个数（含丢弃）|2767|\n|tensorflow 文档总行数|169618|\n|tensorflow 总字符数|9487919|\n|tensorflow 实际翻译字符长度|235238|\n\n### 英文版网页展示图（在dev分支）\n![](images/web-ui.png)\n\n\n### 中文版网页展示图（master、docs分支）\n![](images/zh-ui.png)\n\n\n\n### 项目起初一些废话\n\n- 预计半年到一年的时间\n- 2019年9月29日15:31:42 今天 中途有人告诉我API 有中文版的，呃呃呃？都做到这程度了，继续下去呗，反正也没人看咯。\n- RC 1.5 API https://www.tensorflow.org/versions/r1.15/api_docs/python/tf  1.5\n- 基于 2.0：https://www.tensorflow.org/versions/r2.0/api_docs/python/tf 2.0\n- www.w3cschool.cn 一年前的文档： https://www.w3cschool.cn/tensorflow_python/ \n- w3c 也是基于 这个翻译的：https://devdocs.io/tensorflow~python/\n- 找不到官网的markdown文件在哪~~ 喵\n- 3000+ 个文件要翻译，噗。。。\n- 想要机器翻译来完成，实在是整个文档太过于庞大了。\n\n### 模块划分\n\n|模块|英文迁移|中文|\n|---|---|---|\n|tf|√||\n|tf.audio|√||\n|tf.autograph|√||\n|tf.bitwise|√||\n|tf.compat|√||\n|tf.config|√||\n|tf.data|√||\n|tf.debugging|√||\n|tf.distribute|√||\n|tf.dtypes|√||\n|tf.errors|√||\n|tf.estimator|√||\n|tf.experimental|√||\n|tf.feature_column|√||\n|tf.graph_util|√||\n|tf.image|√||\n|tf.initializers|√||\n|tf.io|√||\n|tf.keras|√||\n|tf.linalg|√||\n|tf.lite|√||\n|tf.lookup|√||\n|tf.losses|√||\n|tf.math|√||\n|tf.metrics|√||\n|tf.nest|√||\n|tf.nn|√||\n|tf.optimizers|√||\n|tf.quantization|√||\n|tf.queue|√||\n|tf.ragged|√||\n|tf.random|√||\n|tf.raw_ops|√||\n|tf.sets|v||\n|tf.signal|√||\n|tf.sparse|√||\n|tf.strings|√||\n|tf.summary|√||\n|tf.sysconfig|√||\n|tf.test|√||\n|tf.tpu|√||\n|tf.train|√||\n|tf.version|√||\n|tf.xla|√||\n\n\n### 导致解析出错的地址：\n- √ docs\\tf.compat\\v1\\estimator\\tpu\\experimental\\EmbeddingConfigSpec.md\n- √ docs\\tf.compat\\v1\\keras\\initializers\\Constant.md\n- √ docs\\tf.distribute\\experimental\\ParameterServerStrategy.md\n- √ docs\\tf.estimator\\VocabInfo.md\n- √ docs\\tf.linalg\\LinearOperatorHouseholder.md\n- √ docs\\tf.linalg\\LinearOperatorToeplitz.md\n- √ docs\\tf.ragged\\stack.md\n- √ docs\\tf.keras\\backend\\transpose.md\n- √ docs\\tf.compat\\v1\\flags\\tf_decorator\\rewrap.md\n- √ docs\\tf.compat\\v1\\estimator\\BaselineClassifier.md\n- √ docs\\tf.compat\\v1\\estimator\\BaselineEstimator.md\n- √ docs\\tf.compat\\v1\\estimator\\BaselineRegressor.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNClassifier.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNEstimator.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNLinearCombinedClassifier.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNLinearCombinedEstimator.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNLinearCombinedRegressor.md\n- √ docs\\tf.compat\\v1\\estimator\\DNNRegressor.md\n- √ docs\\tf.compat\\v1\\estimator\\Estimator.md\n- √ docs\\tf.compat\\v1\\estimator\\LinearClassifier.md\n- √ docs\\tf.compat\\v1\\estimator\\LinearRegressor.md\n- √ docs\\tf.compat\\v1\\space_to_batch.md\n- √ docs\\tf.estimator\\Estimator.md\n- √ docs\\tf.compat\\v1\\DeviceSpec.md\n- √ docs\\tf.compat\\v1\\gradients.md\n- √ docs\\tf.compat\\v1\\queue\\Overview.md\n- √ docs\\tf.keras\\backend\\floatx.md\n- √ docs\\tf.math\\log.md\n\n\n## vuepress theme 阅读规范\n\n- 下划线，代表有链接 todo\n\n## TODO 额外：尝试迁移前端项目到Python平台\n\n已迁移到新的仓库：[pypackjs](https://github.com/veaba/pypackjs)\n\n\u003e vuepress build 构建本项目需要3个小时，所以想找一种替代方案来完成，之前尝试过python 的线程池 将工作效率提高20倍以上，这或许是一种方式  \n\n2.6K个文件，生成js等静态文件，多达5.2k多，需要等待3个小时才能打包完毕。\n\n这对于node来说毕竟也是单线程。\n\n如果将node 这一套打包机制迁移到多线程的编程语言平台上，会不会很快呢？\n\n因为对于前端打包机制不太清楚，但理论上应该是：\n\n1. 根据文件构建关系\n2. 构建内联和引用\n3. 根据html结构生成语法树，然后给vue 的SPA应用使用的\n4. vuepress 通过一些工具类（本质上也就是正则的方式）将markdown文件翻译为HTML文件\n\n我的构想是，python其实可以调用js平台处理一些事情，这样是可以配合webpack打包机制+python 多线程（之前享受过线程池带来的快感）来处理文件的转化，速度会不会更快呢？\n\n而重点是:\n1. vuepress 项目文件关系如何连接\n2. 怎么将md文件转为html文件\n3. html转为语法树的js文件\n\n工作内容（几乎要翻写一个webpack了）：\n\n- style load\n- sass load\n- styl load\n- scss load\n- ts load\n- vue load，打包vue项目\n- url load\n- file load\n- markdown-load \u003e\n    - markdown-html\n- html-\u003eAST\n- js-load 解析js文件,但也是可以调用JS引擎做一些事情\n- v-node load\n- python 版本的js压缩工具  \n\n分析了一波，所以需要看一下vuepres 的核心源码是怎么做的，并迁移到python平台\n\n## 工作进度\n\n\n### 新增分支\n- 新增dev分支，保留原始docs en 文档，用来生成中文文档\n- 新增tag origin-bookmark ，保留原始文档  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveaba%2Ftensorflow-docs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fveaba%2Ftensorflow-docs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fveaba%2Ftensorflow-docs/lists"}