# ERROR get\_atoms from depletion result

**URL:** <https://openmc.discourse.group/t/error-get-atoms-from-depletion-result/4987>\
**Category:** Validation and Verification\
**Created:** [November 22, 2024, 8:29am UTC](https://openmc.discourse.group/t/error-get-atoms-from-depletion-result/4987 "2024-11-22T08:29:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![MAKurniwawan](https://yyz2.discourse-cdn.com/free1/user_avatar/openmc.discourse.group/makurniwawan/32/1706_2.png) [@MAKurniwawan](https://openmc.discourse.group/u/MAKurniwawan)\
**Post date:** [November 22, 2024, 8:29am UTC](https://openmc.discourse.group/t/error-get-atoms-from-depletion-result/4987/1 "2024-11-22T08:29:12Z")

</div>

Hi, everyone, I get an error when trying to get get atom. Can someone tell me what part I’m having problems with?  
`import numpy as np  
import matplotlib.pyplot as plt  
import openmc.deplete  
import openmc  
import pandas as pd

time\_units=‘d’  
results = openmc.deplete.ResultsList.from\_hdf5(‘./home/OPENMC/Teras/10%/depletion\_results.h5’)  
time, k = results.get\_keff(time\_units)

############# U233 ###########################  
data\_u233 =  
for i in range(1, 8):  
for i in id :  
\_time, u233 = results.get\_atoms( str(i),“U233”,“atom/b-cm”)  
data\_u233.append(u233)  
data\_U233 = pd.DataFrame(list(map(np.ravel, data\_u233)) )  
data\_U233.to\_excel(‘Data U233.xlsx’)  
`

I get an error in results = openmc.deplete.ResultsList.from\_hdf5(‘./home/OPENMC/Teras/10%/depletion\_results.h5’)

TypeError: **init** () takes 1 positional argument but 2 were given

---

<div class="post-metadata">

**Author:** ![wahidluthfi](https://yyz2.discourse-cdn.com/free1/user_avatar/openmc.discourse.group/wahidluthfi/32/3375_2.png) [@wahidluthfi](https://openmc.discourse.group/u/wahidluthfi)\
**Post date:** [December 4, 2024, 10:47pm UTC](https://openmc.discourse.group/t/error-get-atoms-from-depletion-result/4987/2 "2024-12-04T22:47:48Z")

</div>

Hai MAKurniawan, welcome to openmc community.  
Sorry if I didn’t get to what you want, but I am using `openmc.deplete.Results("./depletion_results.h5")` when I want to get some info from the depletion results, including the atomic density of each depleteable materials.

This notebook might be helpful for you

> <https://github.com/openmc-dev/openmc-notebooks/blob/main/depletion.ipynb>
