miladmolanaeiamin alikhaniMohammadReza BehnamEhsan AerabiErfan Saghabashi
Published

Smart Traffic Light

This project monitors crossroads with a camera and change traffic lights based on the number of cars waiting on each side.

IntermediateWork in progress20 days1,687
Smart Traffic Light

Things used in this project

Story

Read more

Schematics

this the video show the run of this code and the schematics of this project

Code

turn on led

Python
## -*- coding: utf-8 -*-

import cv2
print(cv2.__version__)
from picamera import PiCamera
import time

camera= PiCamera()
camera.resolution =(860 ,720)

camera.start_preview()
camera.start_recording('vide.h264')
time.sleep(5)
camera.stop_recording()
camera.stop_preview()

cascade_src = 'cars.xml'
video_src = 'vide.h264'
#video_src = 'dataset/video2.avi'

cap = cv2.VideoCapture(video_src)
car_cascade = cv2.CascadeClassifier(cascade_src)

while True:
    ret, img = cap.read()
    if (type(img) == type(None)):
        break
    
    gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
    
    cars = car_cascade.detectMultiScale(gray, 1.1, 1)

    for (x,y,w,h) in cars:
        cv2.rectangle(img,(x,y),(x+w,y+h),(0,0,255),2)      
    
    cv2.imshow('video', img)
#    print "Found "+str(len(cars))+" car(s)"
   
cv2.destroyAllWindows()

detecting cars

XML
<?xml version="1.0"?>
<!-- Add more negative to training. -->
<opencv_storage>
<cars3 type_id="opencv-haar-classifier">
  <size>
    20 20</size>
  <stages>
    <_>
      <!-- stage 0 -->
      <trees>
        <_>
          <!-- tree 0 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 12 8 8 -1.</_>
                <_>
                  6 16 8 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0452074706554413</threshold>
            <left_val>-0.7191650867462158</left_val>
            <right_val>0.7359663248062134</right_val></_></_>
        <_>
          <!-- tree 1 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 12 18 1 -1.</_>
                <_>
                  7 12 6 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0161712504923344</threshold>
            <left_val>0.5866637229919434</left_val>
            <right_val>-0.5909150242805481</right_val></_></_>
        <_>
          <!-- tree 2 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  7 18 5 2 -1.</_>
                <_>
                  7 19 5 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0119725503027439</threshold>
            <left_val>-0.3645753860473633</left_val>
            <right_val>0.8175076246261597</right_val></_></_>
        <_>
          <!-- tree 3 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 12 11 4 -1.</_>
                <_>
                  5 14 11 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0554178208112717</threshold>
            <left_val>-0.5766019225120544</left_val>
            <right_val>0.8059020042419434</right_val></_></_></trees>
      <stage_threshold>-1.0691740512847900</stage_threshold>
      <parent>-1</parent>
      <next>-1</next></_>
    <_>
      <!-- stage 1 -->
      <trees>
        <_>
          <!-- tree 0 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 12 18 2 -1.</_>
                <_>
                  7 12 6 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0243058893829584</threshold>
            <left_val>0.5642552971839905</left_val>
            <right_val>-0.7375097870826721</right_val></_></_>
        <_>
          <!-- tree 1 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 1 14 6 -1.</_>
                <_>
                  3 3 14 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0302439108490944</threshold>
            <left_val>0.5537161827087402</left_val>
            <right_val>-0.5089462995529175</right_val></_></_>
        <_>
          <!-- tree 2 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  4 8 12 9 -1.</_>
                <_>
                  4 11 12 3 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.1937028020620346</threshold>
            <left_val>0.7614368200302124</left_val>
            <right_val>-0.3485977053642273</right_val></_></_>
        <_>
          <!-- tree 3 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  8 18 12 2 -1.</_>
                <_>
                  14 18 6 1 2.</_>
                <_>
                  8 19 6 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0120156398043036</threshold>
            <left_val>-0.4035871028900146</left_val>
            <right_val>0.6296288967132568</right_val></_></_>
        <_>
          <!-- tree 4 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  0 12 6 6 -1.</_>
                <_>
                  2 12 2 6 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.9895049519836903e-03</threshold>
            <left_val>-0.4086846113204956</left_val>
            <right_val>0.4285241067409515</right_val></_></_>
        <_>
          <!-- tree 5 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 11 9 8 -1.</_>
                <_>
                  6 15 9 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.1299877017736435</threshold>
            <left_val>-0.2570166885852814</left_val>
            <right_val>0.5929297208786011</right_val></_></_>
        <_>
          <!-- tree 6 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 6 10 2 -1.</_>
                <_>
                  1 6 5 1 2.</_>
                <_>
                  6 7 5 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-6.0164160095155239e-03</threshold>
            <left_val>0.5601549744606018</left_val>
            <right_val>-0.2849527895450592</right_val></_></_></trees>
      <stage_threshold>-1.0788700580596924</stage_threshold>
      <parent>0</parent>
      <next>-1</next></_>
    <_>
      <!-- stage 2 -->
      <trees>
        <_>
          <!-- tree 0 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 2 14 12 -1.</_>
                <_>
                  3 6 14 4 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0943963602185249</threshold>
            <left_val>-0.5406976938247681</left_val>
            <right_val>0.5407304763793945</right_val></_></_>
        <_>
          <!-- tree 1 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 11 18 9 -1.</_>
                <_>
                  7 11 6 9 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0279577299952507</threshold>
            <left_val>0.3281945884227753</left_val>
            <right_val>-0.7144141197204590</right_val></_></_>
        <_>
          <!-- tree 2 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 12 10 4 -1.</_>
                <_>
                  5 14 10 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0635356530547142</threshold>
            <left_val>-0.3744345009326935</left_val>
            <right_val>0.5956786870956421</right_val></_></_>
        <_>
          <!-- tree 3 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 18 9 2 -1.</_>
                <_>
                  6 19 9 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0211040005087852</threshold>
            <left_val>-0.4845815896987915</left_val>
            <right_val>0.7378302812576294</right_val></_></_>
        <_>
          <!-- tree 4 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  9 12 2 8 -1.</_>
                <_>
                  9 16 2 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.6957250665873289e-03</threshold>
            <left_val>-0.8702409863471985</left_val>
            <right_val>0.2475769072771072</right_val></_></_>
        <_>
          <!-- tree 5 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  15 3 3 16 -1.</_>
                <_>
                  15 11 3 8 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0110464803874493</threshold>
            <left_val>-0.5981134176254272</left_val>
            <right_val>0.1849218010902405</right_val></_></_>
        <_>
          <!-- tree 6 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  7 9 1 6 -1.</_>
                <_>
                  7 11 1 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-1.3549139839597046e-04</threshold>
            <left_val>0.3266639113426208</left_val>
            <right_val>-0.8332661986351013</right_val></_></_>
        <_>
          <!-- tree 7 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 0 8 6 -1.</_>
                <_>
                  6 3 8 3 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0495516993105412</threshold>
            <left_val>0.7439032196998596</left_val>
            <right_val>-0.4024896025657654</right_val></_></_>
        <_>
          <!-- tree 8 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 13 6 1 -1.</_>
                <_>
                  4 13 3 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-1.9892829004675150e-03</threshold>
            <left_val>0.5047793984413147</left_val>
            <right_val>-0.5123764276504517</right_val></_></_>
        <_>
          <!-- tree 9 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  10 10 6 1 -1.</_>
                <_>
                  12 10 2 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-5.7016697246581316e-04</threshold>
            <left_val>0.2391823977231979</left_val>
            <right_val>-0.2104973942041397</right_val></_></_>
        <_>
          <!-- tree 10 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  4 10 6 1 -1.</_>
                <_>
                  6 10 2 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>5.4985969327390194e-03</threshold>
            <left_val>-0.3141318857669830</left_val>
            <right_val>0.7439212799072266</right_val></_></_>
        <_>
          <!-- tree 11 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 6 8 3 -1.</_>
                <_>
                  6 7 8 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-7.7209789305925369e-03</threshold>
            <left_val>0.6021335721015930</left_val>
            <right_val>-0.3841854035854340</right_val></_></_></trees>
      <stage_threshold>-1.5200910568237305</stage_threshold>
      <parent>1</parent>
      <next>-1</next></_>
    <_>
      <!-- stage 3 -->
      <trees>
        <_>
          <!-- tree 0 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 12 14 1 -1.</_>
                <_>
                  8 12 7 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-1.1992900399491191e-03</threshold>
            <left_val>0.2906270921230316</left_val>
            <right_val>-0.7548354268074036</right_val></_></_>
        <_>
          <!-- tree 1 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 2 15 12 -1.</_>
                <_>
                  5 6 15 4 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0943495184183121</threshold>
            <left_val>-0.4595882892608643</left_val>
            <right_val>0.3241611123085022</right_val></_></_>
        <_>
          <!-- tree 2 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  7 18 6 2 -1.</_>
                <_>
                  7 19 6 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0227251593023539</threshold>
            <left_val>-0.2826507091522217</left_val>
            <right_val>0.7242512702941895</right_val></_></_>
        <_>
          <!-- tree 3 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 12 10 4 -1.</_>
                <_>
                  5 14 10 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0585403405129910</threshold>
            <left_val>-0.5193219780921936</left_val>
            <right_val>0.6013407111167908</right_val></_></_>
        <_>
          <!-- tree 4 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  2 19 4 1 -1.</_>
                <_>
                  4 19 2 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.8358890631352551e-05</threshold>
            <left_val>-0.6561384201049805</left_val>
            <right_val>0.3897354006767273</right_val></_></_>
        <_>
          <!-- tree 5 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  10 12 10 8 -1.</_>
                <_>
                  10 16 10 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>3.9341559750027955e-04</threshold>
            <left_val>-0.8008638024330139</left_val>
            <right_val>0.2018187046051025</right_val></_></_>
        <_>
          <!-- tree 6 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 13 6 6 -1.</_>
                <_>
                  4 13 3 6 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-5.8259762590751052e-04</threshold>
            <left_val>0.2970958054065704</left_val>
            <right_val>-0.8628513216972351</right_val></_></_>
        <_>
          <!-- tree 7 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  9 18 6 2 -1.</_>
                <_>
                  12 18 3 1 2.</_>
                <_>
                  9 19 3 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.7955149562330917e-05</threshold>
            <left_val>-0.4508801102638245</left_val>
            <right_val>0.1758446991443634</right_val></_></_>
        <_>
          <!-- tree 8 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 10 9 10 -1.</_>
                <_>
                  1 15 9 5 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>1.2162160128355026e-03</threshold>
            <left_val>-0.8695623278617859</left_val>
            <right_val>0.2619656026363373</right_val></_></_>
        <_>
          <!-- tree 9 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 2 18 5 -1.</_>
                <_>
                  7 2 6 5 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.0133769698441029</threshold>
            <left_val>-0.6464508175849915</left_val>
            <right_val>0.3887208998203278</right_val></_></_>
        <_>
          <!-- tree 10 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 12 18 4 -1.</_>
                <_>
                  7 12 6 4 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0113867800682783</threshold>
            <left_val>0.2826564013957977</left_val>
            <right_val>-0.8351002931594849</right_val></_></_>
        <_>
          <!-- tree 11 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  9 11 6 3 -1.</_>
                <_>
                  9 11 3 3 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.6949660386890173e-03</threshold>
            <left_val>-0.5282859802246094</left_val>
            <right_val>0.6657627820968628</right_val></_></_>
        <_>
          <!-- tree 12 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 10 3 2 -1.</_>
                <_>
                  6 10 1 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.8329479391686618e-05</threshold>
            <left_val>-0.6864507794380188</left_val>
            <right_val>0.5240061283111572</right_val></_></_>
        <_>
          <!-- tree 13 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  8 12 9 8 -1.</_>
                <_>
                  8 16 9 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>1.4069270109757781e-03</threshold>
            <left_val>-0.8969905972480774</left_val>
            <right_val>0.2389785945415497</right_val></_></_>
        <_>
          <!-- tree 14 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 1 3 2 -1.</_>
                <_>
                  6 2 3 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-2.9115570214344189e-05</threshold>
            <left_val>0.4608972072601318</left_val>
            <right_val>-0.8574141860008240</right_val></_></_>
        <_>
          <!-- tree 15 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  2 12 18 6 -1.</_>
                <_>
                  2 14 18 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>4.5082978904247284e-03</threshold>
            <left_val>-0.7511271238327026</left_val>
            <right_val>0.4849173128604889</right_val></_></_>
        <_>
          <!-- tree 16 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  0 11 18 1 -1.</_>
                <_>
                  6 11 6 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-0.0198406204581261</threshold>
            <left_val>0.6246759295463562</left_val>
            <right_val>-0.7629678845405579</right_val></_></_>
        <_>
          <!-- tree 17 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  9 5 6 3 -1.</_>
                <_>
                  9 6 6 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>3.8021910004317760e-03</threshold>
            <left_val>-0.4809493124485016</left_val>
            <right_val>0.6243296861648560</right_val></_></_>
        <_>
          <!-- tree 18 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 11 4 6 -1.</_>
                <_>
                  3 14 4 3 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>1.1158349661855027e-04</threshold>
            <left_val>-0.8559886217117310</left_val>
            <right_val>0.3861764967441559</right_val></_></_>
        <_>
          <!-- tree 19 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  12 18 2 2 -1.</_>
                <_>
                  13 18 1 1 2.</_>
                <_>
                  12 19 1 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.7662550564855337e-05</threshold>
            <left_val>-0.7629433274269104</left_val>
            <right_val>0.3604950010776520</right_val></_></_>
        <_>
          <!-- tree 20 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 12 9 8 -1.</_>
                <_>
                  3 16 9 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.7047859039157629e-03</threshold>
            <left_val>-0.9496951103210449</left_val>
            <right_val>0.3921845853328705</right_val></_></_>
        <_>
          <!-- tree 21 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 12 9 2 -1.</_>
                <_>
                  9 12 3 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>5.1935878582298756e-04</threshold>
            <left_val>-0.8682754039764404</left_val>
            <right_val>0.4790566861629486</right_val></_></_>
        <_>
          <!-- tree 22 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  2 12 12 8 -1.</_>
                <_>
                  2 12 6 4 2.</_>
                <_>
                  8 16 6 4 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>1.0928940173471346e-04</threshold>
            <left_val>-0.9670708775520325</left_val>
            <right_val>0.6848754286766052</right_val></_></_>
        <_>
          <!-- tree 23 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 6 19 3 -1.</_>
                <_>
                  1 7 19 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>5.7576759718358517e-03</threshold>
            <left_val>-0.9778658747673035</left_val>
            <right_val>0.8792119026184082</right_val></_></_>
        <_>
          <!-- tree 24 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  0 0 8 2 -1.</_>
                <_>
                  0 0 4 1 2.</_>
                <_>
                  4 1 4 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-4.2572239181026816e-05</threshold>
            <left_val>1.</left_val>
            <right_val>-1.</right_val></_></_>
        <_>
          <!-- tree 25 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  12 0 8 2 -1.</_>
                <_>
                  16 0 4 1 2.</_>
                <_>
                  12 1 4 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>3.4698568924795836e-05</threshold>
            <left_val>-0.8942371010780334</left_val>
            <right_val>0.6385173201560974</right_val></_></_>
        <_>
          <!-- tree 26 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 0 13 15 -1.</_>
                <_>
                  1 5 13 5 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>6.0833231545984745e-03</threshold>
            <left_val>-0.9911761283874512</left_val>
            <right_val>0.8617964982986450</right_val></_></_>
        <_>
          <!-- tree 27 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  17 18 1 2 -1.</_>
                <_>
                  17 19 1 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>1.5569420065730810e-04</threshold>
            <left_val>-1.</left_val>
            <right_val>0.9989972114562988</right_val></_></_>
        <_>
          <!-- tree 28 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  0 0 4 3 -1.</_>
                <_>
                  2 0 2 3 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.</threshold>
            <left_val>0.</left_val>
            <right_val>-1.</right_val></_></_>
        <_>
          <!-- tree 29 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  9 19 4 1 -1.</_>
                <_>
                  9 19 2 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>5.8437039115233347e-05</threshold>
            <left_val>-0.9401987791061401</left_val>
            <right_val>0.9499294161796570</right_val></_></_>
        <_>
          <!-- tree 30 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 13 14 4 -1.</_>
                <_>
                  3 15 14 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>8.5243082139641047e-04</threshold>
            <left_val>-1.</left_val>
            <right_val>1.0000870227813721</right_val></_></_>
        <_>
          <!-- tree 31 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  17 0 3 4 -1.</_>
                <_>
                  17 2 3 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.</threshold>
            <left_val>0.</left_val>
            <right_val>-1.</right_val></_></_>
        <_>
          <!-- tree 32 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  7 1 2 3 -1.</_>
                <_>
                  7 2 2 1 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>8.8114888058044016e-05</threshold>
            <left_val>-1.</left_val>
            <right_val>1.0001029968261719</right_val></_></_>
        <_>
          <!-- tree 33 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  17 0 3 4 -1.</_>
                <_>
                  17 2 3 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>0.</threshold>
            <left_val>0.</left_val>
            <right_val>-1.</right_val></_></_>
        <_>
          <!-- tree 34 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 12 18 2 -1.</_>
                <_>
                  7 12 6 2 3.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-1.6535379691049457e-03</threshold>
            <left_val>0.9649471044540405</left_val>
            <right_val>-0.9946994185447693</right_val></_></_>
        <_>
          <!-- tree 35 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  16 3 2 4 -1.</_>
                <_>
                  17 3 1 2 2.</_>
                <_>
                  16 5 1 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.2355250257533044e-04</threshold>
            <left_val>-0.8841317892074585</left_val>
            <right_val>0.5885220170021057</right_val></_></_>
        <_>
          <!-- tree 36 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 13 10 2 -1.</_>
                <_>
                  3 13 5 1 2.</_>
                <_>
                  8 14 5 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-2.0420220680534840e-03</threshold>
            <left_val>0.8850557208061218</left_val>
            <right_val>-0.9887136220932007</right_val></_></_>
        <_>
          <!-- tree 37 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  11 13 6 2 -1.</_>
                <_>
                  11 13 3 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-2.7822980191558599e-03</threshold>
            <left_val>0.8021606206893921</left_val>
            <right_val>-0.8011325001716614</right_val></_></_>
        <_>
          <!-- tree 38 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  6 4 6 12 -1.</_>
                <_>
                  9 4 3 12 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.6262819301337004e-03</threshold>
            <left_val>-0.8629643917083740</left_val>
            <right_val>0.9028394818305969</right_val></_></_>
        <_>
          <!-- tree 39 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  14 5 2 14 -1.</_>
                <_>
                  15 5 1 7 2.</_>
                <_>
                  14 12 1 7 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-5.8437039115233347e-05</threshold>
            <left_val>0.5506380796432495</left_val>
            <right_val>-0.8834760189056396</right_val></_></_>
        <_>
          <!-- tree 40 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  3 2 12 10 -1.</_>
                <_>
                  9 2 6 10 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-1.1351429857313633e-03</threshold>
            <left_val>0.9118285179138184</left_val>
            <right_val>-0.8601468205451965</right_val></_></_>
        <_>
          <!-- tree 41 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  16 11 4 4 -1.</_>
                <_>
                  16 13 4 2 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>6.5544509561732411e-04</threshold>
            <left_val>-0.5529929995536804</left_val>
            <right_val>0.6181765794754028</right_val></_></_>
        <_>
          <!-- tree 42 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  5 19 10 1 -1.</_>
                <_>
                  10 19 5 1 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>3.8200760172912851e-05</threshold>
            <left_val>-0.8676869273185730</left_val>
            <right_val>0.7274010777473450</right_val></_></_>
        <_>
          <!-- tree 43 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  15 2 1 18 -1.</_>
                <_>
                  15 11 1 9 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>-6.2933329900261015e-05</threshold>
            <left_val>0.3377492129802704</left_val>
            <right_val>-0.8335667848587036</right_val></_></_>
        <_>
          <!-- tree 44 -->
          <_>
            <!-- root node -->
            <feature>
              <rects>
                <_>
                  1 4 5 16 -1.</_>
                <_>
                  1 12 5 8 2.</_></rects>
              <tilted>0</tilted></feature>
            <threshold>2.8638119692914188e-04</threshold>
            <left_val>-0.8729416131973267</left_val>
            <right_val>0.7917960286140442</right_val></_></_>
...

This file has been truncated, please download it to see its full contents.

Credits

miladmolanaei

miladmolanaei

1 project • 8 followers
amin alikhani

amin alikhani

1 project • 1 follower
MohammadReza Behnam

MohammadReza Behnam

1 project • 3 followers
Ehsan Aerabi

Ehsan Aerabi

18 projects • 60 followers
Researcher on IoT and Embedded Systems
Erfan Saghabashi

Erfan Saghabashi

1 project • 22 followers

Comments