I'll second gec's comments... You're on the right track. Generally and for obvious reasons you want the switch located as close to were the CAT5e drops from the upstairs terminate. That looks to be in the patch panel next to your mains panel. That location is where your network switch should go. However, I wouldn't put it that close to the mains panel. Reroute the drops over a couple of feet from the mains to a small shelf if you can that has access to AC power. From the switch run a single CAT5e to your router in your AV closet, or wherever the router and cable modem will be located. And, while you're running cables....
Personally, I would locate the router somewhere on the first floor in a central location - since I'm assuming it will be wireless. You should have easy access to any first-floor room/wall from the basement, which makes running cables soooooo much easier! Even though most things will use wired drops to the internet, I'm sure you have other notebooks, tablets and smartphones that will use wireless.
Right? The cable modem can still remain in the basement (AV closet). Having your wireless router on the first floor gives much better coverage (and even distribution) to both the 1st floor and 2nd. Sadly, many people put routers where they are not seen and in so doing limit their effective coverage area. Routers should be up high and out in the open so that the signal doesn't have to go thru too many walls and floors. On top of a refrigerator or bookcase. Not readily visible, but it often does not meet the WAF.
You have to think creatively.
Good luck. I've got some before and after pics coming really soon to an AVS thread near you.
I'm still putting the finishing touches on my new basement/office media room space.
ps. As gec said, label the cables you run! You won't regret it.