Neutral-atom arrays have emerged as a versatile platform toward scalable quantum computation and optimization. In this paper, we present demonstrations of solving maximum-weighted independent-set problems on a Rydberg-atom array using annealing with local light shifts. We verify the ability to prepare weighted graphs in one-dimensional (1D) and two-dimensional (2D) arrays, including embedding a five-vertex nonunit-disk graph using nine physical qubits and demonstration of a simple crossing gadget. We find common annealing ramps leading to preparation of the target ground state robustly over a substantial range of different graph weightings. This work provides a route to exploring large-scale optimization of nonplanar weighted graphs relevant for solving relevant real-world problems. Published by the American Physical Society 2025