是否可以在Tensorflow Playground中提供csv输入?

时间:2018-12-13 06:46:21

标签: javascript python typescript

功能不同,所需的数据定义也不同。
我浏览了dataset.ts文件,可以在这里查看:dataset.ts
我试图像这样操纵文件:

export function classifyTwoGaussData(numSamples: number, noise: number):
    Example2D[] {
  let points: Example2D[] = [];

  let varianceScale = d3.scale.linear().domain([0, .5]).range([0.5, 4]);
  let variance = varianceScale(noise);

  function genGauss(cx: number, cy: number, label: number) {
    for (let i = 0; i < numSamples / 2; i++) {
      let x = normalRandom(cx, variance);
      let y = normalRandom(cy, variance);
      points.push({x, y, label});
    }
  }

  genGauss(2, 2, 1); // Gaussian with positive examples.
  genGauss(-2, -2, -1); // Gaussian with negative examples.
  console.log(points);
  return points;
}

控制台窗口中的输出显示:Array(200),当我添加单行genGauss(-2, 2, 0);时,我得到了Array(300)

但是我不知道我是否有一个完整的csv输入和一个单独的csv,如何在运动场数据集中设置它,以便可以可视化我的tensorflow模型的训练。

示例数据如下:

input1  input2  input3  input4  input5  input6  input7  output
1.20047 1.20047 1.20045 1.20045 1.200059606178815   0.0003585714285714223   -3.791789292925229e-06  -1.0
1.20088 1.20088 1.20087 1.20087 1.200329737452543   0.0003835714285714117   6.180045764568489e-07   -1.0
1.20007 1.20023 1.20007 1.20007 1.200243158301695   0.0004278571428571306   4.129903631236368e-06   0.0
1.20022 1.20023 1.20022 1.20023 1.2002387722011298  0.0004271428571428402   7.19294850670973e-06    1.0
1.20023 1.20029 1.20023 1.20029 1.2002558481340868  0.0004192857142857093   9.916424565845627e-06   1.0
1.20046 1.20046 1.20046 1.20046 1.2003238987560578  0.00042499999999998485  1.259884292315837e-05   0.0
1.20053 1.20053 1.20053 1.20053 1.2003925991707052  0.0004049999999999966   1.523257396764079e-05   0.0

请提出建议并帮助我。我很困惑,因为tensorflow团队没有任何答案,甚至他们也不在乎有人是否向他们询问与自己产品有关的问题。

0 个答案:

没有答案
相关问题