【问题标题】:How to set the overwrite option in Mahout?如何在 Mahout 中设置覆盖选项?
【发布时间】:2014-08-22 02:59:02
【问题描述】:

在许多情况下,需要覆盖输出目录,例如 Converting Sequence files into Sparse Vectors。 我想知道如何设置overwrite 选项。

P.S.:我已经能够通过 CLI 执行相同的操作,但我需要使用 API。

【问题讨论】:

    标签: java apache maven mahout overwrite


    【解决方案1】:

    Sparse vectors from Sequence files中使用的API调用如下:

    String[] vectorizingParameters = {"-i", seqDirectory,
                                      "-o", vectorsDirectory,
                                      "-ow"};
    SparseVectorsFromSequenceFiles thisSparseVectorizer = new SparseVectorsFromSequenceFiles();
    thisSparseVectorizer.run(vectorizingParameters);
    

    String[] vectorizingParameters 末尾的 -ow 会被解析为覆盖选项。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-10-19
      • 2011-03-01
      • 2018-04-09
      • 2013-01-01
      • 2013-10-27
      • 1970-01-01
      • 2019-01-23
      相关资源
      最近更新 更多