Datasets:
image
imagewidth (px) 1.28k
1.28k
| annotations
stringlengths 0
263
| image_name
stringlengths 41
50
| partner
stringclasses 3
values | camera
stringclasses 39
values | date
stringlengths 19
19
|
---|---|---|---|---|---|
1 0.313716 0.633438 0.04037210000000002 0.05569420000000003 | sdis-07_brison-110_2024-03-16T08-56-19.jpg | sdis-07 | brison-110 | 2024-03-16T08-56-19 |
|
1 0.349112 0.552534 0.04439870000000001 0.052718800000000066 | force-06_courmettes-160_2024-06-07T09-38-13.jpg | force-06 | courmettes-160 | 2024-06-07T09-38-13 |
|
1 0.0114766 0.735012 0.022545299999999997 0.0492284999999999 | sdis-07_brison-200_2024-01-29T15-15-39.jpg | sdis-07 | brison-200 | 2024-01-29T15-15-39 |
|
1 0.0458948 0.570485 0.03869229999999999 0.06647530000000001 | force-06_cabanelle-327_2024-02-27T09-09-15.jpg | force-06 | cabanelle-327 | 2024-02-27T09-09-15 |
|
1 0.295853 0.810403 0.02872779999999997 0.0988739999999999 | force-06_courmettes-212_2024-01-15T13-27-58.jpg | force-06 | courmettes-212 | 2024-01-15T13-27-58 |
|
force-06_courmettes-160_2024-01-02T12-11-12.jpg | force-06 | courmettes-160 | 2024-01-02T12-11-12 |
||
force-06_courmettes-212_2024-01-26T15-30-41.jpg | force-06 | courmettes-212 | 2024-01-26T15-30-41 |
||
force-06_cabanelle-327_2024-04-03T08-05-01.jpg | force-06 | cabanelle-327 | 2024-04-03T08-05-01 |
||
1 0.95709 0.659528 0.08554119999999998 0.058214999999999906 | sdis-07_brison-200_2024-02-19T16-30-12.jpg | sdis-07 | brison-200 | 2024-02-19T16-30-12 |
|
1 0.0337897 0.559674 0.03383660000000001 0.04022809999999999 | sdis-07_brison-110_2024-03-12T10-06-30.jpg | sdis-07 | brison-110 | 2024-03-12T10-06-30 |
|
1 0.218535 0.503641 0.07821459999999997 0.08206390000000002 | sdis-07_brison-20_2024-01-31T15-13-55.jpg | sdis-07 | brison-20 | 2024-01-31T15-13-55 |
|
sdis-07_brison-110_2024-03-08T10-31-14.jpg | sdis-07 | brison-110 | 2024-03-08T10-31-14 |
||
1 0.376345 0.779719 0.07281020000000005 0.07801799999999992 | force-06_courmettes-212_2024-02-24T16-35-50.jpg | force-06 | courmettes-212 | 2024-02-24T16-35-50 |
|
1 0.296674 0.412267 0.10111300000000001 0.06148129999999996 | force-06_valbonne-349_2024-01-23T11-50-59.jpg | force-06 | valbonne-349 | 2024-01-23T11-50-59 |
|
sdis-07_marguerite-339_2024-01-31T13-16-27.jpg | sdis-07 | marguerite-339 | 2024-01-31T13-16-27 |
||
1 0.229897 0.442702 0.021080900000000014 0.05553790000000003
1 0.011704 0.538178 0.0192773 0.03555930000000007 | sdis-07_brison-20_2024-02-12T16-21-56.jpg | sdis-07 | brison-20 | 2024-02-12T16-21-56 |
|
1 0.241027 0.416133 0.02170470000000002 0.05006710000000003 | sdis-07_marguerite-282_2024-02-13T15-35-22.jpg | sdis-07 | marguerite-282 | 2024-02-13T15-35-22 |
|
1 0.501429 0.583688 0.04613800000000001 0.11218499999999998 | force-06_ferion-142_2024-02-28T14-53-30.jpg | force-06 | ferion-142 | 2024-02-28T14-53-30 |
|
1 0.173248 0.628975 0.025263199999999986 0.04027029999999998
1 0.992888 0.596638 0.014212700000000078 0.03477459999999999 | sdis-07_brison-200_2024-01-15T13-53-35.jpg | sdis-07 | brison-200 | 2024-01-15T13-53-35 |
|
1 0.51303 0.496328 0.025942300000000085 0.0691754 | sdis-07_marguerite-282_2024-06-08T15-49-26.jpg | sdis-07 | marguerite-282 | 2024-06-08T15-49-26 |
|
sdis-07_brison-200_2024-02-20T16-53-46.jpg | sdis-07 | brison-200 | 2024-02-20T16-53-46 |
||
1 0.105924 0.696863 0.03346170000000001 0.03990260000000001 | sdis-07_brison-200_2024-03-20T09-31-47.jpg | sdis-07 | brison-200 | 2024-03-20T09-31-47 |
|
1 0.450568 0.657587 0.02443430000000002 0.068133 | force-06_cabanelle-244_2024-09-12T14-01-53.jpg | force-06 | cabanelle-244 | 2024-09-12T14-01-53 |
|
sdis-77_croix-augas-59_2024-07-08T15-49-04.jpg | sdis-77 | croix-augas-59 | 2024-07-08T15-49-04 |
||
sdis-77_croix-augas-110_2024-08-12T14-45-45.jpg | sdis-77 | croix-augas-110 | 2024-08-12T14-45-45 |
||
1 0.271984 0.804571 0.03136030000000001 0.04920619999999998 | force-06_courmettes-212_2024-01-08T15-21-40.jpg | force-06 | courmettes-212 | 2024-01-08T15-21-40 |
|
1 0.132819 0.49994 0.03500160000000001 0.04803440000000003 | force-06_courmettes-212_2024-01-25T13-57-41.jpg | force-06 | courmettes-212 | 2024-01-25T13-57-41 |
|
1 0.02647 0.513978 0.05051699999999999 0.03207270000000001 | sdis-07_brison-110_2024-03-01T11-37-52.jpg | sdis-07 | brison-110 | 2024-03-01T11-37-52 |
|
1 0.106626 0.746435 0.034773899999999996 0.027724400000000093 | force-06_courmettes-160_2024-01-09T10-41-14.jpg | force-06 | courmettes-160 | 2024-01-09T10-41-14 |
|
1 0.166729 0.578998 0.021141100000000024 0.02398110000000009 | sdis-07_brison-110_2024-08-17T08-54-58.jpg | sdis-07 | brison-110 | 2024-08-17T08-54-58 |
|
1 0.146181 0.518916 0.08910410000000002 0.04901139999999998 | sdis-07_brison-110_2024-03-01T09-12-44.jpg | sdis-07 | brison-110 | 2024-03-01T09-12-44 |
|
1 0.384801 0.587283 0.03409589999999996 0.05442429999999998 | force-06_valbonne-138_2024-01-13T17-17-49.jpg | force-06 | valbonne-138 | 2024-01-13T17-17-49 |
|
1 0.182638 0.636508 0.01972980000000002 0.025478600000000018 | sdis-07_brison-200_2024-01-21T13-32-28.jpg | sdis-07 | brison-200 | 2024-01-21T13-32-28 |
|
1 0.406245 0.334342 0.04596520000000004 0.06062500000000004 | sdis-07_brison-20_2024-02-14T15-24-46.jpg | sdis-07 | brison-20 | 2024-02-14T15-24-46 |
|
1 0.473056 0.676309 0.03592709999999999 0.04911679999999996 | sdis-07_brison-110_2024-03-27T12-54-43.jpg | sdis-07 | brison-110 | 2024-03-27T12-54-43 |
|
1 0.374944 0.333011 0.01578029999999997 0.022127200000000014 | sdis-77_croix-augas-59_2024-09-07T10-26-51.jpg | sdis-77 | croix-augas-59 | 2024-09-07T10-26-51 |
|
1 0.0268512 0.4218 0.010446399999999998 0.026931600000000055 | force-06_cabanelle-46_2024-02-23T09-50-39.jpg | force-06 | cabanelle-46 | 2024-02-23T09-50-39 |
|
1 0.298741 0.615807 0.02847580000000005 0.04402559999999989
1 0.0924852 0.70277 0.05846319999999999 0.04693759999999991 | sdis-07_brison-200_2024-02-07T15-31-59.jpg | sdis-07 | brison-200 | 2024-02-07T15-31-59 |
|
1 0.325966 0.450279 0.03439570000000003 0.02848980000000001 | sdis-07_marguerite-282_2024-01-30T15-54-10.jpg | sdis-07 | marguerite-282 | 2024-01-30T15-54-10 |
|
1 0.0629051 0.725492 0.125588 0.11739800000000011 | force-06_courmettes-275_2024-02-09T16-19-09.jpg | force-06 | courmettes-275 | 2024-02-09T16-19-09 |
|
force-06_valbonne-349_2024-04-04T17-28-47.jpg | force-06 | valbonne-349 | 2024-04-04T17-28-47 |
||
1 0.464954 0.351592 0.03538949999999996 0.03497919999999999 | sdis-07_marguerite-282_2024-02-08T11-57-15.jpg | sdis-07 | marguerite-282 | 2024-02-08T11-57-15 |
|
1 0.519247 0.531423 0.027180900000000063 0.038484799999999986 | force-06_courmettes-160_2024-01-06T10-25-52.jpg | force-06 | courmettes-160 | 2024-01-06T10-25-52 |
|
1 0.0646557 0.688057 0.041977299999999995 0.034742300000000004 | force-06_courmettes-275_2024-06-21T05-58-39.jpg | force-06 | courmettes-275 | 2024-06-21T05-58-39 |
|
1 0.0254784 0.615442 0.0509568 0.08399709999999994 | sdis-07_marguerite-29_2024-01-31T10-58-17.jpg | sdis-07 | marguerite-29 | 2024-01-31T10-58-17 |
|
1 0.441039 0.613006 0.06675520000000001 0.07381860000000007 | sdis-07_marguerite-339_2024-02-21T13-02-05.jpg | sdis-07 | marguerite-339 | 2024-02-21T13-02-05 |
|
1 0.131563 0.511384 0.02051180000000001 0.023966699999999952
1 0.265421 0.505377 0.036604900000000024 0.038181900000000046 | force-06_courmettes-212_2024-01-09T11-16-01.jpg | force-06 | courmettes-212 | 2024-01-09T11-16-01 |
|
1 0.403124 0.344316 0.014956700000000045 0.014171000000000045 | sdis-77_croix-augas-8_2024-07-12T21-47-54.jpg | sdis-77 | croix-augas-8 | 2024-07-12T21-47-54 |
|
1 0.490464 0.655802 0.11281800000000003 0.08044260000000003 | force-06_courmettes-160_2024-02-28T10-22-18.jpg | force-06 | courmettes-160 | 2024-02-28T10-22-18 |
|
1 0.870706 0.690209 0.049300200000000016 0.051256200000000085
1 0.179619 0.595527 0.024739100000000014 0.03566120000000006 | sdis-07_brison-110_2024-01-09T10-41-11.jpg | sdis-07 | brison-110 | 2024-01-09T10-41-11 |
|
1 0.0139307 0.727436 0.027861500000000004 0.06226820000000011 | sdis-07_brison-200_2024-01-15T15-24-45.jpg | sdis-07 | brison-200 | 2024-01-15T15-24-45 |
|
sdis-07_brison-200_2024-03-17T17-19-57.jpg | sdis-07 | brison-200 | 2024-03-17T17-19-57 |
||
1 0.49103 0.634387 0.056646899999999945 0.03818600000000005 | sdis-07_marguerite-339_2024-03-18T14-19-57.jpg | sdis-07 | marguerite-339 | 2024-03-18T14-19-57 |
|
1 0.0776863 0.568912 0.029480299999999987 0.08574499999999996 | force-06_cabanelle-327_2024-01-08T12-00-47.jpg | force-06 | cabanelle-327 | 2024-01-08T12-00-47 |
|
1 0.404578 0.544519 0.029915299999999978 0.025760400000000017 | force-06_valbonne-223_2024-01-22T15-08-10.jpg | force-06 | valbonne-223 | 2024-01-22T15-08-10 |
|
1 0.0282535 0.717926 0.0561816 0.08599850000000009 | sdis-07_brison-200_2024-01-15T15-27-12.jpg | sdis-07 | brison-200 | 2024-01-15T15-27-12 |
|
1 0.193831 0.598493 0.022521100000000016 0.03522000000000003 | sdis-07_brison-110_2024-01-09T11-36-12.jpg | sdis-07 | brison-110 | 2024-01-09T11-36-12 |
|
1 0.0394446 0.47249 0.030045299999999997 0.07472460000000003 | force-06_valbonne-349_2024-04-20T19-04-04.jpg | force-06 | valbonne-349 | 2024-04-20T19-04-04 |
|
1 0.348618 0.4851 0.03929360000000004 0.0614344 | sdis-07_marguerite-185_2024-01-26T13-13-23.jpg | sdis-07 | marguerite-185 | 2024-01-26T13-13-23 |
|
force-06_courmettes-160_2024-01-16T11-29-42.jpg | force-06 | courmettes-160 | 2024-01-16T11-29-42 |
||
force-06_courmettes-160_2024-02-01T12-54-19.jpg | force-06 | courmettes-160 | 2024-02-01T12-54-19 |
||
1 0.877561 0.697348 0.024813900000000055 0.0432357000000001
1 0.417069 0.653638 0.0350819 0.04796249999999991
1 0.113327 0.5842 0.07786570000000001 0.07104029999999995 | sdis-07_brison-110_2024-02-21T11-07-10.jpg | sdis-07 | brison-110 | 2024-02-21T11-07-10 |
|
1 0.258543 0.572844 0.025694899999999993 0.058425699999999914 | force-06_courmettes-80_2024-01-10T11-30-41.jpg | force-06 | courmettes-80 | 2024-01-10T11-30-41 |
|
1 0.486894 0.678884 0.02473599999999998 0.028414600000000068 | sdis-07_brison-110_2024-01-21T11-45-22.jpg | sdis-07 | brison-110 | 2024-01-21T11-45-22 |
|
1 0.0468836 0.575985 0.05020730000000001 0.06979840000000004 | force-06_cabanelle-327_2024-02-26T14-51-41.jpg | force-06 | cabanelle-327 | 2024-02-26T14-51-41 |
|
1 0.102406 0.702936 0.02602180000000001 0.026721999999999912 | sdis-07_brison-200_2024-03-20T09-00-39.jpg | sdis-07 | brison-200 | 2024-03-20T09-00-39 |
|
1 0.0917627 0.558511 0.179199 0.24752099999999994 | sdis-07_brison-20_2024-01-24T10-16-44.jpg | sdis-07 | brison-20 | 2024-01-24T10-16-44 |
|
1 0.709338 0.548409 0.023765999999999954 0.03130260000000007
1 0.355409 0.615426 0.010204899999999961 0.021286399999999928 | sdis-07_brison-200_2024-02-14T14-42-39.jpg | sdis-07 | brison-200 | 2024-02-14T14-42-39 |
|
1 0.387473 0.622179 0.05814890000000006 0.056989500000000026 | force-06_ferion-142_2024-02-20T11-38-56.jpg | force-06 | ferion-142 | 2024-02-20T11-38-56 |
|
1 0.52352 0.574388 0.008330820000000072 0.02411500000000011 | force-06_ferion-142_2024-02-29T10-06-01.jpg | force-06 | ferion-142 | 2024-02-29T10-06-01 |
|
1 0.564355 0.338024 0.029393699999999967 0.03362290000000001 | sdis-77_croix-augas-59_2024-07-19T11-31-46.jpg | sdis-77 | croix-augas-59 | 2024-07-19T11-31-46 |
|
1 0.0715841 0.504826 0.041633699999999996 0.20997500000000002 | force-06_cabanelle-327_2024-01-08T11-44-24.jpg | force-06 | cabanelle-327 | 2024-01-08T11-44-24 |
|
1 0.468805 0.352706 0.03236680000000003 0.033016900000000016 | sdis-07_marguerite-282_2024-02-08T12-05-52.jpg | sdis-07 | marguerite-282 | 2024-02-08T12-05-52 |
|
1 0.176305 0.632261 0.020867499999999983 0.03273389999999998
1 0.991083 0.601739 0.015642600000000062 0.03924620000000001 | sdis-07_brison-200_2024-01-15T14-15-06.jpg | sdis-07 | brison-200 | 2024-01-15T14-15-06 |
|
1 0.4875769999999999 0.687675 0.03228519999999996 0.037441999999999975 | sdis-07_brison-110_2024-03-27T13-45-14.jpg | sdis-07 | brison-110 | 2024-03-27T13-45-14 |
|
1 0.866577 0.590873 0.017424799999999907 0.018516500000000047 | force-06_courmettes-160_2024-01-24T10-46-36.jpg | force-06 | courmettes-160 | 2024-01-24T10-46-36 |
|
force-06_courmettes-212_2024-01-12T12-03-37.jpg | force-06 | courmettes-212 | 2024-01-12T12-03-37 |
||
1 0.036759700000000006 0.69557 0.0673163 0.09329750000000003
1 0.775671 0.614307 0.031697499999999934 0.023659000000000097 | force-06_courmettes-160_2024-04-20T18-30-43.jpg | force-06 | courmettes-160 | 2024-04-20T18-30-43 |
|
1 0.120266 0.69066 0.06427269999999999 0.11875600000000008 | force-06_cabanelle-327_2024-06-02T17-26-58.jpg | force-06 | cabanelle-327 | 2024-06-02T17-26-58 |
|
1 0.461066 0.327946 0.014554199999999962 0.01097999999999999 | sdis-77_croix-augas-8_2024-08-22T15-29-42.jpg | sdis-77 | croix-augas-8 | 2024-08-22T15-29-42 |
|
1 0.410008 0.516081 0.04610939999999997 0.05763030000000002 | sdis-07_brison-290_2024-02-07T16-46-03.jpg | sdis-07 | brison-290 | 2024-02-07T16-46-03 |
|
sdis-07_brison-200_2024-01-23T16-22-08.jpg | sdis-07 | brison-200 | 2024-01-23T16-22-08 |
||
1 0.00710795 0.435907 0.0142159 0.06214209999999998
1 0.606464 0.354379 0.13802500000000006 0.08307299999999995 | sdis-07_brison-290_2024-02-06T15-42-09.jpg | sdis-07 | brison-290 | 2024-02-06T15-42-09 |
|
1 0.218654 0.600552 0.0307751 0.08280660000000006 | sdis-07_marguerite-29_2024-03-25T09-53-41.jpg | sdis-07 | marguerite-29 | 2024-03-25T09-53-41 |
|
1 0.478497 0.351181 0.019834099999999966 0.024777500000000008 | sdis-07_marguerite-282_2024-02-08T13-19-48.jpg | sdis-07 | marguerite-282 | 2024-02-08T13-19-48 |
|
1 0.213073 0.368652 0.005180740000000017 0.010524599999999995 | sdis-77_croix-augas-8_2024-07-05T21-47-51.jpg | sdis-77 | croix-augas-8 | 2024-07-05T21-47-51 |
|
1 0.330544 0.481923 0.06837389999999999 0.05624910000000005 | sdis-07_marguerite-185_2024-01-26T12-39-52.jpg | sdis-07 | marguerite-185 | 2024-01-26T12-39-52 |
|
sdis-07_marguerite-282_2024-01-27T17-14-14.jpg | sdis-07 | marguerite-282 | 2024-01-27T17-14-14 |
||
1 0.103454 0.562181 0.035995200000000005 0.11833399999999994 | sdis-07_marguerite-29_2024-02-20T10-16-55.jpg | sdis-07 | marguerite-29 | 2024-02-20T10-16-55 |
|
1 0.334086 0.495185 0.008709260000000052 0.02391589999999999 | force-06_courmettes-212_2024-01-12T13-13-07.jpg | force-06 | courmettes-212 | 2024-01-12T13-13-07 |
|
1 0.0326793 0.721776 0.027241699999999997 0.03289769999999992 | sdis-07_brison-200_2024-01-09T15-17-07.jpg | sdis-07 | brison-200 | 2024-01-09T15-17-07 |
|
force-06_ferion-287_2024-01-30T11-22-33.jpg | force-06 | ferion-287 | 2024-01-30T11-22-33 |
||
1 0.147656 0.585131 0.100244 0.18118999999999996 | sdis-07_brison-20_2024-01-24T10-33-45.jpg | sdis-07 | brison-20 | 2024-01-24T10-33-45 |
|
1 0.673978 0.536841 0.07304949999999999 0.09785719999999998 | force-06_valbonne-67_2024-01-24T09-58-23.jpg | force-06 | valbonne-67 | 2024-01-24T09-58-23 |
|
1 0.372395 0.57323 0.048160300000000045 0.052159000000000066 | force-06_cabanelle-327_2024-01-01T15-42-08.jpg | force-06 | cabanelle-327 | 2024-01-01T15-42-08 |
|
1 0.719153 0.332637 0.011646499999999893 0.033859399999999984
1 0.192982 0.354671 0.007583500000000021 0.01749500000000004 | sdis-77_croix-augas-265_2024-07-21T17-43-37.jpg | sdis-77 | croix-augas-265 | 2024-07-21T17-43-37 |
|
sdis-07_brison-290_2024-03-19T18-58-51.jpg | sdis-07 | brison-290 | 2024-03-19T18-58-51 |
||
1 0.142719 0.456994 0.10164899999999999 0.08719140000000003 | sdis-07_marguerite-29_2024-01-27T15-27-16.jpg | sdis-07 | marguerite-29 | 2024-01-27T15-27-16 |
|
1 0.254862 0.40691 0.007729839999999988 0.018336200000000025 | sdis-07_marguerite-282_2024-02-07T16-49-39.jpg | sdis-07 | marguerite-282 | 2024-02-07T16-49-39 |
|
1 0.337802 0.543074 0.03137690000000004 0.03422649999999994 | force-06_courmettes-160_2024-01-23T10-42-39.jpg | force-06 | courmettes-160 | 2024-01-23T10-42-39 |
Pyro-SDIS Dataset
⚠️ Warning: This is a pre-release version of the Pyro-SDIS dataset.
This subset is provided for early access and experimentation. Not all images are currently included, and there may still be annotation errors. The full release of the 2025 version of Pyro-SDIS (based on images collected in 2024) will be available in January 2025.
About the Dataset
Pyro-SDIS is a dataset designed for wildfire smoke detection using AI models. It is developed in collaboration with the Fire and Rescue Services (SDIS) in France and the dedicated volunteers of the Pyronear association.
The images in this dataset come from Pyronear cameras installed with the support of our SDIS partners. These images have been carefully annotated by Pyronear volunteers, whose tireless efforts we deeply appreciate.
We extend our heartfelt thanks to all Pyronear volunteers and our SDIS partners for their trust and support:
- Force 06
- SDIS 07
- SDIS 12
- SDIS 77
Additionally, we express our gratitude to the DINUM for their financial and strategic support through the AIC, Etalab, and the Legal Service. Special thanks also go to the Mission Stratégie Prospective (MSP) for their guidance and collaboration.
The Pyro-SDIS Subset contains 33,636 images, including:
- 28,103 images with smoke
- 31,975 smoke instances
This dataset is formatted to be compatible with the Ultralytics YOLO framework, enabling efficient training of object detection models.
Stay tuned for the full release in January 2025, which will include additional images and refined annotations. Thank you for your interest and support in advancing wildfire detection technologies!
Dataset Overview
Contents
The Pyro-SDIS Subset contains images and annotations for wildfire smoke detection. The dataset is structured with the following metadata for each image:
- Image Path: File path to the image.
- Annotations: YOLO-format bounding box annotations for smoke detection:
class_id
: Class label (e.g., smoke).x_center
,y_center
: Normalized center coordinates of the bounding box.width
,height
: Normalized width and height of the bounding box.
- Metadata:
partner
: Partner organization responsible for the camera (e.g., SDIS 07, Force 06).camera
: Camera identifier.date
: Date of image capture (formatted asYYYY-MM-DDTHH-MM-SS
).image_name
: Original file name of the image.
- Split: Indicates whether the image belongs to the training or validation set (
train
orval
).
Example Record
Each record in the dataset contains the following structure:
{
"image": "./images/train/partner_camera_date.jpg",
"annotations": "0 0.5 0.5 0.1 0.2",
"split": "train",
"image_name": "partner_camera_date.jpg",
"partner": "partner",
"camera": "camera",
"date": "YYYY-MM-DDTHH-MM-SS"
}
Let me know if you’d like further refinements or if you want me to include specific numbers/statistics for the dataset.
Splits
The dataset is divided into:
- Training split: Used for training the model.
- Validation split: Used to evaluate model performance.
Exporting the Dataset for Ultralytics Training
To train a YOLO model using the Ultralytics framework, the dataset must be structured as follows:
- Images: Stored in
images/train/
andimages/val/
directories. - Annotations: Stored in YOLO-compatible format in
labels/train/
andlabels/val/
directories.
Steps to Export the Dataset
Install Required Libraries:
pip install datasets ultralytics
Define Paths: Set up the directory structure for the Ultralytics dataset:
import os from datasets import load_dataset # Define paths REPO_ID = "pyronear/pyro-sdis" OUTPUT_DIR = "./pyro-sdis" IMAGE_DIR = os.path.join(OUTPUT_DIR, "images") LABEL_DIR = IMAGE_DIR.replace("images", "labels") # Create the directory structure for split in ["train", "val"]: os.makedirs(os.path.join(IMAGE_DIR, split), exist_ok=True) os.makedirs(os.path.join(LABEL_DIR, split), exist_ok=True) # Load the dataset from the Hugging Face Hub dataset = load_dataset(REPO_ID)
Export Dataset: Use the following function to save the dataset in Ultralytics format:
def save_ultralytics_format(dataset_split, split): """ Save a dataset split into the Ultralytics format. Args: dataset_split: The dataset split (e.g., dataset["train"]) split: "train" or "val" """ for example in dataset_split: # Save the image to the appropriate folder image = example["image"] # PIL.Image.Image image_name = example["image_name"] # Original file name output_image_path = os.path.join(IMAGE_DIR, split, image_name) # Save the image object to disk image.save(output_image_path) # Save label annotations = example["annotations"] label_name = image_name.replace(".jpg", ".txt").replace(".png", ".txt") output_label_path = os.path.join(LABEL_DIR, split, label_name) with open(output_label_path, "w") as label_file: label_file.write(annotations) # Save train and validation splits save_ultralytics_format(dataset["train"], "train") save_ultralytics_format(dataset["val"], "val") print("Dataset exported to Ultralytics format.")
Directory Structure: After running the script, the dataset will have the following structure:
pyro-sdis/ ├── images/ │ ├── train/ │ ├── val/ ├── labels/ │ ├── train/ │ ├── val/
Training with Ultralytics YOLO
Download the
data.yaml
File: Use the following code to download the configuration file:from huggingface_hub import hf_hub_download # Correctly set repo_id and repo_type repo_id = "pyronear/pyro-sdis" filename = "data.yaml" # Download data.yaml to the current directory yaml_path = hf_hub_download(repo_id=repo_id, filename=filename, repo_type="dataset", local_dir=".") print(f"data.yaml downloaded to: {yaml_path}")
Train the Model: Install the Ultralytics YOLO framework and train the model:
pip install ultralytics yolo task=detect mode=train data=data.yaml model=yolov8n.pt epochs=50 imgsz=640
License
The dataset is released under the Apache-2.0 License.
Citation
If you use this dataset, please cite:
@dataset{pyro-sdis,
author = {Pyronear Team},
title = {Pyro-SDIS Dataset},
year = {2024},
publisher = {Hugging Face},
url = {https://huggingface.co/pyronear/pyro-sdis}
}
- Downloads last month
- 65