Due to recent updates, all users are required to create an Altair One account to login to the RapidMiner community. Click the Register button to create your account using the same email that you have previously used to login to the RapidMiner community. This will ensure that any previously created content will be synced to your Altair One account. Once you login, you will be asked to provide a username that identifies you to other Community users. Email us at Community with questions.

How to load an Ioo file?

srinisrini Member Posts: 9 Contributor II
edited November 2018 in Help
I have an ioo file that was generated by UI. I am trying to load that repo programmatically. When I try to load, I am getting NullPointerException. However when I try to load the sample data, it is able to retrieve. What is it that I am doing wrong?

Below is the sample code.

RepositoryLocation pLoc = null;
        try {
            pLoc = new RepositoryLocation("//NewLocalRepository//Hypo");
        } catch (MalformedRepositoryLocationException ex) {
            ex.printStackTrace();
        }

        IOObjectEntry entry = (IOObjectEntry) pLoc.locateEntry();
        IOObject myIOObject = entry.retrieveData(null);
        IOContainer ioInput = new IOContainer(new IOObject[]{myIOObject});
        ExampleSet examples = ioInput.get(ExampleSet.class);
Tagged:

Answers

  • Marco_BoeckMarco_Boeck Administrator, Moderator, Employee, Member, University Professor Posts: 1,996 RM Engineering
    Hi,

    sorry I somehow missed the question..
    The problem is that

    pLoc.locateEntry();
    returns null when the entry could not be found. In your case the entry could not be found because you have too many '/' in the RepositoryLocation. Only at the beginning '//' is needed, otherwise the seperator is simply '/'.
    Change the line to

    pLoc = new RepositoryLocation("//NewLocalRepository/Hypo");
    and it should work.

    Regards,
    Marco
Sign In or Register to comment.