Pixel shape in Allpix2


Can the pixel shape be changed in allpix2?
For example, if I want to simulate pixels with a hexagonal/Circular shape, it is possible?

what I found till now is that the pixel is defined by the pixel_size parameter in the config file and which is given two values, so we have at the end a rectangular pixel.

Thanks for your suggestions.


Dear Tasneem,

currently we only support rectangular pixels. However, you are not the only one looking at different shapes and we will likely start soon implementing hexagonal pixels. Let me know if you have time and capacity to help us out, either with coding or testing.
Best regards,

Hi Simon,

I can help in coding, but maybe I need some help from your side since I don’t know all about the code for the moment, I have just started using it. But for sure I can find sometime to do the needed test.

Do you have any idea (if possible) where can I define the inter-pixel region (the distance separate different pixels) in the code ?


Hi Tasneem,

I have sent you an e-mail concerning the hexagonal pixels, to put you in contact with a few other interested parties.

Concerning the inter-pixel region:
If you are using the GenericPropagation module with an electric field that is not linear, you may define a pixel implant size in your detector model (via implant_size, see here) and set the collect_from_implant key in the SimpleTransfer module to true (see here). That way, only charge carriers ending up within your pixel implant are accounted for.

For linear electric fields this of course does not make much sense.

Is this what you are looking for?

best regards,