Class CnnSentenceDataSetIterator

  • All Implemented Interfaces:
    Serializable, Iterator<org.nd4j.linalg.dataset.DataSet>, org.nd4j.linalg.dataset.api.iterator.DataSetIterator

    public class CnnSentenceDataSetIterator
    extends Object
    implements org.nd4j.linalg.dataset.api.iterator.DataSetIterator
    See Also:
    Serialized Form
    • Method Detail

      • loadSingleSentence

        public org.nd4j.linalg.api.ndarray.INDArray loadSingleSentence​(String sentence)
        Generally used post training time to load a single sentence for predictions
      • getLabels

        public List<String> getLabels()
        Specified by:
        getLabels in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • hasNext

        public boolean hasNext()
        Specified by:
        hasNext in interface Iterator<org.nd4j.linalg.dataset.DataSet>
      • next

        public org.nd4j.linalg.dataset.DataSet next()
        Specified by:
        next in interface Iterator<org.nd4j.linalg.dataset.DataSet>
      • next

        public org.nd4j.linalg.dataset.DataSet next​(int num)
        Specified by:
        next in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • inputColumns

        public int inputColumns()
        Specified by:
        inputColumns in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • totalOutcomes

        public int totalOutcomes()
        Specified by:
        totalOutcomes in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • resetSupported

        public boolean resetSupported()
        Specified by:
        resetSupported in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • asyncSupported

        public boolean asyncSupported()
        Specified by:
        asyncSupported in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • reset

        public void reset()
        Specified by:
        reset in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • batch

        public int batch()
        Specified by:
        batch in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • setPreProcessor

        public void setPreProcessor​(org.nd4j.linalg.dataset.api.DataSetPreProcessor preProcessor)
        Specified by:
        setPreProcessor in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • getPreProcessor

        public org.nd4j.linalg.dataset.api.DataSetPreProcessor getPreProcessor()
        Specified by:
        getPreProcessor in interface org.nd4j.linalg.dataset.api.iterator.DataSetIterator
      • remove

        public void remove()
        Specified by:
        remove in interface Iterator<org.nd4j.linalg.dataset.DataSet>