The thermal sensors allocation is optimized based on Fuzzy Clustering Algorithm. The temperature measured by sensors is analyzed in temporal and spatial domains. A self-heating test module using the FPGA resources is presented for validation. The optimization method is suitable for various applications on FPGA.