# ERROR: More than 95% of external source sites sampled were rejected. Please check your external source’s spatial definition

**URL:** <https://openmc.discourse.group/t/error-more-than-95-of-external-source-sites-sampled-were-rejected-please-check-your-external-source-s-spatial-definition/3343>\
**Category:** User Support\
**Created:** [August 23, 2023, 1:28pm UTC](https://openmc.discourse.group/t/error-more-than-95-of-external-source-sites-sampled-were-rejected-please-check-your-external-source-s-spatial-definition/3343 "2023-08-23T13:28:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![srichr221](https://yyz2.discourse-cdn.com/free1/user_avatar/openmc.discourse.group/srichr221/32/2360_2.png) [@srichr221](https://openmc.discourse.group/u/srichr221)\
**Post date:** [August 23, 2023, 1:28pm UTC](https://openmc.discourse.group/t/error-more-than-95-of-external-source-sites-sampled-were-rejected-please-check-your-external-source-s-spatial-definition/3343/1 "2023-08-23T13:28:27Z")

</div>

Hi all - am playing around with Paramak in the openMC neutronics workshop docker container, trying to make a simple point source irradiate a shape and tally the heating. I got the following error:

ERROR: More than 95% of external source sites sampled were rejected. Please check your external source’s spatial definition.

And I’m not sure why - I’d appreciate any pointers, thanks

attaching my script here:  
[Untitled-2.py](https://openmc.discourse.group/uploads/short-url/ffEIbAUTlf7q5YHPzQLbG64bSRR.py) (1.8 KB)

---

<div class="post-metadata">

**Author:** ![Shimwell](https://yyz2.discourse-cdn.com/free1/user_avatar/openmc.discourse.group/shimwell/32/3876_2.png) [@Shimwell](https://openmc.discourse.group/u/Shimwell)\
**Post date:** [August 23, 2023, 3:28pm UTC](https://openmc.discourse.group/t/error-more-than-95-of-external-source-sites-sampled-were-rejected-please-check-your-external-source-s-spatial-definition/3343/2 "2023-08-23T15:28:35Z")

</div>

I think this is because your source location (0,0,0) is not within the geometry.

You can check this by looking at the model.xml, it should contain 6 surfaces which are all vacuum boundaries. These surfaces are made automatically for you by the bounded\_universe method. You should see that they are around 50 and 100. So the location of the source could be changed to match.

perhaps try getting the center of the geometry and setting the location to the middle

print(bound\_dag\_univ.bounding\_box.center)

or you could create a large radius sphere with a boundary\_type=‘vacuum’ and bound the dagmc geometry manually.

perhaps what we should do to make this type of simulation easier is add an `offset` argument to the [bounding\_region](https://github.com/openmc-dev/openmc/blob/ffbf1b9917ab9b3f6a2e414c3bd1ef62385a1fcf/openmc/universe.py#L952) method so that users can easily make the region larger than the geometry it bounds.

---

<div class="post-metadata">

**Author:** ![srichr221](https://yyz2.discourse-cdn.com/free1/user_avatar/openmc.discourse.group/srichr221/32/2360_2.png) [@srichr221](https://openmc.discourse.group/u/srichr221)\
**Post date:** [August 23, 2023, 3:48pm UTC](https://openmc.discourse.group/t/error-more-than-95-of-external-source-sites-sampled-were-rejected-please-check-your-external-source-s-spatial-definition/3343/3 "2023-08-23T15:48:04Z")

</div>

It worked! thanks very much.
