Microscopic spatial defects (inhomogeneities) in solar cells have a detrimental impact on the overall performance of the solar cells. These defects can be due to the polycrystalline nature of the photovoltaic absorber (general case) or on the other hand, the characterization method itself can induce such inhomogeneities (ex: local excitation with confocal system). Photoluminescence imaging in particular is the most attractive type of experimental character- ization technique which has been studied by many research groups. Since it is contactless, it allows a complete analysis of the photovoltaic material and it can actually be performed at each step of the solar cell fabrication process. To properly analyze the recorded images, one has to model the transport properties. In this work we model the transport properties in 2D using both a numerical and analytic approach. First,we model the global illumination of the sample, we then analyze the effects of grains and surface recombination. Second, we study lateral transport that can be influenced by recombination at the surface (passivation issues), grain boundaries (polycrystalline cells) or local artifacts (shunts, defects...). At the same time we are able to extract the lifetime knowing the generation rate and solving the excess carrier density from our model. And finally we implement our model to extract some cell parameters like the diffusion length from experimental data through data fitting.