org.apache.ctakes.typesystem.type.textsem.IdentifiedAnnotation.getType()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(3.9k)|赞(0)|评价(0)|浏览(47)

本文整理了Java中org.apache.ctakes.typesystem.type.textsem.IdentifiedAnnotation.getType()方法的一些代码示例,展示了IdentifiedAnnotation.getType()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。IdentifiedAnnotation.getType()方法的具体详情如下:
包路径:org.apache.ctakes.typesystem.type.textsem.IdentifiedAnnotation
类名称:IdentifiedAnnotation
方法名:getType

IdentifiedAnnotation.getType介绍

[英]getter for typeID - gets The type of named entity (e.g. drug, disorder, ...)
[中]typeID的getter-获取命名实体的类型(例如药物、疾病等)

代码示例

代码示例来源:origin: apache/tika

metadata.add(CTAKES_META_PREFIX + annotation.getType().getShortName(), annotationBuilder.toString());

代码示例来源:origin: org.apache.ctakes/ctakes-assertion

logger.debug(key + " not found in gold annotations ");
} else {
  Feature feature = goldAnnotation.getType().getFeatureByBaseName(classifierType);
  goldLabel = getFeatureValue(feature, categoryClass, goldAnnotation);
  logger.info(key + " not found in system annotations ");
} else {
  Feature feature = systemAnnotation.getType().getFeatureByBaseName(classifierType);
  systemLabel = getFeatureValue(feature, categoryClass, systemAnnotation);

代码示例来源:origin: apache/ctakes

logger.debug(key + " not found in gold annotations ");
} else {
  Feature feature = goldAnnotation.getType().getFeatureByBaseName(classifierType);
  goldLabel = getFeatureValue(feature, categoryClass, goldAnnotation);
  logger.info(key + " not found in system annotations ");
} else {
  Feature feature = systemAnnotation.getType().getFeatureByBaseName(classifierType);
  systemLabel = getFeatureValue(feature, categoryClass, systemAnnotation);

代码示例来源:origin: apache/ctakes

public void debugAnnotationsInCas(JCas jcas, IdentifiedAnnotation annotation,
  String label)
{
 CasIndexer<IdentifiedAnnotation> i = new CasIndexer<IdentifiedAnnotation>(jcas, annotation.getType());
 
 StringBuilder b = new StringBuilder();
 b.append(String.format("<<<<<%n### TARGET ###%nclass: %s%naddress: %d%nvalue: %s%n### END TARGET ###%n>>>>>%n%n", annotation.getClass().getName(), annotation.getAddress(), annotation.toString()));
 
 String debugOutput = i.convertToDebugOutput(label, annotation);
 
 b.append(debugOutput);
 
 logger.debug(b.toString());
 
}

代码示例来源:origin: org.apache.ctakes/ctakes-assertion

logger.debug(key + " not found in gold annotations ");
} else {
  Feature feature = goldAnnotation.getType().getFeatureByBaseName(classifierType);
  goldLabel = getFeatureValue(feature, categoryClass, goldAnnotation);
  logger.info(key + " not found in system annotations ");
} else {
  Feature feature = systemAnnotation.getType().getFeatureByBaseName(classifierType);
  systemLabel = getFeatureValue(feature, categoryClass, systemAnnotation);

代码示例来源:origin: org.apache.ctakes/ctakes-assertion

public void debugAnnotationsInCas(JCas jcas, IdentifiedAnnotation annotation,
  String label)
{
 CasIndexer<IdentifiedAnnotation> i = new CasIndexer<IdentifiedAnnotation>(jcas, annotation.getType());
 
 StringBuilder b = new StringBuilder();
 b.append(String.format("<<<<<%n### TARGET ###%nclass: %s%naddress: %d%nvalue: %s%n### END TARGET ###%n>>>>>%n%n", annotation.getClass().getName(), annotation.getAddress(), annotation.toString()));
 
 String debugOutput = i.convertToDebugOutput(label, annotation);
 
 b.append(debugOutput);
 
 logger.debug(b.toString());
 
}

代码示例来源:origin: apache/ctakes

logger.debug(key + " not found in gold annotations ");
} else {
  Feature feature = goldAnnotation.getType().getFeatureByBaseName(classifierType);
  goldLabel = getFeatureValue(feature, categoryClass, goldAnnotation);
  logger.info(key + " not found in system annotations ");
} else {
  Feature feature = systemAnnotation.getType().getFeatureByBaseName(classifierType);
  systemLabel = getFeatureValue(feature, categoryClass, systemAnnotation);

代码示例来源:origin: com.github.lafa.tikaNoExternal/tika-parsers

metadata.add(CTAKES_META_PREFIX + annotation.getType().getShortName(), annotationBuilder.toString());

代码示例来源:origin: org.apache.tika/tika-parsers

metadata.add(CTAKES_META_PREFIX + annotation.getType().getShortName(), annotationBuilder.toString());

相关文章

微信公众号

最新文章

更多