/** * Sets the format of the input instances. * * @param instanceInfo an Instances object containing the input instance * structure (any instances contained in the object are ignored - * only the structure is required). * @return true if the outputFormat may be collected immediately * @throws Exception if the input format can't be set successfully */ @Override public boolean setInputFormat(Instances instanceInfo) throws Exception { super.setInputFormat(instanceInfo); m_containsStringAtts = instanceInfo.checkForStringAttributes(); setOutputFormat(instanceInfo); m_subSample = new Object[m_SampleSize]; m_currentInst = 0; m_random = new Random(m_RandomSeed); return true; }
/** * Sets the format of the input instances. * * @param instanceInfo an Instances object containing the input instance * structure (any instances contained in the object are ignored - * only the structure is required). * @return true if the outputFormat may be collected immediately * @throws Exception if the input format can't be set successfully */ @Override public boolean setInputFormat(Instances instanceInfo) throws Exception { super.setInputFormat(instanceInfo); m_containsStringAtts = instanceInfo.checkForStringAttributes(); setOutputFormat(instanceInfo); m_subSample = new Object[m_SampleSize]; m_currentInst = 0; m_random = new Random(m_RandomSeed); return true; }