• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java XLog类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.deckfour.xes.model.XLog的典型用法代码示例。如果您正苦于以下问题:Java XLog类的具体用法?Java XLog怎么用?Java XLog使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



XLog类属于org.deckfour.xes.model包,在下文中一共展示了XLog类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: extractXESLog

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
/**
 * Generates XES log based on the given inputs, namely: 
 * Domain Ontology, OBDA Model, and annotation information
 * 
 * @author Ario Santoso ([email protected] / [email protected])
 * @param domainOntology
 * @param obdaModel
 * @param annotation
 * @return event log - XLog
 * @throws InvalidDataSourcesNumberException 
 * @throws OWLException 
 * @throws InvalidAnnotationException 
 * @throws XESLogExtractionFailureException 
 * @deprecated this one is only maintained for backward compatibility with the other OnProm plug in, at some point it should be removed
 */
@Deprecated
public static XLog extractXESLog(OWLOntology domainOntology, OBDAModel obdaModel, AnnotationQueries annotation) 
		throws InvalidDataSourcesNumberException, InvalidAnnotationException, OWLException, XESLogExtractionFailureException, OBDAException, MalformedQueryException{

	List<OBDADataSource> odsList = obdaModel.getSources();
	if(odsList.size() > 1)
		throw new InvalidDataSourcesNumberException(odsList.size());
	
	//Construct EBDA Model
	logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Start constucting an EBDA Model"));
	LEObjectFactory leFact = LEObjectFactory.getInstance();
	EBDAModelNaiveImpl ebdaModel = leFact.createEBDAModelNaiveImpl();
	
	//add data source information to the EBDA Model
	ebdaModel.addSource(odsList.get(0));
	
	logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Construct the mappings for the EBDA Model"));
	//add new mapping based on the annotation information
	ebdaModel.addMapping(domainOntology, obdaModel, annotation);
	
	logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish constucting an EBDA Model"));

	return extractXESLog(ebdaModel);
}
 
开发者ID:onprom,项目名称:onprom,代码行数:40,代码来源:XESLogExtractorExperimental.java


示例2: getXESLog17

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
/**
 * 
 * Generates XES log based on the given particular OBDA model that connects a 
 * Database to the Event Ontology (i.e., EBDA).
 * 
 * @author Ario Santoso ([email protected] / [email protected])
 * @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that 
 * 						connects a Database to the Event Ontology
 * @return event log - XLog
 * @throws OWLException 
 */
public XLog getXESLog17(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
	
	logger.info(String.format(
			LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
	
	EBDAReasonerImplWithParallelProcessing ebdaR = new EBDAReasonerImplWithParallelProcessing(ebdaModel);
	ebdaR.setExecutionLogListener(this);
	
	try{
		//Create XLogOnProm 
		XLogOnProm xlog = ebdaR.extractXLog();
		if(xlog == null) 
			throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
		
		logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));

		//return the log
		return xlog;
	
	} catch (OWLException e) {
		e.printStackTrace();
		throw new XESLogExtractionFailureException();
	}
}
 
开发者ID:onprom,项目名称:onprom,代码行数:36,代码来源:XESLogExtractorExperimental.java


示例3: extractOnPromXESLogUsingParallelAndOptimizedXAttributesProcessing

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
/**
 * 
 * Generates XES log based on the given particular OBDA model that connects a 
 * Database to the Event Ontology (i.e., EBDA).
 * 
 * <br /><br />
 * Feature(s)/Note(s):
 * <ul>
 * 		<li>It encodes/extracts the XAttributes information (i.e., key, type, values) in/from the Attributes URI</li>
 * 		<li>It must use EBDAModelWithOptimizedXAttributesEncoding</li>
 * 		<li>It runs some tasks in parallel</li>
 * </ul>
 * 
 * @author Ario Santoso ([email protected] / [email protected])
 * @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that 
 * 						connects a Database to the Event Ontology
 * @return event log - XLog
 * @throws OWLException 
 */
public XLog extractOnPromXESLogUsingParallelAndOptimizedXAttributesProcessing(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
	
	logger.info(String.format(
			LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
	
	EBDAReasonerImplWithParallelProcessing ebdaR = new EBDAReasonerImplWithParallelProcessing(ebdaModel);
	ebdaR.setExecutionLogListener(this);
	
	try{
		//Create XLogOnProm 
		XLogOnProm xlog = ebdaR.extractXLog();
		if(xlog == null) 
			throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
		
		logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));

		return xlog;
	
	} catch (OWLException e) {
		e.printStackTrace();
		throw new XESLogExtractionFailureException();
	}
}
 
开发者ID:onprom,项目名称:onprom,代码行数:43,代码来源:XESLogExtractor.java


示例4: mineProcessTree

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
public ProcessTree mineProcessTree(UIPluginContext context, XLog log, boolean structure, MiningSettings params, XEventClassifier xEventClassifier) {
    LogPreprocessing logPreprocessing = new LogPreprocessing();
    log = logPreprocessing.preprocessLog(context, log);

    System.setOut(new PrintStream(new OutputStream() {
        @Override
        public void write(int b) throws IOException {}
    }));

    IMProcessTree miner = new IMProcessTree();
    if(miningParameters == null) {
        miningParameters = new MiningParametersIMc();
        miningParameters.setClassifier(xEventClassifier);
    }
    ProcessTree result = miner.mineProcessTree(log, miningParameters);
    logPreprocessing.removedAddedElements(result);

    System.setOut(new PrintStream(new FileOutputStream(FileDescriptor.out)));

    return result;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:23,代码来源:InductiveMinerIMcWrapper.java


示例5: createGraph

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public Graph createGraph(XLog log, String event_label) {
    Graph graph = new Graph();

    ArrayList<XEvent> pre_window = new ArrayList<>(window_size);
    ArrayList<XEvent> post_window = new ArrayList<>(window_size);
    XEvent center_element = null;

    for(XTrace trace : log) {
        pre_window.clear();
        post_window.clear();
        center_element = null;
        for(int i = 0; i < trace.size(); i++) {
            center_element = shiftWindows(pre_window, post_window, center_element, trace.get(i));
            if(center_element != null) {
                System.out.println(toString(pre_window) + " " + toString(center_element) + " " + toString(post_window));
            }
        }
    }

    return graph;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:22,代码来源:GraphFactory.java


示例6: minePetrinet

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
public PetrinetWithMarking minePetrinet(UIPluginContext context, XLog log, boolean structure, MiningSettings params, XEventClassifier xEventClassifier) {
    LogPreprocessing logPreprocessing = new LogPreprocessing();
    log = logPreprocessing.preprocessLog(context, log);

    BPMNMinerPlugin bpmnMinerPlugin = new BPMNMinerPlugin();
    BPMNDiagram diagram = bpmnMinerPlugin.mineBPMNModel(context, log);

    if (structure) {
        try {
            StructuringService structuring = new StructuringService();
            diagram = structuring.structureDiagram(diagram);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

    BPMNToPetriNetConverter.convert(diagram);

    Object[] objects = BPMNToPetriNetConverter.convert(diagram);
    logPreprocessing.removedAddedElements((Petrinet) objects[0]);

    context.addConnection(new InitialMarkingConnection((Petrinet) objects[0], (Marking) objects[1]));
    context.addConnection(new FinalMarkingConnection((Petrinet) objects[0], (Marking) objects[2]));
    return new PetrinetWithMarking((Petrinet) objects[0], (Marking) objects[1], (Marking) objects[2]);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:27,代码来源:BPMNMinerAlgorithmWrapper.java


示例7: minePetrinet

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
public PetrinetWithMarking minePetrinet(UIPluginContext context, XLog log, boolean structure, MiningSettings params, XEventClassifier xEventClassifier) {
    LogPreprocessing logPreprocessing = new LogPreprocessing();
    log = logPreprocessing.preprocessLog(context, log);

    System.setOut(new PrintStream(new OutputStream() {
        @Override
        public void write(int b) throws IOException {}
    }));

    IMPetriNet miner = new IMPetriNet();
    if(miningParameters == null) {
        miningParameters = new MiningParametersIMa();
        miningParameters.setClassifier(xEventClassifier);
    }
    Object[] result = miner.minePetriNetParameters(context, log, miningParameters);
    logPreprocessing.removedAddedElements((Petrinet) result[0]);

    System.setOut(new PrintStream(new FileOutputStream(FileDescriptor.out)));

    return new PetrinetWithMarking((Petrinet) result[0], (Marking) result[1], (Marking)result[2]);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:23,代码来源:InductiveMinerIMaWrapper.java


示例8: removeInfrequentBehaviour

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public static XLog removeInfrequentBehaviour(PluginContext context, XEventClassifier xEventClassifier, XLog log, Automaton<String> automaton, double lowerbound, double upperbound, boolean exception, boolean excludeTraces) throws HighThresholdException {

        double originalEvents = countEvents(log);

        XLog result = filter(context, xEventClassifier, log, automaton, excludeTraces);
//        XLog result = filter(context, xEventClassifier, log, automaton, false);
        double resultEvents = countEvents(result);

        if(exception) {
            if (resultEvents > 0.0) {
                if (resultEvents / originalEvents < 0.5 && lowerbound < upperbound) {
                    System.out.println("error1");
                    throw new HighThresholdException();
                }
                return result;
            } else {
                throw new HighThresholdException();
            }
        }else {
            return result;
        }

    }
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:24,代码来源:AutomatonInfrequentBehaviourRemover.java


示例9: constructMapping

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
private static TransEvClassMapping constructMapping(Petrinet net, XLog log, XEventClass dummyEvClass) {
    TransEvClassMapping mapping = new TransEvClassMapping(xEventClassifier, dummyEvClass);

    XLogInfo summary = XLogInfoFactory.createLogInfo(log, xEventClassifier);

    for (Transition t : net.getTransitions()) {
        boolean mapped = false;

        for (XEventClass evClass : summary.getEventClasses().getClasses()) {
            String id = evClass.getId();

            if (t.getLabel().equals(id)) {
                mapping.put(t, evClass);
                mapped = true;
                break;
            }
        }

        if (!mapped) {
            mapping.put(t, dummyEvClass);
        }

    }

    return mapping;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:27,代码来源:ComputeMeasurment.java


示例10: constructMapping

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
private static TransEvClassMapping constructMapping(Petrinet net, XEventClassifier xEventClassifier, XLog log, XEventClass dummyEvClass) {
    TransEvClassMapping mapping = new TransEvClassMapping(xEventClassifier, dummyEvClass);

    XLogInfo summary = XLogInfoFactory.createLogInfo(log, xEventClassifier);

    for (Transition t : net.getTransitions()) {
        boolean mapped = false;

        for (XEventClass evClass : summary.getEventClasses().getClasses()) {
            String id = evClass.getId();

            if (t.getLabel().equals(id)) {
                mapping.put(t, evClass);
                mapped = true;
                break;
            }
        }

        if (!mapped) {
            mapping.put(t, dummyEvClass);
        }

    }

    return mapping;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:27,代码来源:DAFSABasedFitness.java


示例11: computeMeasurement

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
    public Measure computeMeasurement(UIPluginContext pluginContext, XEventClassifier xEventClassifier, PetrinetWithMarking petrinetWithMarking, MiningAlgorithm miningAlgorithm, XLog log) {
        Measure measure = new Measure();

        if(petrinetWithMarking == null) return measure;

        try {
            BPMNDiagram bpmn = PetriNetToBPMNConverter.convert(petrinetWithMarking.getPetrinet(), petrinetWithMarking.getInitialMarking(), petrinetWithMarking.getFinalMarking(), false);
//            BPMNCleaner.clean(bpmn);
//            BPMNSimplifier.simplify(bpmn);
            ComplexityCalculator cc = new ComplexityCalculator(bpmn);
            measure.addMeasure("size", cc.computeSize());
            measure.addMeasure("cfc", cc.computeCFC());
            measure.addMeasure("struct.", cc.computeStructuredness());
            measure.addMeasure("duplicates", cc.computeDuplicates());
            return measure;
        } catch( Exception e ) { return measure; }

    }
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:20,代码来源:BPMNComplexity.java


示例12: filterLog

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public XLog filterLog(XLog rawlog) {
    XLog log = rawlog;
    XFactory factory = new XFactoryNaiveImpl();
    LogOptimizer logOptimizer = new LogOptimizer(factory);
    log = logOptimizer.optimizeLog(log);

    XFactoryRegistry.instance().setCurrentDefault(factory);
    LogModifier logModifier = new LogModifier(factory, XConceptExtension.instance(), XTimeExtension.instance(), logOptimizer);
    logModifier.insertArtificialStartAndEndEvent(log);

    Automaton<String> automatonOriginal = automatonFactory.generate(log);

    double[] arcs = infrequentBehaviourFilter.discoverArcs(automatonOriginal, 1.0);

    NoiseFilterUI noiseUI = new NoiseFilterUI();
    NoiseFilterResult result = noiseUI.showGUI(this, arcs, automatonOriginal.getNodes());

    return infrequentBehaviourFilter.filterLog(new FakePluginContext(), rawlog, result);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:20,代码来源:InfrequentBehaviourFilterCommandLine.java


示例13: showGUI

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public ConceptualModel showGUI(XLog log, int algorithm) throws NoEntityException {

        List<String> allAttributes = discoverERmodel.generateAllAttributes(log);
        DiscoverERmodel_UI_ignoreAttributes ignoreGui = new DiscoverERmodel_UI_ignoreAttributes(allAttributes);

        /*
         * Step 1: discover primary keys
		 */
        UnifiedMap<String, Data> data = discoverERmodel.generateData(log, ignoreGui.getIgnoreAttributes());

        List<DiscoverERmodel.PrimaryKeyData> pKeyData = DiscoverERmodel.PrimaryKeyData.getData(data);
        DiscoverERmodel_UI_primaryKeys pKeyGui = new DiscoverERmodel_UI_primaryKeys(pKeyData);

        // get user selection
        Map<Set<String>, Set<String>> group = pKeyGui.getSelection();

        discoverERmodel.setPrimaryKeysEntityName(generateEntitiesNames(group));
        ConceptualModel concModel = discoverERmodel.createConceptualModel(group, data);

        return discoverERmodel.showGUI(concModel, discoverERmodel.getPrimaryKeys_entityName(), algorithm);
    }
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:22,代码来源:DiscoverERModel_UI.java


示例14: computeFitness

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
private PNRepResult computeFitness(UIPluginContext context, PetrinetWithMarking petrinetWithMarking, XLog log) {
    Petrinet petrinet = petrinetWithMarking.getPetrinet();
    Marking initialMarking = petrinetWithMarking.getInitialMarking();
    Marking finalMarking = petrinetWithMarking.getFinalMarking();

    context.addConnection(new FinalMarkingConnection(petrinet, finalMarking));

    PetrinetReplayerWithILP replayer = new PetrinetReplayerWithILP();

    XEventClass dummyEvClass = new XEventClass("DUMMY",99999);

    Map<Transition, Integer> transitions2costs = constructTTCMap(petrinet);
    Map<XEventClass, Integer> events2costs = constructETCMap(petrinet, log, dummyEvClass);

    parameters = constructParameters(transitions2costs, events2costs, petrinet, initialMarking, finalMarking);
    mapping = constructMapping(petrinet, log, dummyEvClass);

    try {
        return replayer.replayLog(context, petrinet, log, mapping, parameters);
    } catch (AStarException | ArrayIndexOutOfBoundsException e) {
        e.printStackTrace();
    }

    return null;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:26,代码来源:ComputeMeasurment.java


示例15: removeRedundantPathToEnd

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
private BPMNDiagram removeRedundantPathToEnd(BPMNDiagram subProcess, XLog log, Set<String> bpmnDiagrams) {
    Set<String> possibleActivitiesToCheck = new UnifiedSet<String>();

    for (XTrace trace : log) {
        XEvent last = null;
        for (XEvent event : trace) {
            if (last != null) {
                String name = xce.extractName(event);
                if (bpmnDiagrams.contains(name)) {
                    possibleActivitiesToCheck.add(xce.extractName(last));
                    break;
                }
            }
            last = event;
        }
    }

    return removePath(subProcess, possibleActivitiesToCheck);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:20,代码来源:BPMNSubProcessMiner.java


示例16: main

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public static void main(String[] args) throws Exception {
        XFactory factory = new XFactoryNaiveImpl();
//        String[] logNames = new String[] {"BPI2017"};
        String[] logNames = new String[] {"BPI2011", "BPI2012", "BPI2013_cp", "BPI2013_i", "BPI2014", "BPI2015-1", "BPI2015-2", "BPI2015-3", "BPI2015-4", "BPI2015-5", "BPI2017", "Road", "Sepsis"};
//        String[] logNames = new String[] {"BPI2012", "BPI2013_cp", "BPI2013_i", "BPI2014", "BPI2015-1", "BPI2015-2", "BPI2015-3", "BPI2015-4", "BPI2015-5", "BPI2017", "Road", "Sepsis"};

        for(int i = logNames.length - 1; i >= 0; i--) {
            logName = logNames[i];
            XLog log = LogImporter.importFromFile(factory, "/Volumes/Data/SharedFolder/Logs/Label/" + logName + ".xes.gz");
//            LogModifier logModifier = new LogModifier(factory, XConceptExtension.instance(), XTimeExtension.instance(), new LogOptimizer());
//            logModifier.insertArtificialStartAndEndEvent(log);

            LabelFilter labelFilter = new LabelFilter(
//                    new XEventAndClassifier(new XEventNameClassifier()));
                    new XEventAndClassifier(new XEventNameClassifier(), new XEventLifeTransClassifier()));

            log = labelFilter.filterLog(log);

            xce.assignName(log, xce.extractName(log) + " (Label)");

            if (labelFilter.label_removed > 0) {
//                log = logModifier.removeArtificialStartAndEndEvent(log);
                LogImporter.exportToFile("/Volumes/Data/SharedFolder/Logs/Label/" + logName + " " + testName + ".xes.gz", log);
            }
        }
    }
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:27,代码来源:LabelFilter.java


示例17: isInterruptingEventSubProcess

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
public boolean isInterruptingEventSubProcess(BPMNDiagram process, BPMNDiagram subProcessDiagram, Activity subProcess, Map<Entity, XLog> logs,
                                             Entity parentEntity, double tolerance) {

    Set<Activity> pre = bpmnAnalizer.findLastActivitiesExcludeANDGateway(process);

    boolean checkStart = false;
    if (!pre.contains(subProcess)) return false;
    else if (pre.size() > 1) checkStart = true;

    if (checkStart) {
        Set<Activity> last = bpmnAnalizer.findLastActivities(subProcessDiagram);
        Set<String> eventNames = new UnifiedSet<String>(last.size());
        for (Activity activity : last) {
            eventNames.add(bpmnAnalizer.extractActivityLabel(activity));
        }

        if (percentageProcessInstanceEnd(parentEntity, eventNames, logs) >= 1 - tolerance) return true;
    }

    return false;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:22,代码来源:SubProcessTypeDiscoverer.java


示例18: mineProcessTree

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
public ProcessTree mineProcessTree(UIPluginContext context, XLog log, boolean structure, MiningSettings params, XEventClassifier xEventClassifier) {
    LogPreprocessing logPreprocessing = new LogPreprocessing();
    log = logPreprocessing.preprocessLog(context, log);

    System.setOut(new PrintStream(new OutputStream() {
        @Override
        public void write(int b) throws IOException {}
    }));

    IMProcessTree miner = new IMProcessTree();
    if(miningParameters == null) {
        miningParameters = new MiningParametersIM();
        miningParameters.setClassifier(xEventClassifier);
    }
    ProcessTree result = miner.mineProcessTree(log, miningParameters);
    logPreprocessing.removedAddedElements(result);

    System.setOut(new PrintStream(new FileOutputStream(FileDescriptor.out)));

    return result;
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:23,代码来源:InductiveMinerIMWrapper.java


示例19: minePetrinet

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
@Override
public PetrinetWithMarking minePetrinet(UIPluginContext context, XLog log, boolean structure, MiningSettings params, XEventClassifier xEventClassifier) {
    LogPreprocessing logPreprocessing = new LogPreprocessing();
    log = logPreprocessing.preprocessLog(context, log);

    System.setOut(new PrintStream(new OutputStream() {
        @Override
        public void write(int b) throws IOException {}
    }));

    IMPetriNet miner = new IMPetriNet();
    if(miningParameters == null) {
        miningParameters = new MiningParametersIMc();
        miningParameters.setClassifier(xEventClassifier);
    }
    Object[] result = miner.minePetriNetParameters(context, log, miningParameters);
    logPreprocessing.removedAddedElements((Petrinet) result[0]);

    System.setOut(new PrintStream(new FileOutputStream(FileDescriptor.out)));

    return new PetrinetWithMarking((Petrinet) result[0], (Marking) result[1], (Marking)result[2]);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:23,代码来源:InductiveMinerIMcWrapper.java


示例20: discoverPetrinet

import org.deckfour.xes.model.XLog; //导入依赖的package包/类
private PetrinetWithMarking discoverPetrinet(UIPluginContext context, MiningAlgorithm miningAlgorithm, XLog log, boolean isStructured, XEventClassifier xEventClassifier) {
    PetrinetWithMarking petrinetWithMarking = miningAlgorithm.minePetrinet(context, log, isStructured, null, xEventClassifier);
    Petrinet petrinet = petrinetWithMarking.getPetrinet();
    Marking initialMarking = petrinetWithMarking.getInitialMarking();
    Marking finalMarking = constructFinalMarking(petrinet);

    for (Transition t : petrinet.getTransitions()) {
        if (t.getLabel().contains("###$$$%%%$$$###START###$$$%%%$$$###")) {
            t.setInvisible(true);
            t.getAttributeMap().put("ProM_Vis_attr_label", "source");
        }else if (t.getLabel().contains("###$$$%%%$$$###END###$$$%%%$$$###")) {
            t.setInvisible(true);
            t.getAttributeMap().put("ProM_Vis_attr_label", "sink");
        }else if (t.getLabel().toLowerCase().endsWith("+complete")) {
            t.getAttributeMap().put("ProM_Vis_attr_label", t.getLabel().substring(0, t.getLabel().toLowerCase().indexOf("+complete")));
        } else if (t.getLabel().toLowerCase().endsWith("+start")) {
            t.getAttributeMap().put("ProM_Vis_attr_label", t.getLabel().substring(0, t.getLabel().toLowerCase().indexOf("+start")));
        }
    }

    context.getProvidedObjectManager().createProvidedObject("PetriNet", petrinet, Petrinet.class, context);
    context.addConnection(new InitialMarkingConnection(petrinet, initialMarking));
    context.addConnection(new FinalMarkingConnection(petrinet, finalMarking));

    return new PetrinetWithMarking(petrinet, initialMarking, finalMarking);
}
 
开发者ID:raffaeleconforti,项目名称:ResearchCode,代码行数:27,代码来源:ComputeMeasurment.java



注:本文中的org.deckfour.xes.model.XLog类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java CustomerInfo类代码示例发布时间:2022-05-22
下一篇:
Java AsyncRequestFactory类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap