The traditional RSS-based fingerprint localization algorithm needs RSS values from all access points (AP) at each reference point (RP). In the large-scale indoor environment, the increasing of the number of APs will lead to establish a large-scale fingerprint database, which occupies a lot of storage space. In this paper, we propose a new reliable localization algorithm, which firstly utilizes quantized RSS to encode the monitoring region which has been divided into grids, so as to specify the grids that the interested target appears roughly. Then, we utilize Multi-Layer Perceptron (MLP) to train the grid regions in which the beacons deployment is non-isomorphic and obtain the accurate localization result. Due to the same deployment of isomorphic regions, it is imperative to train only one model to replace the others, which greatly reduces the computation of neural network. It can be concluded from the experimental results that compared with the traditional MLP-based fingerprint localization algorithm, the proposed algorithm reduces the size of fingerprint database over 80% with guarantee of localization accuracy. Moreover, our algorithm can obtain better localization accuracy compared with the other latest quantization based localization algorithm. INDEX TERMS Grid coding, multi-layer perceptron, indoor localization.