Question: I simply want to detect face and eyes using haarcascade. But this is the error I am receiving.

```
Traceback (most recent call last):   File "L:/Project/1", line 10, in <module>
    faces=face_cascade.detectMultiscale(gray,1.3,5) AttributeError: 'cv2.CascadeClassifier' object has no attribute

'detectMultiscale'

```

This is the code I found on internet

```
import numpy as np
import cv2

face_cascade=cv2.CascadeClassifier('haarcascade_frontalface_default.xml')
eye_cascade=cv2.CascadeClassifier('haarcascade_eye.xml')

img=cv2.imread('download.jpg')
gray=cv2.cvtColor(img,cv2.COLOR_BGR2GRAY)

faces=face_cascade.detectMultiscale(gray,1.3,5)
for(x,y,w,h) in faces:
    cv2.rectangle(img,(x,y),(x+w,y+h),(255,0,0),2)
    roi_gray=gray[y:y+h,x:x+w]
    roi_color=img[y:y+h,x:x+w]
    eyes=eye_cascade.detectMultiScale(roi_gray)
    for(ex,ey,ew,eh) in eyes:
        cv2.rectangle(roi_color,(ex,ey),(ex+ew,ey+eh),(0,255,0),2)

cv2.imshow('img',img)
cv2.waitKey(0)
cv2.destroyAllWindows

```

Answer: 
`{% for kupon in session %}` will not loop over `app.session.get('kupon')`

what you want to do is:

```
{% for kupon in app.session.get('kupon') %}

```

But looking at you dumped data, `app.session.get('kupon')` is just a single dataset, so you cant even loop that (with desired results)...

it will be just:

```
{{ app.session.get('kupon').game }}

```

extra explanations about your data: you have this in you session:

```
"kupon" => [
    "game" => ...
    "type" => ...
    ...
]

```

to be able to loop over these, you need to make a collection of your data types:

```
"kupon" => [
    [
        "game" => ...
        "type" => ...
        ...
    ],
    [
        "game" => ...
        "type" => ...
        ...
    ],
    ....
]

```
Try below

```
{% if app.session.get('kupon') is not null %}
  {% set kupon = app.session.get('kupon') %}
  <table>
      <tr>
        <td>{{ kupon.game }}</td>
        <td>{{ kupon.type }}</td>
        <td> </td>
      </tr>
  </table>
{% endif %}

```