骑行游戏 (迷你神经网络演示)
Cycling Game (Mini Neural Net Demo)

原始链接: https://www.doc.ic.ac.uk/~ajd/Cycling/

这个模拟展示了人工智能控制的自行车手在比赛中进化。每个骑手由一个独特的神经网络驱动,最初是随机的,它会根据速度、坡度和与竞争对手的距离等输入来学习优化表现。 目标是观察这些“大脑”在几代中的进化——每场比赛后,前5名骑手会繁殖(并带有少量变异),从而缓慢提高整个种群的速度。成功的策略通常包括在上坡时最大化努力,在下坡时恢复体力,并且可能会出现诸如跟车和冲刺等涌现行为。 该模拟使用了真实的自行车物理机制,考虑了重量、阻力、滚动阻力和骑手的有氧/无氧能量系统。玩家可以观察单个神经网络,并使用新的骑手和地形重置模拟,以获得不同的结果。这是一个迷人地展示了简单的AI如何通过进化原理进行适应和改进。

黑客新闻 新的 | 过去的 | 评论 | 提问 | 展示 | 工作 | 提交 登录 自行车游戏(迷你神经网络演示)(ic.ac.uk) 15 分,由 ungreased0675 发表于 5 小时前 | 隐藏 | 过去的 | 收藏 | 2 条评论 JKCalhoun 4 小时前 | 下一个 [–] 我很喜欢这个。试图理解:输入和输出之间只有一层吗?而且所有的输入都是计算出来的……有趣的是,有一个(假设正在运行的)平均 100 米梯度和一个单独的 1000 米梯度。我想这让大脑可以区分短暂的爬升/下降和更长的爬升/下降。现在想知道一个“距离终点不足 100 米”的输入,以便在最后一秒冲刺。或者“后方骑手在 10 米范围内接近”。回复 ungreased0675 5 小时前 | 上一个 [–] 一个游戏,每个骑自行车的人都是一个迷你神经网络,他们试图找到最佳策略。回复 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请 YC | 联系 搜索:
相关文章

原文

Click or use up/down arrow keys to select a rider and see their neural controller. Press 'r' or wait to return to default race view which shows the top 5 riders. Space to force evolution before race distance. Reload (Ctrl+R or Cmd+R) to reset with new riders and randomly generated terrain (try this if nothing interesting is happening!).

All the riders have the same physical characteristics, but different brains, which evolve over multiple races. Each rider is controlled by a small neural network whose inputs are percepts (speed, power, battery level, average gradient over the next 100m, average gradient over the next 1000m, distance to the rider ahead, fraction of race completed) and whose output determines how the rider's power output will change per timestep (scaled by Power Multiplier). The network weights are randomly initialised. The red/blue colouring of the input nodes shows the current positive/negative contribution of each input to the output change. After each race we select the 5 leading riders, and generate a new generation of some exact copies and some with small weight mutations, which will lead to different behaviour. Watch the population of riders hopefully slowly improve their average speed over a few generations. Basic good strategy is to try hard going uphill and recover going down (because the air resistance force is proportional to velocity squared). You may also sometimes see dedicated drafters or sprinters emerge...

The cycling physics is based on rider + bike weighing 87kg, and simulates slope and air resistance effects with a drag area CwA of 0.32 and a coefficient of rolling resistance Cr of 0.004. Drafting reduces air resistance by up to nearly 40% when a rider is close behind another. Physiologically, the riders have aerobic threshold power of 250W, and a "Wprime" anaerobic battery of 15000J which discharges above that threshold and recovers beneath it. The riders have a maximum sprint power of 750W, but this decreases linearly with battery level.

Andrew Davison, Imperial College London, 2025. @ajddavison on x.com for suggestions! Partly inspired by this.

联系我们 contact @ memedata.com