Blog

 

Wheelchair (2012/finals/L): generator and eval

wheelchair by Tibor 'Igor2' Palinkas on 2020-02-15

Tags: 2012, finals, 2012finals, generator, eval, geo

node source

 

 

Abstract: n/a

 

Datasheet

Task Wheelchair
When 2012 finals L
Description html
Input pack zip

Sponsored task

Some sponsors, like Graphisoft in the 2012 finals, got a dedicated task in the problem set. This was normally based on an agreement between the sponsor and the operative team of Challenge24 organizers.

In such an agreement a few of the task writer team and the main organizer visited the sponsor, who presented a few raw task ideas. Our task writer team then discussed these ideas with the engineers of the sponsor and included a task written from one of the ideas in the problem set with a reference to the sponsor.

This setup was a win-win situation. The sponsor normally did not organize or participate in programming contests so they had no experience in how to design and implement a task that works properly in Challenge24. On the other hand even a diverse task writer team can use some creative ideas and unusual topics coming from outside of the team. Especially if the ideas are about very hard real life problems our sponsors faced in the software industry.

Wheelchair

After the meeting with Graphisoft, we choose their topic idea on accessibility. Their flagship product is a CAD program for architects and designing buildings with accessibility in mind is an important factor.

We took their idea and turned it into a Challenge24 task: a simplified wheelchair model with a specific way of moving and turning, modeling a real wheelchair and a "labirynth" of a "building", specified as a 2d vector graphic floorplan. Teams had to produce a script to optimize the wheelchair path from a starting point to a target point on the map with all turning and moving considering the geometry of the wheelchair and nearby walls.

Input generation

Mate Nagy wrote an interactive graphical level/map editor that could also animate a solution. He used python, animator and plumb for that. This editor was used for drawing the first few input maps. The more complex, large input files were generated.

After installing animator and plumb on a modern *NIX, you can run the map editor:


cd editor
./editor.sh ../inputs/1

Mouse and key bindings:

Left Mouse Button over an object: select, move; over empty space: pan
Mouse Wheel zoom
Middle Mouse Button selection box
Right Mouse Button draw new line
Backspace ?
ctrl+c copy to buffer
ctrl+x cut to buffer
ctrl+v paste from buffer
P or i edit path: push
L edit path: left
R edit path: right
ctrl+s save path
ctrl+l load path
f toggle path checking
G then integer go to path segment N
g toggle grid density
v view mode
c chair mode
a animation mode
p path mode

Eval

Submissions are evaluated by eval/eval.sh. Command line argument should be the number of the input between 1 and 10. It reads the original input from ../inputs/ and the submission on stdin. It prints the result on stdout, using the standard eval syntax.

License

The wheelchair material is Copyright (C) 2012 Mate Nagy and is licensed under the GNU GPL version 2.