Magnetic field extrapolation is an important tool to study the three-dimensional (3D) solar coronal magnetic field which is difficult to directly measure. Various analytic models and numerical codes exist but their results often drastically differ. Thus a critical comparison of the modeled magnetic field lines with the observed coronal loops is strongly required to establish the credibility of the model. Here we compare two different non-potential extrapolation codes, a non-linear force-free field code (CESE-MHD-NLFFF) and a non-forcefree field (NFFF) code in modeling a solar active region (AR) that has a sigmoidal configuration just before a major flare erupted from the region. A 2D coronal-loop tracing and fitting method is employed to study the 3D misalignment angles between the extrapolated magnetic field lines and the EUV loops as imaged by SDO/AIA. It is found that the CESE-MHD-NLFFF code with preprocessed magnetogram performs the best, outputting a field which matches the coronal loops in the AR core imaged in AIA 94 Å with a misalignment angle of ∼ 10 • . This suggests that the CESE-MHD-NLFFF code, even without using the information of coronal loops in constraining the magnetic field, performs as good as some coronal-loop forward-fitting models. For the loops as imaged by AIA 171 Å in the outskirts of the AR, all the codes including the potential-field give comparable results of mean misalignment angle (∼ 30 • ). Thus further improvement of the codes is needed for a better reconstruction of the long loops enveloping the core region. . Three magnetic field models often used include the potential field, linear force-free field (LFFF), and nonlinear force-free field (NLFFF). All these models are derived from a basic assumption that the Lorentz force in the corona vanishes in the case of extremely low plasma β (β is the ratio of the plasma pressure to the magnetic pressure) and quasi-static equilibrium of the coronal field. Consequently the electric current J = ∇ × B must be parallel to the magnetic field, i.e., J = αB where α is called the force-free parameter. In the potential field model, α = 0; in the LFFF, α is a constant; and in the NLFFF, α is variable in space. The earliest models were based on potential field (Altschuler & Newkirk 1969;Sakurai 1982) and LFFF (Seehafer 1978) that are extrapolated from only the data of line-of-sight (LoS) component of the photospheric field since the transverse components were not measured. Now both the LoS and transverse components of the photospheric magnetic field can be measured (e.g., Hoeksema et al. 2014) and information of the electric current passing through the photosphere can derived. Nonlinear force-free field (NLFFF) reconstructions, which are based on the vector magnetograms, are more robust than those earlier models, and employ several numerical schemes