« September 2008 | Main | November 2008 »

October 30, 2008

Cyclopath Tutorial Part 4: Revisions

In the last post, I talked about how you can edit the map in Cyclopath. Now, how do you see what changes other users have made? And what can you do if another user makes an edit that you know is not correct? This is where revisions come in.

Revisions are used in many applications such as Wikipedia and Google Docs to keep track of changes made to documents. Each revision is a change or save made by a user. Whenever you make changes to the map in Cyclopath and hit Save, you are asked to summarize your changes. These changes are grouped together into a revision, accompanied by your summary. Now, let’s look at how you can view and interact with other users’ revisions.

We will be concentrating on the Recent Changes panel of the interface.

tutorial4a.JPG

This panel shows a list of all recent changes (revisions). You can view all revisions or filter them by visible area (only show revisions that affect the area of the map that you are currently looking at) or by watch regions (we’ll talk more about this in the next post). The list of revisions shows for each revision the revision number, the user who made the change (if anonymous, then the IP address is shown), the date and time of the revision and the user’s summary about the revision.

Now, what happens if you click on a revision?

tutorial4b.JPG

You’ll notice that a section of the map just got highlighted. This is where the change occurred. Sometimes, this change might not be in the visible area of the map. To move to where the change is, click on “Look at?. The map will then center on the location of the change and zoom in as much as possible.

tutorial4c.JPG

Now comes the fun part. Diff mode. This is where you can see the changes that actually occurred during the selected revision(s). There are two types of changes in Cyclopath: geographical edits and non-geographical edits. Let’s take a look at non-geographical edits first. With the revision we selected above still selected, we now click on the “Changes? radio button in the “Map shows:? section. This tells Cyclopath that you want to view changes made in the selected revision (not just where they occurred). Click on “Update? and the map will change to Historic Mode.

tutorial4d.JPG

The map now highlights the changes made. The blocks highlighted had some of their information changed. We can click on them to view what changed.

tutorial4e.JPG

tutorial4f.JPG

Same thing can be done with points. Here’s an example.

tutorial4g.JPG

By the way, to exit Historic mode and go back to what the map is like currently, just click on the “Exit historic mode? button on the bottom of the map.

Now, let’s take a look at geographical edits. Revision 4941 is a good candidate. When we click on “Update? after selecting “changes? we get the following screen:

tutorial4h.JPG

Looks quite different, right? Here, the edits actually moved vertices and points around, added new blocks and removed blocks. We call them geographical edits because they change how the objects look on the map. Take a look at the Comparison Key if you ever get confused about what the colors mean!

tutorial4i.JPG

To make looking at geographical edits easier, at the bottom at the map there is a “Before? and an “After? button. With these buttons you can view what the map looked like before and after the change.

Before:

tutorial4j.JPG

After:

tutorial4k.JPG

To go back to viewing the difference together, just click on the “Both? button at the bottom of the map.

Now, what if you see a revision that you think is incorrect? How do you undo it? In the world of wikis, this is called reverting a revision. Reverting a revision in Cyclopath is simple. Just click on the revision you wish to undo and click on the “Revert Revisions? button above it. Write a short summary of your reason for undoing that revision and you’re done.

Another neat feature about revisions in Cyclopath is writing feedback. If you want to comment to someone about a change they made, just select the revision you want to give feedback about and click on the “Write feedback? button. You will then be given a change to write your feedback, which will be sent to that user and to the Cyclopath mailing list.

You should now know the basics of viewing changes in Cyclopath. Go ahead and give it a try. Have fun!

October 27, 2008

Cyclopath Tutorial Part 3: Editing the Map

One of the coolest features of Cyclopath is that you can edit the map as you wish. You can add points of interest, add roads, remove paths, etc. Today, I will be going through some of the basics of map editing in Cyclopath. Let’s start with the easiest: editing points of interest.

Editing a Point

Editing an existing point is very easy. To edit a point’s information, it’s as simple as clicking on a point on the map and editing the fields that appear on the left pane in “Point Details?.

tutorial3a.JPG

You can move a point by dragging it on the map. And to remove it, just click on “Delete Point? in the Details panel.

Finally, for adding a point, you’ll need to use one of the tools on the upper right corner of the map.

tutorial3b.JPG

When you click on the second tool, the “Add a Point? tool, your cursor will change to let you know that you’re using that tool (that’s what is happening in the image above). Once in this mode, simply click on the map and you will be prompted to enter a point name. After you enter the name, a point is created in the location that you clicked.

Editing Blocks

Editing blocks (or road segments) is a bit trickier. The simple part is editing a block’s information. As with points, just click on a block and edit the fields in the Details panel. One difference though is that you can add multiple notes to a block (and add those notes to other blocks). Furthermore, you can edit multiple blocks a time by holding either CTRL or SHIFT to select blocks (CTRL allows you to select individual blocks, while SHIFT allows you to select a path of blocks).

tutorial3c.JPG

The harder part is editing blocks geographically, that is, on the map. To create a block, click on the “Create new block? tool on the upper right.

tutorial3d.JPG

After selecting the right tool, you can click anywhere on the map to create a new block.

tutorial3e.JPG

You will notice that the new block has two endpoints. You can drag these endpoints to connect your new block to other block endpoints. The endpoint will snap to other endpoints when nearby.

tutorial3f.JPG

If you have the connectivity checkbox checked, you will notice that the new block is now connected to other nearby blocks. Now, suppose we don’t want the block to be a boring straight line. We can shape it even further by adding vertices. For this we select the “Add vertex? tool (it will only be enabled when you select a block).

tutorial3g.JPG

This time, the cursor will not change. But when you click on your block, a new vertex will be created!

tutorial3h.JPG

You can now drag this vertex around to give your block a better shape. Keep in mind that you can’t snap vertices to other endpoints though! Only endpoints can be connected to other block endpoints.

tutorial3i.JPG

Now suppose you want to connect your new block to the middle of another block. You can't just drag it over because there are no endpoints, so it won’t snap. What you’re trying to do is create an intersection where there isn’t any. To do this, first we have to split the block we want to connect to. For this, select the “Split Block? tool on the upper right. Once again, you have to have the block selected for the tool to be enabled and the cursor won’t change after you select the tool.

tutorial3j.JPG

Next, click on the block wherever you want to create the new intersection.

tutorial3k.JPG

Now the block has been split in two, basically creating an intersection between the two blocks. These two blocks are connected together through endpoints where we just clicked. Now we can connect to these endpoints!

tutorial3l.JPG

Now, what if you want to remove a block? Simple. Click on the block and go to the “Advanced? tab in the Details panel.

tutorial3lb.JPG

There is a button called “Delete Block(s)?. Click it to remove the block.

tutorial3m.JPG

Now we have another problem. Remember the block that we split before? We want to stick it back together, merge it back into only one block. To do this, first select the two blocks (you can use CTRL to select multiple blocks). In the Details panel, right next to the “Delete Block(s)? button, there is a button called “Merge Blocks?. Just click on it to merge the two blocks back together!

tutorial3n.JPG

And that’s it! You now know how to edit the map. Just three more tips before I end this post. There is a checkbox called “Aerial Photos?. This is incredibly useful when editing the map geographically. It displays satellite photos, allowing you to do more precise editing (be careful with it though, since the photos may be a few years old). The second feature that you should use extensively when doing geographic editing is the connectivity checkbox. This is the best way to know if you are connecting blocks correctly. The third thing to keep in mind is the usefulness of the Undo, Redo and Discard Changes buttons. Use them as much as needed! And use them to experiment and try out map editing. As long as you don’t hit Save, your changes won’t affect the system.

So go ahead, give map editing a try. It’s the coolest thing around.

October 24, 2008

Cyclopath Tutorial Part 2: Rating and Finding Routes

The fastest way to start using Cyclopath and getting some benefit out of it is using its route finder feature. It’s also one of the features that most users are already accustomed to thanks to other popular route finders. Let’s take a look at how to use the route finder.

On the left side of the interface, you will find the “Routes? panel:

tutorial2a.JPG

At first, until we ask it to find a route, it will be empty. By clicking on the “Find New Route? button, you will be presented with the following popup:

tutorial2b.JPG

Inputting addresses to search for here is pretty straightforward. But there are three more things to be aware of. First, besides addresses, you can also search for points. Points are those locations of interests that can be found throughout the map. For example, in the following screenshot, Mariucci Arena, Williams Arena, and TCF Bank Stadium are all points. This means that you can find routes to them by writing their names instead of street addresses.

tutorial2c.JPG

The second thing to be aware of is the sliders at the bottom. One says Bikeability and the other says Distance. Cyclopath has a few ways of measuring bikeability, which we will talk about a little more later in this post. You can ask the route finder to find a route that is more bikeable or a route that is shorter.

The third thing to be aware of is that this interface may change somewhat in the near feature. As we are still in Beta development, some really cool features are currently in development. So stay on the lookout for these cool changes!

After you write in your source and destination addresses, click on the “Find? button to get your route. (click on the image to view a larger version)

tutorial2d.JPG

You will get the route displayed on the map and the directions (included distance of each step) on the left. You can get a nice, printable version of the directions by clicking on the “Printer Friendly? button.

Now, let’s get back to bikeability. How is bikeability computed? The base case is based on a formula that takes into account aspects of the blocks such as usable shoulder space. Now comes the fun part. You can affect this computation by rating blocks. That’s right. How you rate blocks will change how the route finder computes bikeability. If you rate a block as excellent, the route finder will give that block preference. If you rate a block as poor, it will be penalized by the route finder. You can even rate a block as impassable to have the route finder avoid it altogether. By the way, for blocks you haven’t rated, if a reasonable amount of other users have rated it, their averaged rating will be given priority over the base formula. Cool, isn’t it? Now, let me show you where to apply the ratings:

tutorial2e.JPG

When you click on a block, the Item Details panel will open. Here, you will be able to see the estimated rating of the block and the option for giving it your own ratings. Keep in mind that you have to be logged in to use this feature, so be sure to register! Once you have rated a block, all you have to do is save changes and your ratings are ready to be used the next time you search for a route.

tutorial2f.JPG

By the way, blocks you have rated will be colored differently depending on the rating you give them. Check the Map Key at the bottom of the map to see which colors correspond to which ratings.

tutorial2g.JPG

Now you should know how to rate blocks and find routes. Have fun rating!

October 21, 2008

Cyclopath Tutorial: Part 1

I am really enjoying the project I am working on, Cyclopath. It’s an awesome geowiki for cyclists in the Twin Cities. But for the first time user, it may be a lot to take in. It has a lot of neat features that most people don’t expect to see together (e.g. map editing and route finding). So I decided to dedicate my next few posts to explaining the basics of Cyclopath. I won’t cover all there is to say about it (that’s what the user manual is for), but I’ll try to focus on the most important aspects. Also, Cyclopath is still in Beta, so new features and changes occur frequently. Anyway, this should still prove to be useful. Enjoy!

Part 1: Getting Around Cyclopath

Cyclopath is at its core simply a map. That is why the most obvious thing you will notice when you visit it will be a map of the Twin Cities. Everything revolves around this map. After you have located the map (shouldn’t take you more than a few milliseconds) you can then start focusing on all the other awesome stuff lying around. Here’s an overview of some of the stuff you’ll find (labeled on the picture below for your convenience):

A) Help Button – If you get stuck, this is the place to go! This opens a new window with help information.
Log in/ Register Button – You can use Cyclopath even if you’re not registered, but that’s no fun. Please register!
B) Item Details Panel – This panel displays information about blocks (as in road segments) and points (as in locations of interest). It remains empty until you select a block or point.
C) I’ll talk about these other panels in later tutorials. For now, just take my word that they’re very useful!
D) The map, just in case you couldn’t find it.
E) Navigation – You can move around the map by either dragging it or using the navigation buttons here on the upper left. The plus and minus buttons are for zooming in and out, respectively.
F) Editing tools – Since this is a geowiki, it means that you can edit the map. That’s right. You can change information, points, and even the road segments themselves as you see necessary (try not to vandalize though). The set of tools on the upper right are used for editing, but we’ll delay the explanation of these tools for another tutorial. For now, all we need is the select tool.
G) More Tools – These are a few settings and tools. You can save any of your changes here. The four checkboxes toggle connectivity (which shows you which blocks are connected to which blocks), Watch Regions (we’ll talk about this later), Aerial Photos (so you can see what the map really looks like), and Sticky Intersections (we’ll talk about this later too).
H) Map Key – If you forget what some of the colors and shapes mean, just click on the map key for a refresher.

cyclopath1.jpg

Viewing Item Details

When you are zoomed close enough, you can click on points and blocks to view their details. The screenshot below shows what that looks like.
A) A selected block – When you select a block, it is highlighted with blue and all its vertices are shown. Its information is then shown on the left.
B) Points are in the shape of circles. They too can be selected to display their information.
C) Name - The name of the block or point, which usually shows on the map.
D) Type – For blocks, you can select the road type.
E) Flags – Some more options to set for blocks.
F) Ratings – We’ll talk about this more in the next part of the tutorial, but basically this is where you rate blocks.
G) All blocks and points can have notes associated with them. This is where you can see and edit these notes. Blocks that have notes appear on the map highlighted with purple.

cyclopath2.jpg

If you’re a new user, then you probably aren’t interested or confident enough to start editing right away. Take some time to explore the map, clicking on different byways and points to see their information.
I hope this brief introduction helps. Let me know in the comments section if you have any questions!

October 16, 2008

A Video About Puerto Rico That Will Make You Want to Take a Vacation Right Now

I must admit I am very biased. But I really do believe that Puerto Rico is a great vacation spot. And this is the best video I've found about tourism in Puerto Rico. So don't think about it anymore. Make Puerto Rico the destination for your next vacation. Enjoy the video!

October 13, 2008

Puerto Rico Islanders Almost Get There

Once again, I will diverge from the normal blog topics to talk about my favorite sports team (the only one from my country to be in the same league as one from Minnesota, where I currently reside). Yesterday I watched the USL (United Soccer League) championship game on TV. The Puerto Rico Islanders made it to the finals for the first time in their short 5-year history. It was an intense game, which ended 2-1 with the Vancouver Whitecaps winning.

They did not win, but I am still proud of them. They finished first in the regular season and were awarded with MVP, Coach of the Year, and Defender of the Year. This has been their best season yet. And I can't wait to watch them come play against the Minnesota Thunder again next year! Congratulations, Puerto Rico Islanders!

P.S. If anyone wants to send me a Puerto Rico Islanders jersey, by all means go ahead!

(Now back to our regular programming.)

October 11, 2008

WPE Victory!

I'm taking a short break from a dreaded Machine Learning homework to let all of you know the great news. I passed the WPE (Written Preliminary Exam)!! I took this 3-part exam in September and had been waiting for the results since then. Thankfully, I passed all three parts of the exam. This marks an important milestone in my PhD progress. The next steps are now finishing the required classes (I should be done by Fall of next year) and the Oral Examination (which I hope to do in Spring '10). If all goes well, I'm on track to finishing by 2012. The date seems far away, but passing the WPE just made it feel much closer.

October 7, 2008

Computer Security With Bible Verses?

One of the reading references for the Computer Security class is an online book called Secure Programming for Linux and Unix HOWTO, by David A. Wheeler.

One aspect of his book that caught my attention was the fact that he starts each section with a verse from the Bible. It doesn't matter if you're a Bible fan or not, you have to admit that he was very clever. Here are some of my favorite book sections and corresponding verse:

Security Requirements
"You will know that your tent is secure; you will take stock of your property and find nothing missing."
Job 5:24 (NIV)

Avoid Buffer Overflow
"An enemy will overrun the land; he will pull down your strongholds and plunder your fortresses."
Amos 3:11 (NIV)

Structure Program Internals and Approach
"Like a city whose walls are broken down is a man who lacks self-control."
Proverbs 25:28 (NIV)

Send Information Back Judiciously
"Do not answer a fool according to his folly, or you will be like him yourself."
Proverbs 26:4 (NIV)

Bibliography
"The words of the wise are like goads, their collected sayings like firmly embedded nails--given by one Shepherd. Be warned, my son, of anything in addition to them. Of making many books there is no end, and much study wearies the body."
Ecclesiastes 12:11-12 (NIV)

Acknowledgements
"As iron sharpens iron, so one man sharpens another."
Proverbs 27:17 (NIV)

October 4, 2008

A New Puzzle For This Semester: Hidato!

I am fond of puzzles. I enjoy having something fun and entertaining to do during boring clas... during my free time. I even had a week about some of my favorites here in this blog.

So, as a puzzle enthusiast, it is my duty to let all of you know when I discover a new puzzle to waste my neurons on. Here is my short review of Hidato (based on the puzzle book I own, by Dr. Gyora Benedek):

Concept:
Complete the sequence of numbers, which must be adjacent either horizontally, vertically or diagonally.
Difficulty: C
The puzzles don't really seem to get much harder as you progress in difficulty. And there is a small number of tactics to learn (as opposed to Sudoku and Kakuro, which have tons of tactics). The puzzles remain somewhat easy and only get bigger as the "difficulty" goes up.
Entertainment Value: B
It's fun to follow the sequence around.
Benefit: C
If you're learning how to count from one to one hundred, then this is the puzzle for you. Otherwise, your mind won't really gain much from it.
Replay Value: A
The fact that it doesn't take too much time too solve makes you feel like you need to solve many more to feel satisfied. I usually solve about five in a row.
Overall:B
Fun, but not challenging enough for those who have done a lot of Kakuro and Sudoku.

For more information, check out www.hidato.com.

October 1, 2008

Hacking for Grades

No, I'm not doing anything illegal. I am taking a class called Introduction to Computer Security. It's not a topic that I enjoy very much or that I'm good at, but I believe it's essential in order to be a good programmer.

As part of my first homework, I had to attack a badly written version control system in order to gain access to a shell (that interface to your computer that is just a command line) as root (which means I get top privileges and can modify the system even if I was not allowed to initially).

The most interesting exploit to do was a buffer overflow. It was also the toughest. Basically, what this type of attack tries to do is store a very long piece of code into a section in memory that has a smaller size than that of the code's length. When the computer tries to store that very long piece of code, since it doesn't fit, it ends up overwriting other sections of memory. The fun part is that with this type of attack you can make the victim code jump to your own code and execute whatever you want. It's tricky, but it's possible.

After I was done with this assignment, I at least realized that I don't have zero security skills. Looks like the class is being worth it!