microsoft / malmo

Project Malmo is a platform for Artificial Intelligence experimentation and research built on top of Minecraft. We aim to inspire a new generation of research into challenging new problems presented by this unique environment. --- For installation instructions, scroll down to *Getting Started* below, or visit the project page for more information:
https://www.microsoft.com/en-us/research/project/project-malmo/
MIT License
4.1k stars 600 forks source link

Problem Xml_schema #176

Closed Helpdesk-CS closed 8 years ago

Helpdesk-CS commented 8 years ago

Hello, I have a error in agent or in Malmo Human Action Error parsing Mission

parsing

thanks

DaveyBiggers commented 8 years ago

Looks like your mission XML is malformed - if you paste it here, we can try to find the problem.

Helpdesk-CS commented 8 years ago

sorry but it's the original XML example ...

DaveyBiggers commented 8 years ago

Ha, that's a shame! Can't blame anyone else then... We'll take a look.

timhutton commented 8 years ago

@Helpdesk-CS What is your operating system? Can you confirm that you followed the install instructions and tried to run an agent from e.g. the Python_Examples folder in the unpacked zip?

Helpdesk-CS commented 8 years ago

Under Windows 10, and yes I tried the agents, including c#, I add the ReadLine() to have error consoles. And I got the same error: the above with HumanAction.

I think having succeeded in everything installed: I also added three environment variables: JAVA_HOME PATH (for ffmpeg) and MALMO_XSD_PATH

I have install Additionally https://slimdx.org/download.php, in order to run in X64 HumanAction, Otherwise I had an additional error of incompatible version.

Sorry for this english ( is so bad :s ) ( i'am french)

timhutton commented 8 years ago

@Helpdesk-CS Could you please paste in the output of run_mission.exe (located in Cpp_Examples)? Also CSharpExamples_RunMission.exe (located in CSharp_Examples). Perhaps the exact output will give us more clues.

Helpdesk-CS commented 8 years ago

Error starting mission: Internal error: the XML we generate does not validate: instance document parsing failed :1:236 error: schemaLocation does not contain namespace-location pairs

<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<MissionInit xmlns="http://ProjectMalmo.microsoft.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://ProjectMalmo.microsoft.com MissionInit.xsd">
  <Mission><About><Summary/></About><ServerSection><ServerHandlers>
    <FlatWorldGenerator forceReset="false" generatorString="3;7,220*1,5*3,2;3;,biome_1" seed=""/>
<ServerQuitFromTimeUp description="" timeLimitMs="10000"/><ServerQuitWhenAnyAgentFinishes description=""/>
</ServerHandlers>
  </ServerSection>
    <AgentSection mode="Survival">
      <Name>Cristina</Name>
      <AgentStart/>
<AgentHandlers><ObservationFromFullStats/>
<VideoProducer viewpoint="0" want_depth="false">
  <Width>320</Width>
<Height>240</Height>
</VideoProducer>
<RewardForReachingPosition dimension="0">
  <Marker oneshot="true" reward="100" tolerance="1.100000023841858" x="19.5" y="0" z="19.5"/>
</RewardForReachingPosition>
<ContinuousMovementCommands turnSpeedDegs="180"/>
</AgentHandlers>
</AgentSection>
</Mission>
<ExperimentUID/>
<ClientRole>0</ClientRole>
<ClientAgentConnection>
  <ClientIPAddress>127.0.0.1</ClientIPAddress>
<ClientMissionControlPort>10000</ClientMissionControlPort>
<ClientCommandsPort>0</ClientCommandsPort>
<AgentIPAddress>127.0.0.1</AgentIPAddress>
<AgentMissionControlPort>10976</AgentMissionControlPort>
<AgentVideoPort>10004</AgentVideoPort>
<AgentObservationsPort>10155</AgentObservationsPort>
<AgentRewardsPort>10740</AgentRewardsPort>
</ClientAgentConnection>
</MissionInit>
HAadams commented 8 years ago

@Helpdesk-CS What specific actions did you take to get that error? Did you try to load an xml file for "Curriculum" from MalmoHumanAction.exe?

Helpdesk-CS commented 8 years ago

I Want just test the programm with a example, but nothing works ...

HAadams commented 8 years ago

@Helpdesk-CS If by program you mean MalmoHumanAction.exe, then as @DaveyBiggers said, I think the problem is with the xml file you are trying to load.

So, if you are indeed running MalmoHumanActin.exe, try to load the tutorial_6.xml file which can be found in the python_examples folder and tell us what you get

Helpdesk-CS commented 8 years ago

The same problem, when i load the file tutorial_6.xml in the python_examples folder.

Helpdesk-CS commented 8 years ago

Ok i find this line on C#

agentHost.startMission(mission, missionRecord);

It is this line that throws the error. If I put the comment line, subsequently starts correctly.

Helpdesk-CS commented 8 years ago

Suddenly, I got the message: "waiting for the mission to start", It as something that I do not understand: how rules your connection from agent to Minecraft. If from Minecraft, I create the login/password, I cannot find on the other side, the way to inform them

Helpdesk-CS commented 8 years ago

If I look at the changeLog, "Removed xsi::schemaLocation entries from all XML files, since not used." Yet the Agent looking everywhere the location of this schemaLocation which does not exist in the sample XML files.

Es that the agent may not be updated relative to the file?

DaveyBiggers commented 8 years ago

If you remove the "startMission" line then the mission won't start, and the sample will wait at the "waiting for the mission to start" stage forever.

Can I check: how did you install Malmo? Did you got to the release page - https://github.com/Microsoft/malmo/releases - and install a pre-built version, or did you use the big green button at the top of GitHub to download a zip of the source? If you downloaded the source, you will also need to build it.

Also, can I ask where you installed Malmo to? What is the exact path to your Schemas folder?

Helpdesk-CS commented 8 years ago

I have download "Malmo-0.14.0-Windows-64bit.zip" I have unzip in a folder, and i use direct from it.
It as not in itself, installation to MALMÖ?

Folder ->Malmo-0.14.0-Windows-64bit ---->Schemas ---->Minecraft ---->Csharp_Examples ---->HumanAction

Helpdesk-CS commented 8 years ago

Still the same error... capture

DaveyBiggers commented 8 years ago

We still can't reproduce this error here. Can you tell us what you used to build your C# example? How exactly did you run it? And do you get the same error if you run the prebuilt one that came in the zip file - ie CSharp_Examples\CSharpExamples_RunMission.exe?

Do you get the same error if you run a python sample - eg

cd "H:\Projet Malmo\Malmo-0.14.0-Windows-64bit\Python_Examples"
H:\Projet Malmo\Malmo-0.14.0-Windows-64bit\Python_Examples>python MazeRunner.py

Finally, what do you see if you type xsd version into a command prompt?

Helpdesk-CS commented 8 years ago

Yes I use the pre-compiled in the ZIP, and also the version compiled with Visual-Studio 2015.

Here are trying with pyton: And the version of xsd : cap2 cap1

DaveyBiggers commented 8 years ago

Thank you. The only thing I can think of is that there must be some corrupt copies of the XSD files getting picked up somehow. Can I check what your MALMO_XSD_PATH is set to?

Helpdesk-CS commented 8 years ago

Ok, so, I will re-download again all.

Yes my Path is : " H:\Projet Malmo\Malmo-0.14.0-Windows-64bit\Schemas "

Helpdesk-CS commented 8 years ago

Nothing works. I downloaded, I even tried with other version of the xsd (those of debian, and those in the source) files. I do not understand.

I tried the version 0.15, it is the same.

DaveyBiggers commented 8 years ago

Got it, I think - for some reason it fails if there is a space in your MALMO_XSD_PATH. Try removing the space from "Projet Malmo", change the MALMO_XSD_PATH (remember to open a new command prompt so the change takes effect), and try again.

Helpdesk-CS commented 8 years ago

Yes ! Thanks ! it's WORK ! Very very congratulations!

DaveyBiggers commented 8 years ago

Hurrah! Glad we got there in the end!

siolfyr commented 8 years ago

I had this same error. Glad this issue was here.

jaysl commented 5 years ago

Got it, I think - for some reason it fails if there is a space in your MALMO_XSD_PATH. Try removing the space from "Projet Malmo", change the MALMO_XSD_PATH (remember to open a new command prompt so the change takes effect), and try again.

I'm getting an error called "Please set the MALMO_XSD_PATH environment variable" Can you please tell me how can I solve this