本文整理了Java中de.tudarmstadt.ukp.dkpro.core.api.segmentation.type.Sentence.setEnd()
方法的一些代码示例,展示了Sentence.setEnd()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Sentence.setEnd()
方法的具体详情如下:
包路径:de.tudarmstadt.ukp.dkpro.core.api.segmentation.type.Sentence
类名称:Sentence
方法名:setEnd
暂无
代码示例来源:origin: de.tudarmstadt.ukp.dkpro.core/de.tudarmstadt.ukp.dkpro.core.api.segmentation-asl
/** @generated
* @param jcas JCas to which this Feature Structure belongs
* @param begin offset to the begin spot in the SofA
* @param end offset to the end spot in the SofA
*/
public Sentence(JCas jcas, int begin, int end) {
super(jcas);
setBegin(begin);
setEnd(end);
readObject();
}
代码示例来源:origin: dkpro/dkpro-core
/** @generated
* @param jcas JCas to which this Feature Structure belongs
* @param begin offset to the begin spot in the SofA
* @param end offset to the end spot in the SofA
*/
public Sentence(JCas jcas, int begin, int end) {
super(jcas);
setBegin(begin);
setEnd(end);
readObject();
}
代码示例来源:origin: UKPLab/argument-reasoning-comprehension-task
Integer end = sentenceBoundaries.get(1);
s.setBegin(begin);
s.setEnd(end);
s.addToIndexes();
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/de.tudarmstadt.ukp.clarin.webanno.tsv
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
break;
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
outSentence
.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i)).getEnd() + 1);
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
代码示例来源:origin: webanno/webanno
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
break;
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
tokensStored.get("t_" + firstTokenInSentence.get(i)).getEnd() + 1);
outSentence
.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1)).getEnd());
outSentence.addToIndexes();
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-io-tsv
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
break;
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
tokensStored.get("t_" + firstTokenInSentence.get(i)).getEnd() + 1);
outSentence
.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1)).getEnd());
outSentence.addToIndexes();
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-tsv
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
break;
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
outSentence
.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i)).getEnd() + 1);
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/de.tudarmstadt.ukp.clarin.webanno.conll
outSentence.setEnd(tokensStored.get("t_" + (tokensStored.size())).getEnd());
outSentence.addToIndexes();
break;
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" +(tokensStored.size())).getEnd());
outSentence.addToIndexes();
outSentence.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i))
.getBegin());
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
outSentence
.setBegin(tokensStored.get("t_" + firstTokenInSentence.get(i)).getEnd() + 1);
outSentence.setEnd(tokensStored.get("t_" + firstTokenInSentence.get(i + 1))
.getEnd());
outSentence.addToIndexes();
代码示例来源:origin: hltfbk/Excitement-Open-Platform
Sentence sentenceAnnot = new Sentence(aJCas);
sentenceAnnot.setBegin(dockedSentence.getCharOffsetStart());
sentenceAnnot.setEnd(dockedSentence.getCharOffsetEnd());
sentenceAnnot.addToIndexes();
代码示例来源:origin: webanno/webanno
sentence.getUimaSentence().setEnd(text.length() - 1);
sentence.getUimaSentence().addToIndexes();
prevSentence = sentence;
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-io-tsv
sentence.getUimaSentence().setEnd(text.length() - 1);
sentence.getUimaSentence().addToIndexes();
prevSentence = sentence;
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-io-tcf
outSentence.setEnd(tokenBeginPosition);
outSentence.addToIndexes();
tokenBeginPosition = tokenBeginPosition + 1;
代码示例来源:origin: de.tudarmstadt.ukp.dkpro.wsd/de.tudarmstadt.ukp.dkpro.wsd.io
sentenceAnnotation.setEnd(offset);
sentenceAnnotation.addToIndexes();
代码示例来源:origin: webanno/webanno
outSentence.setEnd(tokenBeginPosition);
outSentence.addToIndexes();
tokenBeginPosition = tokenBeginPosition + 1;
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/webanno-io-tcf
private void convertSentences(JCas aJCas, TextCorpus aCorpusData, Map<String, Token> aTokens) {
if (aCorpusData.getSentencesLayer() == null) {
// No layer to read from.
return;
}
for (int i = 0; i < aCorpusData.getSentencesLayer().size(); i++) {
eu.clarin.weblicht.wlfxb.tc.api.Token[] sentencesTokens = aCorpusData
.getSentencesLayer().getTokens(aCorpusData.getSentencesLayer().getSentence(i));
Sentence outSentence = new Sentence(aJCas);
outSentence.setBegin(aTokens.get(sentencesTokens[0].getID()).getBegin());
outSentence.setEnd(
aTokens.get(sentencesTokens[sentencesTokens.length - 1].getID()).getEnd());
outSentence.addToIndexes();
}
}
代码示例来源:origin: webanno/webanno
private void convertSentences(JCas aJCas, TextCorpus aCorpusData, Map<String, Token> aTokens) {
if (aCorpusData.getSentencesLayer() == null) {
// No layer to read from.
return;
}
for (int i = 0; i < aCorpusData.getSentencesLayer().size(); i++) {
eu.clarin.weblicht.wlfxb.tc.api.Token[] sentencesTokens = aCorpusData
.getSentencesLayer().getTokens(aCorpusData.getSentencesLayer().getSentence(i));
Sentence outSentence = new Sentence(aJCas);
outSentence.setBegin(aTokens.get(sentencesTokens[0].getID()).getBegin());
outSentence.setEnd(
aTokens.get(sentencesTokens[sentencesTokens.length - 1].getID()).getEnd());
outSentence.addToIndexes();
}
}
代码示例来源:origin: de.tudarmstadt.ukp.dkpro.core/de.tudarmstadt.ukp.dkpro.core.io.tcf-asl
private void convertSentences(JCas aJCas, TextCorpus aCorpusData,
Map<String, Token> aTokens)
{
if (aCorpusData.getSentencesLayer() == null) {
// No layer to read from.
return;
}
for (int i = 0; i < aCorpusData.getSentencesLayer().size(); i++) {
eu.clarin.weblicht.wlfxb.tc.api.Token[] sentencesTokens = aCorpusData
.getSentencesLayer().getTokens(aCorpusData.getSentencesLayer().getSentence(i));
Sentence outSentence = new Sentence(aJCas);
outSentence.setBegin(aTokens.get(sentencesTokens[0].getID()).getBegin());
outSentence.setEnd(aTokens.get(sentencesTokens[sentencesTokens.length - 1].getID())
.getEnd());
outSentence.addToIndexes();
}
}
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/de.tudarmstadt.ukp.clarin.webanno.tcf
outSentence.setEnd(tokenBeginPosition);
outSentence.addToIndexes();
tokenBeginPosition = tokenBeginPosition +1;
代码示例来源:origin: de.tudarmstadt.ukp.clarin.webanno/de.tudarmstadt.ukp.clarin.webanno.tcf
private void convertSentences(JCas aJCas, TextCorpus aCorpusData,
Map<String, Token> aTokens)
{
if (aCorpusData.getSentencesLayer() == null) {
// No layer to read from.
return;
}
for (int i = 0; i < aCorpusData.getSentencesLayer().size(); i++) {
eu.clarin.weblicht.wlfxb.tc.api.Token[] sentencesTokens = aCorpusData
.getSentencesLayer().getTokens(aCorpusData.getSentencesLayer().getSentence(i));
Sentence outSentence = new Sentence(aJCas);
outSentence.setBegin(aTokens.get(sentencesTokens[0].getID()).getBegin());
outSentence.setEnd(aTokens.get(sentencesTokens[sentencesTokens.length - 1].getID())
.getEnd());
outSentence.addToIndexes();
}
}
代码示例来源:origin: hltfbk/Excitement-Open-Platform
sentAnnotation.setEnd(sent.getEnd());
sentAnnotation.addToIndexes();
内容来源于网络,如有侵权,请联系作者删除!