Java 类weka.core.xml.XMLInstances 实例源码

项目:repo.kmeanspp.silhouette_score    文件:XRFFLoader.java   
/**
  * Determines and returns (if possible) the structure (internally the 
  * header) of the data set as an empty set of instances.
  *
  * @return             the structure of the data set as an empty set 
  *                 of Instances
  * @throws IOException     if an error occurs
  */
 public Instances getStructure() throws IOException {
   if (m_sourceReader == null)
     throw new IOException("No source has been specified");

   if (m_structure == null) {
     try {
m_XMLInstances = new XMLInstances(m_sourceReader);
m_structure    = new Instances(m_XMLInstances.getInstances(), 0);
     }
     catch (IOException ioe) {
// just re-throw it
throw ioe;
     }
     catch (Exception e) {
throw new RuntimeException(e);
     }
   }

   return new Instances(m_structure, 0);
 }
项目:repo.kmeanspp.silhouette_score    文件:XRFFSaver.java   
/**
 * Resets the Saver
 */
@Override
public void resetOptions() {
  super.resetOptions();

  if (getCompressOutput()) {
    setFileExtension(XRFFLoader.FILE_EXTENSION_COMPRESSED);
  } else {
    setFileExtension(XRFFLoader.FILE_EXTENSION);
  }

  try {
    m_XMLInstances = new XMLInstances();
  } catch (Exception e) {
    m_XMLInstances = null;
  }
}
项目:autoweka    文件:XRFFLoader.java   
/**
  * Determines and returns (if possible) the structure (internally the 
  * header) of the data set as an empty set of instances.
  *
  * @return             the structure of the data set as an empty set 
  *                 of Instances
  * @throws IOException     if an error occurs
  */
 public Instances getStructure() throws IOException {
   if (m_sourceReader == null)
     throw new IOException("No source has been specified");

   if (m_structure == null) {
     try {
m_XMLInstances = new XMLInstances(m_sourceReader);
m_structure    = new Instances(m_XMLInstances.getInstances(), 0);
     }
     catch (IOException ioe) {
// just re-throw it
throw ioe;
     }
     catch (Exception e) {
throw new RuntimeException(e);
     }
   }

   return new Instances(m_structure, 0);
 }
项目:autoweka    文件:XRFFSaver.java   
/**
 * Resets the Saver 
 */
public void resetOptions() {
  super.resetOptions();

  if (getCompressOutput())
    setFileExtension(XRFFLoader.FILE_EXTENSION_COMPRESSED);
  else
    setFileExtension(XRFFLoader.FILE_EXTENSION);

  try {
    m_XMLInstances = new XMLInstances();
  }
  catch (Exception e) {
    m_XMLInstances = null;
  }
}
项目:umple    文件:XRFFLoader.java   
/**
  * Determines and returns (if possible) the structure (internally the 
  * header) of the data set as an empty set of instances.
  *
  * @return             the structure of the data set as an empty set 
  *                 of Instances
  * @throws IOException     if an error occurs
  */
 public Instances getStructure() throws IOException {
   if (m_sourceReader == null)
     throw new IOException("No source has been specified");

   if (m_structure == null) {
     try {
m_XMLInstances = new XMLInstances(m_sourceReader);
m_structure    = new Instances(m_XMLInstances.getInstances(), 0);
     }
     catch (IOException ioe) {
// just re-throw it
throw ioe;
     }
     catch (Exception e) {
throw new RuntimeException(e);
     }
   }

   return new Instances(m_structure, 0);
 }
项目:umple    文件:XRFFSaver.java   
/**
 * Resets the Saver
 */
@Override
public void resetOptions() {
  super.resetOptions();

  if (getCompressOutput()) {
    setFileExtension(XRFFLoader.FILE_EXTENSION_COMPRESSED);
  } else {
    setFileExtension(XRFFLoader.FILE_EXTENSION);
  }

  try {
    m_XMLInstances = new XMLInstances();
  } catch (Exception e) {
    m_XMLInstances = null;
  }
}
项目:jbossBA    文件:XRFFLoader.java   
/**
  * Determines and returns (if possible) the structure (internally the 
  * header) of the data set as an empty set of instances.
  *
  * @return             the structure of the data set as an empty set 
  *                 of Instances
  * @throws IOException     if an error occurs
  */
 public Instances getStructure() throws IOException {
   if (m_sourceReader == null)
     throw new IOException("No source has been specified");

   if (m_structure == null) {
     try {
m_XMLInstances = new XMLInstances(m_sourceReader);
m_structure    = new Instances(m_XMLInstances.getInstances(), 0);
     }
     catch (IOException ioe) {
// just re-throw it
throw ioe;
     }
     catch (Exception e) {
throw new RuntimeException(e);
     }
   }

   return new Instances(m_structure, 0);
 }
项目:jbossBA    文件:XRFFSaver.java   
/**
 * Resets the Saver 
 */
public void resetOptions() {
  super.resetOptions();

  if (getCompressOutput())
    setFileExtension(XRFFLoader.FILE_EXTENSION_COMPRESSED);
  else
    setFileExtension(XRFFLoader.FILE_EXTENSION);

  try {
    m_XMLInstances = new XMLInstances();
  }
  catch (Exception e) {
    m_XMLInstances = null;
  }
}