insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22028147 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=22028138 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='environnement' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028147) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028138) result : ((1349836124,), (1349836146,), (1349836152,), (1349836157,), (1349836163,), (1349836169,), (1349836173,), (1349836513,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22028148 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=22028138 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Teint_Dans_La_Masse' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028148) result : ((1349836533,), (1349836534,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028138) result : ((1349836124,), (1349836146,), (1349836152,), (1349836157,), (1349836163,), (1349836169,), (1349836173,), (1349836513,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22028149 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=22028138 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Carton_gris' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028149) result : ((1349836536,), (1349836537,), (1349836538,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028138) result : ((1349836124,), (1349836146,), (1349836152,), (1349836157,), (1349836163,), (1349836169,), (1349836173,), (1349836513,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22028150 , sub_photo_id, 979,now() FROM (SELECT csp.sub_photo_id, csp.crop_hashtag_id, csp.created_at FROM MTRPhoto.crop_sub_photo_ids csp, MTRPhoto.crop_hashtag_ids chi, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp WHERE mpp.mtr_portfolio_id=22028138 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Carton_brun' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028150) result : ((1349836543,), (1349836544,), (1349836545,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22028138) result : ((1349836124,), (1349836146,), (1349836152,), (1349836157,), (1349836163,), (1349836169,), (1349836173,), (1349836513,)) select distinct(cspi.sub_photo_id) from MTRPhoto.crop_hashtag_ids chi, MTRPhoto.crop_sub_photo_ids cspi where chi.type=3726 and chi.photo_id in () and cspi.crop_hashtag_id = chi.id; Catched exception ! Connect or reconnect ! (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')\n and cspi.crop_hashtag_id = chi.id' at line 3") To do ! Use context local managing function ! SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22028138 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('autre_refus','cartonnette','kraft','plastique','flou','papier','mal_croppe','metal','environnement','Teint_Dans_La_Masse','Carton_gris','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22028138 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('autre_refus','cartonnette','kraft','plastique','flou','papier','mal_croppe','metal','environnement','Teint_Dans_La_Masse','Carton_gris','Carton_brun')) AND mptpi.`min_score`=0.5 To do To do query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_autre_refus_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_cartonnette_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_kraft_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_plastique_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_flou_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_papier_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_mal_croppe_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_metal_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_environnement_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_Teint_Dans_La_Masse_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_Carton_gris_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio query : SELECT id FROM MTRUser.mtr_portfolios WHERE name="JRM_diff_batch__03042025_18_30_04_10145_4417_Carton_brun_0.5_chtin_0" AND mtr_user_id=979 Creating new portfolio INSERT IGNORE INTO MTRPhoto.mtr_port_to_port_ids (`mtr_portfolio_id_1`, `mtr_portfolio_id_2`, `type`, `min_score`, `hashtag_id`, `mtr_user_id`) VALUES (%s,%s,%s,%s,%s,%s)[[22028138, 22028151, 4417, 0.5, 2107752406, 979], [22028138, 22028152, 4417, 0.5, 702398920, 979], [22028138, 22028153, 4417, 0.5, 493202403, 979], [22028138, 22028154, 4417, 0.5, 492725882, 979], [22028138, 22028155, 4417, 0.5, 492777938, 979], [22028138, 22028156, 4417, 0.5, 492668766, 979], [22028138, 22028157, 4417, 0.5, 2107755527, 979], [22028138, 22028158, 4417, 0.5, 492628673, 979], [22028138, 22028159, 4417, 0.5, 493012381, 979], [22028138, 22028160, 4417, 0.5, 2107752385, 979], [22028138, 22028161, 4417, 0.5, 2107753020, 979], [22028138, 22028162, 4417, 0.5, 2107753024, 979]] SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22028138 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('autre_refus','cartonnette','kraft','plastique','flou','papier','mal_croppe','metal','environnement','Teint_Dans_La_Masse','Carton_gris','Carton_brun')) AND mptpi.`min_score`=0.5 SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22028138 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('autre_refus','cartonnette','kraft','plastique','flou','papier','mal_croppe','metal','environnement','Teint_Dans_La_Masse','Carton_gris','Carton_brun')) AND mptpi.`min_score`=0.5 To do returned map {'autre_refus': {'main_port_id': 22028138, 'sub_port_id': 22028151, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521300, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'cartonnette': {'main_port_id': 22028138, 'sub_port_id': 22028152, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521301, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'kraft': {'main_port_id': 22028138, 'sub_port_id': 22028153, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521302, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'plastique': {'main_port_id': 22028138, 'sub_port_id': 22028154, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521303, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'flou': {'main_port_id': 22028138, 'sub_port_id': 22028155, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521304, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'papier': {'main_port_id': 22028138, 'sub_port_id': 22028156, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521305, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'mal_croppe': {'main_port_id': 22028138, 'sub_port_id': 22028157, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521306, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'metal': {'main_port_id': 22028138, 'sub_port_id': 22028158, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521307, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'environnement': {'main_port_id': 22028138, 'sub_port_id': 22028159, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521308, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'Teint_Dans_La_Masse': {'main_port_id': 22028138, 'sub_port_id': 22028160, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521309, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'Carton_gris': {'main_port_id': 22028138, 'sub_port_id': 22028161, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521310, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}, 'Carton_brun': {'main_port_id': 22028138, 'sub_port_id': 22028162, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14521311, 'last_updated_at': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_desc': datetime.datetime(2025, 4, 3, 18, 37, 3), 'last_updated_at_asc': datetime.datetime(2025, 4, 3, 18, 37, 3)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028151,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028139 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028152,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028140 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028153,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028141 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028154,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028142 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028155,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028143 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028156,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028144 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028157,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028145 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028158,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028146 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028159,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028147 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028160,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028148 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028161,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028149 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22028162,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22028150 lien utilise dans velours : https://www.fotonower.com/velours/22028151,22028152,22028153,22028154,22028155,22028156,22028157,22028158,22028159,22028160,22028161,22028162?tags=autre_refus,cartonnette,kraft,plastique,flou,papier,mal_croppe,metal,environnement,Teint_Dans_La_Masse,Carton_gris,Carton_brun After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22028138]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] map_info['map_portfolio_photo'] : {22028138: [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124]} final : False mtd_id 4302 list_pids : [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] Looping around the photos to save general results len do output : 1 /22028138. before output type Here is an output not treated by saveGeneral : Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 9 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '22028138', "{'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150}", None, None, None, None, '2721196'), ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196')] time used for this insertion : 1.1602694988250732 save_final save missing photos in datou_result : time spend for datou_step_exec : 6.02553653717041 time spend to save output : 1.1605615615844727 total time spend for step 1 : 7.186098098754883 step2:final Thu Apr 3 18:37:04 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :0, first value : [] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22028138) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} Beginning of datou step final ! query to retrieve results for portfolio 22028138 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1349836124,1349836173,1349836169,1349836163,1349836157,1349836152,1349836146,1349836513); insert ignore into MTRUser.portfolio_carac_ratio (portfolio_id, hashtag_type, hashtag_id, value) values (%s,%s,%s,%s) on DUPLICATE KEY UPDATE value=VALUES(value) After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22028138]) Inside saveOutput : final : False verbose : True original output for save of step final : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} new output for save of step final : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] map_info['map_portfolio_photo'] : {22028138: [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124]} final : False mtd_id 4302 list_pids : [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] Looping around the photos to save general results len do output : 8 /1349836513.Didn't retrieve data . /1349836173.Didn't retrieve data . /1349836169.Didn't retrieve data . /1349836163.Didn't retrieve data . /1349836157.Didn't retrieve data . /1349836152.Didn't retrieve data . /1349836146.Didn't retrieve data . /1349836124.Didn't retrieve data . before output type Used above Used above Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 24 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '22028138', '1349836513', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836173', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836169', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836163', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836157', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836152', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836146', '0.02977487521685605', None, None, None, None, '2721196'), ('4302', '22028138', '1349836124', '0.02977487521685605', None, None, None, None, '2721196')] time used for this insertion : 0.013447046279907227 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.02942681312561035 time spend to save output : 0.013938426971435547 total time spend for step 2 : 0.0433652400970459 step3:velours_tree Thu Apr 3 18:37:05 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : {22028138: [{'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150}]} input_args_next_step : {22028138: ()} output_args : {22028138: [{'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150}]} args : 22028138 depend.output_id : 0 VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : ({'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22028138) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} can't find the photo_desc_type After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22028138]) Inside saveOutput : final : False verbose : True ouput is None No outpout to save, returning out of save general time spend for datou_step_exec : 0.332988977432251 time spend to save output : 0.00013184547424316406 total time spend for step 3 : 0.33312082290649414 step4:send_mail_cod Thu Apr 3 18:37:05 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! complete output_args for input 2 : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} input_args_next_step : {1349836513: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836513 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836173 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836169 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836163 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836157 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836152 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836146 depend.output_id : 0 input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ()} output_args : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',)} args : 1349836124 depend.output_id : 0 Inconsistent number of input and output, step which parrallelize and manage error in input by avoiding sending an output for this data can't be used in tree dependencies of input and output complete output_args for input 3 : {22028138: [{'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150}]} input_args_next_step : {1349836513: ('0.02977487521685605',), 1349836173: ('0.02977487521685605',), 1349836169: ('0.02977487521685605',), 1349836163: ('0.02977487521685605',), 1349836157: ('0.02977487521685605',), 1349836152: ('0.02977487521685605',), 1349836146: ('0.02977487521685605',), 1349836124: ('0.02977487521685605',), 22028138: ()} output_args : {22028138: [{'autre_refus': 22028139, 'cartonnette': 22028140, 'kraft': 22028141, 'plastique': 22028142, 'flou': 22028143, 'papier': 22028144, 'mal_croppe': 22028145, 'metal': 22028146, 'environnement': 22028147, 'Teint_Dans_La_Masse': 22028148, 'Carton_gris': 22028149, 'Carton_brun': 22028150}]} args : 22028138 depend.output_id : 0 We should have FATAL ERROR but same_nb_input_output==True : this should be an optionnal input ! VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :9, first value : ('0.02977487521685605',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22028138) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} dans la step send mail cod work_area: /home/admin/workarea/git/Velours/python in order to get the selector url, please entre the license of selector SELECT photo_id, url FROM MTRBack.photos ph WHERE photo_id IN (1349836513,1349836173,1349836169,1349836163,1349836157,1349836152,1349836146,1349836124) Found this number of photos: 8 ##### Call download_photos : nb_thread : 5 begin to download photo : 1349836124 begin to download photo : 1349836152 begin to download photo : 1349836163 begin to download photo : 1349836173 download finish for photo 1349836173 begin to download photo : 1349836513 download finish for photo 1349836163 begin to download photo : 1349836169 download finish for photo 1349836152 begin to download photo : 1349836157 download finish for photo 1349836124 begin to download photo : 1349836146 download finish for photo 1349836157 download finish for photo 1349836513 download finish for photo 1349836146 download finish for photo 1349836169 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette220281391743698225/ length of list_filenames : 8 ; length of list_pids : 8 ; length of list_args : 8 results_Auto_P22028138_03-04-2025_18_37_05.pdf 22028139 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028139 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette220281391743698225 22028140 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028140 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836540: '1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357112_0.png', 1349836541: '1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357130_0.png', 1349836542: '1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357126_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/093214c9fecaa68b2e9edacce7a683c8_81836212.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/262546ce827d5288bc6fefa824293128_42072902.png change filename to text .imagette220281401743698225/ imagette220281401743698225/1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357126_0.png.png imagette220281401743698225/1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357112_0.png.png imagette220281401743698225/1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357130_0.png.png wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/d7d28542b4b56b54b08e3a4b4c4f7deb_49631811.png imagette220281401743698225 22028141 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028141 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836551: '1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357050_0.png'} change filename to text .imagette220281411743698225/ imagette220281411743698225/1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357050_0.png.png wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/8ab1fa338459eb90c6396e2fcd9915f5_63731180.png imagette220281411743698225 22028142 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028142 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836546: '1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357054_0.png', 1349836547: '1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357053_0.png', 1349836548: '1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357083_0.png', 1349836549: '1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357113_0.png', 1349836550: '1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357129_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/95bc95b5e1d3c483c86a3cccc80cca12_42925143.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/45c784173da47ee5c297876b7dd0bd1f_29934897.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/ce5a2ea058ab4b42dc9509b4ede8abef_59989676.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/07ace7784441097cf3b1d577e9648d2f_59737897.png change filename to text .imagette220281421743698225/ imagette220281421743698225/1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357113_0.png.png imagette220281421743698225/1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357129_0.png.png imagette220281421743698225/1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357083_0.png.png imagette220281421743698225/1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357053_0.png.png imagette220281421743698225/1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357054_0.png.png imagette220281431743698226/ imagette220281451743698226/ imagette220281461743698226/ wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/5761aa2baef08eb8a755405b7d30dde3_56324209.png imagette220281421743698225 22028143 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028143 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette220281431743698226 22028145 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028145 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette220281451743698226 22028146 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028146 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette220281461743698226 22028148 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028148 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836533: '1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357056_0.png', 1349836534: '1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357132_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/a4f36007f552221dc1568bb12c7d2df5_62183708.png change filename to text .imagette220281481743698226/ imagette220281481743698226/1743698112_2442963_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b_rle_crop_3746357056_0.png.png imagette220281481743698226/1743698112_2442963_1349836146_59b96554e65fc0b5b817f0ab0ed62462_rle_crop_3746357132_0.png.png wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/52b40e2cc29b3038977224c28dab2df8_60504860.png imagette220281481743698226 22028149 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028149 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836536: '1743698112_2442963_1349836163_8cb8aaf1005f0664ee1c7fbad6026189_rle_crop_3746357062_0.png', 1349836537: '1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357075_0.png', 1349836538: '1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357080_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/5a2a4fbbbf5bd46bf69cacc09b317a4b_2015721.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/b1ffd8d06776c60fbe474c7309fb7d14_75423857.png change filename to text .imagette220281491743698226/ imagette220281491743698226/1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357075_0.png.png imagette220281491743698226/1743698112_2442963_1349836163_8cb8aaf1005f0664ee1c7fbad6026189_rle_crop_3746357062_0.png.png imagette220281491743698226/1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357080_0.png.png wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/bac5781596b348b674b7f7578a01a6a5_37736006.png imagette220281491743698226 22028150 SELECT ph.photo_id,ph.url,ph.username,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028150 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1349836543: '1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357078_0.png', 1349836544: '1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357117_0.png', 1349836545: '1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357115_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/29461a05f54af9feb41725c463452d5e_63107372.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/2d6fd4bafd363bfc808c3d0a6215a2d8_38432808.png change filename to text .imagette220281501743698226/ imagette220281501743698226/1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357115_0.png.png imagette220281501743698226/1743698112_2442963_1349836152_455375d6b2a87757441bbf20089239e2_rle_crop_3746357117_0.png.png imagette220281501743698226/1743698112_2442963_1349836157_ebc085136055c1ab8b7bc35f3ff4d272_rle_crop_3746357078_0.png.png wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/42902836f8ddccc8e636355e69e3e402_78118329.png imagette220281501743698226 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=22028138 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/22028151,22028152,22028153,22028154,22028155,22028156,22028157,22028158,22028159,22028160,22028161,22028162?tags=autre_refus,cartonnette,kraft,plastique,flou,papier,mal_croppe,metal,environnement,Teint_Dans_La_Masse,Carton_gris,Carton_brun your option no_mail is active, we will not send the real mail to your client args[1349836513] : ('0.02977487521685605',) no score found for photo 1349836513 We are sending mail with results at report@fotonower.com args[1349836173] : ('0.02977487521685605',) no score found for photo 1349836173 We are sending mail with results at report@fotonower.com args[1349836169] : ('0.02977487521685605',) no score found for photo 1349836169 We are sending mail with results at report@fotonower.com args[1349836163] : ('0.02977487521685605',) no score found for photo 1349836163 We are sending mail with results at report@fotonower.com args[1349836157] : ('0.02977487521685605',) no score found for photo 1349836157 We are sending mail with results at report@fotonower.com args[1349836152] : ('0.02977487521685605',) no score found for photo 1349836152 We are sending mail with results at report@fotonower.com args[1349836146] : ('0.02977487521685605',) no score found for photo 1349836146 We are sending mail with results at report@fotonower.com args[1349836124] : ('0.02977487521685605',) no score found for photo 1349836124 We are sending mail with results at report@fotonower.com refus_total : 0.02977487521685605 2022-04-13 10:29:59 0 SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028138 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 1000 start upload file to ovh https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf results_Auto_P22028138_03-04-2025_18_37_05.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf start insert file to database insert into MTRUser.mtr_files (mtd_id,mtr_portfolio_id,text,url,format,tags,file_size,value) values ('4302','22028138','results_Auto_P22028138_03-04-2025_18_37_05.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf','pdf','','0.12','0.02977487521685605') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22028138]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] map_info['map_portfolio_photo'] : {22028138: [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124]} final : False mtd_id 4302 list_pids : [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] Looping around the photos to save general results len do output : 0 before output type Used above Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 8 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', '22028138', '1349836513', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196')] time used for this insertion : 0.012183666229248047 save_final save missing photos in datou_result : time spend for datou_step_exec : 2.4861958026885986 time spend to save output : 0.012482643127441406 total time spend for step 4 : 2.49867844581604 step5:split_time_score Thu Apr 3 18:37:07 2025 VR 17-11-17 : now, only for linear exec dependencies tree, some output goes to fill the input of the next VR 22-3-18 : now we test the dependencies tree, but keep two separate code for datou_prepare_output_input until the code is correctly tested, clean and works in both case VR 22-3-18 : but we use the first code for the first step id = -1, build in the code of datou_exec VR 22-3-18 : we should manage here the case when we are at the first step instead of building this step before datou_exec Currently we do not manage missing dependencies information, that could maybe be correctly interpreted with default behavior Some of the step done at execution of the step could be done before when the tree of execution is build and the dependencies of different step analysed complete output_args for input 0 : ['22028138'] We expect there is only one output and this part is used while all output are not tuple or array Inconsistent number of input and output, step which parrallelize and manage error in input by avoiding sending an output for this data can't be used in tree dependencies of input and output complete output_args for input 1 : VR 22-3-18 : For now we do not clean correctly the datou structure input_args_next_step, len :1, first value : [('22028138',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22028138) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1349836152: {'path': 'temp/1743698225_79118_1349836152_455375d6b2a87757441bbf20089239e2.jpg', 'extension': 'jpg'}, 1349836157: {'path': 'temp/1743698225_79118_1349836157_ebc085136055c1ab8b7bc35f3ff4d272.jpg', 'extension': 'jpg'}, 1349836173: {'path': 'temp/1743698225_79118_1349836173_17397cd7ceeaefe4e1cf46154bdcabfa.jpg', 'extension': 'jpg'}, 1349836513: {'path': 'temp/1743698225_79118_1349836513_f7343b095e6f8ddf3edc35ae8472ce0c.jpg', 'extension': 'jpg'}, 1349836124: {'path': 'temp/1743698225_79118_1349836124_3377f11669a609f9bad153f8fea04d2f.jpg', 'extension': 'jpg'}, 1349836146: {'path': 'temp/1743698225_79118_1349836146_59b96554e65fc0b5b817f0ab0ed62462.jpg', 'extension': 'jpg'}, 1349836163: {'path': 'temp/1743698225_79118_1349836163_8cb8aaf1005f0664ee1c7fbad6026189.jpg', 'extension': 'jpg'}, 1349836169: {'path': 'temp/1743698225_79118_1349836169_a200b2e6b109e9c6ca7c69ca419ed62b.jpg', 'extension': 'jpg'}} map_subphoto_mainphoto : {} begin split time score SELECT app_name, token FROM MTRUser.mtr_app_api_token WHERE mtr_user_id=979 AND app_name="token_split_time_score" AND expire_at > NOW() select distinct dp.name from MTRPhoto.dashboard_entry_day ded, MTRPhoto.dashboard_places dp, MTRPhoto.dashboard_results dr where ded.dashboard_place_id = dp.id and ded.last_run_id = dr.dashboard_run_id and dp.id = ded.dashboard_place_id and dr.mtr_portfolio_id = 22028138; (('arc_en_ciel_jrm',),) TODO : Insert select and so on Begin split_port_in_batch_balle thcls : [{'id': 861, 'mtr_user_id': 31, 'name': 'Rungis_class_dechets_1212', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Rungis_Aluminium,Rungis_Carton,Rungis_Papier,Rungis_Plastique_clair,Rungis_Plastique_dur,Rungis_Plastique_fonce,Rungis_Tapis_vide,Rungis_Tetrapak', 'svm_portfolios_learning': '1160730,571842,571844,571839,571933,571840,571841,572307', 'photo_hashtag_type': 999, 'photo_desc_type': 3963, 'type_classification': 'caffe', 'hashtag_id_list': '2107751280,2107750907,2107750908,2107750909,2107750910,2107750911,2107750912,2107750913'}] thcls : [{'id': 758, 'mtr_user_id': 31, 'name': 'Rungis_amount_dechets_fall_2018_v2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': '05102018_Papier_non_papier_dense,05102018_Papier_non_papier_peu_dense,05102018_Papier_non_papier_presque_vide,05102018_Papier_non_papier_tres_dense,05102018_Papier_non_papier_tres_peu_dense', 'svm_portfolios_learning': '1108385,1108386,1108388,1108384,1108387', 'photo_hashtag_type': 856, 'photo_desc_type': 3853, 'type_classification': 'caffe', 'hashtag_id_list': '2107751013,2107751014,2107751015,2107751016,2107751017'}] select SUBSTRING(ph.text,16,2) as h, count(*) from MTRUser.mtr_portfolio_photos mpp inner join MTRBack.photos ph on mpp.mtr_photo_id = ph.photo_id where mpp.mtr_portfolio_id = 22028138 group by h (('18', 8),) SELECT ph.photo_id,ph.url,ph.username,ph.uploaded_at,ph.text FROM MTRBack.photos ph, MTRUser.mtr_portfolio_photos mpp WHERE ph.photo_id=mpp.mtr_photo_id AND mpp.mtr_portfolio_id=22028138 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 100000 SELECT cps.photo_id, cps.score, h.hashtag, cps.hashtag_id, mpp1.mtr_portfolio_id FROM MTRPhoto.class_photo_score cps, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp1 where mpp1.mtr_photo_id=cps.photo_id AND h.hashtag_id=cps.hashtag_id AND mpp1.hide_status=0 AND mpp1.mtr_portfolio_id in (22028138) AND cps.thcl in (861) order by cps.score desc LIMIT 0, 100000 SELECT cps.photo_id, cps.score, h.hashtag, cps.hashtag_id, mpp1.mtr_portfolio_id FROM MTRPhoto.class_photo_score cps, MTRBack.hashtags h, MTRUser.mtr_portfolio_photos mpp1 where mpp1.mtr_photo_id=cps.photo_id AND h.hashtag_id=cps.hashtag_id AND mpp1.hide_status=0 AND mpp1.mtr_portfolio_id in (22028138) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 03042025 22028138 Nombre de photos uploadées : 8 / 23040 (0%) 03042025 22028138 Nombre de photos taguées (types de déchets): 0 / 8 (0%) 03042025 22028138 Nombre de photos taguées (volume) : 0 / 8 (0%) [{'photo_id': 1349836124, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/3377f11669a609f9bad153f8fea04d2f.jpg', 'username': None, 'uploaded_at': 1743697908, 'text': 'image_03042025_18_30_04_10144.jpg'}, {'photo_id': 1349836173, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/17397cd7ceeaefe4e1cf46154bdcabfa.jpg', 'username': None, 'uploaded_at': 1743697948, 'text': 'image_03042025_18_30_44_10133.jpg'}, {'photo_id': 1349836169, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/a200b2e6b109e9c6ca7c69ca419ed62b.jpg', 'username': None, 'uploaded_at': 1743697948, 'text': 'image_03042025_18_31_04_10139.jpg'}, {'photo_id': 1349836163, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/3/8cb8aaf1005f0664ee1c7fbad6026189.jpg', 'username': None, 'uploaded_at': 1743697948, 'text': 'image_03042025_18_31_14_10136.jpg'}] 0 [] elapsed_time : load_data_split_time_score 2.1457672119140625e-06 elapsed_time : order_list_meta_photo_and_scores 5.4836273193359375e-06 ???????? elapsed_time : fill_and_build_computed_from_old_data 0.0005049705505371094 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 22028138, '2025-04-03' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1712161,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.026021242141723633 We will return after consolidate but for now we need the day, how to get it, for now depending on the previous heavy steps SELECT dri.dashboard_entry_day, dr.dashboard_run_id, dr.mtr_portfolio_id, dr.id, dr.hashtag, dr.completion_json FROM MTRPhoto.dashboard_results dr, MTRPhoto.dashboard_run_ids dri, MTRPhoto.dashboard_entry_day ded WHERE ded.id= 1712161 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1712161, 'dashboard_run_id': 1722174, 'mtr_portfolio_id': 22027156, 'dashboard_result_id': 9851294, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027156_03-04-2025_18_19_02.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027184, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027185, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027186, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027187, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027188, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027189, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027190, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027191, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027192, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027194, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027195, 'pht': 3726}}"}, {'dashboat_entry_day': 1712161, 'dashboard_run_id': 1722174, 'mtr_portfolio_id': 22027723, 'dashboard_result_id': 9851295, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027723_03-04-2025_18_33_01.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027726, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027727, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027729, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027730, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027731, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027732, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027733, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027734, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027735, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027736, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027737, 'pht': 3726}}"}, {'dashboat_entry_day': 1712161, 'dashboard_run_id': 1722174, 'mtr_portfolio_id': 22028138, 'dashboard_result_id': 9851297, 'hashtag': '_______JRM', 'completion_json': "{'max_time_prod_two_photos': 0}"}] SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 22027156 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2721092, 'mtr_portfolio_id': 22027156, 'created_at': datetime.datetime(2025, 4, 3, 18, 19, 1), 'result': '0.05517224166982827', 'result_long': None, 'result_double': None}] Qualite : 0.05517224166982827 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22027156 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027156_03-04-2025_18_19_02.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22027156 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027156_03-04-2025_18_19_02.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027184, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027185, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027186, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027187, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027188, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027189, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027190, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027191, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027192, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027194, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027195, 'pht': 3726}}" where mtr_portfolio_id = 22027156 and dashboard_run_id = 1722174 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22027156 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9851294, 0.05517224166982827, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027156_03-04-2025_18_19_02.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027184, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027185, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027186, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027187, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027188, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027189, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027190, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027191, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027192, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027193, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027194, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027195, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 22027723 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2721140, 'mtr_portfolio_id': 22027723, 'created_at': datetime.datetime(2025, 4, 3, 18, 33, 1), 'result': '0.052984148345078697', 'result_long': None, 'result_double': None}] Qualite : 0.052984148345078697 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22027723 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027723_03-04-2025_18_33_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22027723 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027723_03-04-2025_18_33_01.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027726, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027727, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027729, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027730, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027731, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027732, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027733, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027734, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027735, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027736, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027737, 'pht': 3726}}" where mtr_portfolio_id = 22027723 and dashboard_run_id = 1722174 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22027723 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9851295, 0.052984148345078697, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22027723_03-04-2025_18_33_01.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22027726, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22027727, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22027728, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22027729, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22027730, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22027731, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22027732, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22027733, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22027734, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22027735, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22027736, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22027737, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtd_id, mtr_current_id, mtr_portfolio_id, created_at, result, result_long, result_double FROM MTRPhoto.mtr_datou_result WHERE mtr_portfolio_id = 22028138 AND result is not null and result<>"None" and result<>0.0 AND mtd_id=4302 ORDER BY id desc LIMIT 1 list_result_datou : [{'mtr_datou_id': 4302, 'mtr_datou_current_id': 2721196, 'mtr_portfolio_id': 22028138, 'created_at': datetime.datetime(2025, 4, 3, 18, 37, 5), 'result': '0.02977487521685605', 'result_long': None, 'result_double': None}] Qualite : 0.02977487521685605 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22028138 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22028138 order by id desc limit 1 update MTRPhoto.dashboard_results set completion_json = "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf'}" where mtr_portfolio_id = 22028138 and dashboard_run_id = 1722174 SELECT name, created_at,limit_max FROM MTRDatou.mtr_datou WHERE id=4302 SELECT mtd.id, mtdt.`type`, mtd.`param`, mtd.param_json, mtdt.nb_input, mtdt.nb_output, mtdt.prod, mtdt.is_local, mtdt.is_datou_depend, mtdt.is_photo_id_local FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_step_types mtdt WHERE mtdt.`id`=mtd.`type` AND mtd.mtd_id=4302 SELECT mtd.id, mtd.mtd_id, mdsdt.id, mdsdt.name, mdsdt.description, msid.output_or_input, msid.data_order_id, mdsdt.type FROM MTRDatou.mtr_datou_step mtd, MTRDatou.mtr_datou_steptype_io_datatypes msid, MTRDatou.mtr_datou_step_data_types mdsdt WHERE mtd.`type`=msid.`mtr_datou_step_type` AND mtd.mtd_id= 4302 AND msid.data_type=mdsdt.id SELECT mts_id_output, id_output, mts_id_input, id_input FROM MTRDatou.mtr_datou_step_by_step WHERE mtd_id=4302 # VR 17-11-17 : to create in DB ! Here we check the datou graph and we reorder steps ! Tree builded and cycle checked, now we need to re-order the steps ! We have currenlty an error because there is no dependence between the last step for the case tile - detect - glue We can either keep the depence of, it is better to keep an order compatible with the id of steps if we do not have sons, so a lexical order : (number_son, step_id) All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! All sons are already in current list ! DONE and to test : checkNoCycle ! Here we check the consistency of inputs/outputs number between the given ones and the db ! eke 1-6-18 : checkConsistencyNbInputNbOutput should be processed after step reordering ! WARNING : number of outputs for step 13596 ventilate_hashtags_in_portfolio is not consistent : 2 used against 1 in the step definition ! Step 11881 final have less inputs used (1) than in the step definition (3) : maybe we manage optionnal inputs ! Step 11881 final have less outputs used (1) than in the step definition (2) : some outputs may be not used ! WARNING : number of outputs for step 13625 velours_tree is not consistent : 2 used against 1 in the step definition ! Step 11884 send_mail_cod have less inputs used (3) than in the step definition (5) : maybe we manage optionnal inputs ! Number of inputs / outputs for each step checked ! Here we check the consistency of outputs/inputs types during steps connections eke 1-6-18 : checkConsistencyTypeOutputInput should be processed after checkConsistencyNbInputNbOutput ! We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 3 of step 11884 have datatype=6 WARNING : type of output 1 of step 13596 doesn't seem to be define in the database( WARNING : type of input 3 of step 11881 doesn't seem to be define in the database( We ignore checkConsistencyTypeOutputInput for datou_step final ! WARNING : output 0 of step 13596 have datatype=10 whereas input 0 of step 13625 have datatype=18 WARNING : type of output 1 of step 13625 doesn't seem to be define in the database( WARNING : type of input 5 of step 11884 doesn't seem to be define in the database( DataTypes for each output/input checked ! no param json to modify TODO Duplicate data, are they consistent 3 ? Duplicate data, are they consistent 4 ? SELECT mptpi.id, mptpi.mtr_portfolio_id_1, mptpi.mtr_portfolio_id_2, mptpi.type, mptpi.hashtag_id, mptpi.min_score, mptpi.mtr_user_id, mptpi.created_at, mptpi.updated_at, mptpi.last_updated_at_desc, mptpi.last_updated_at_asc, h.hashtag FROM MTRPhoto.mtr_port_to_port_ids mptpi, MTRBack.hashtags h WHERE h.hashtag_id=mptpi.hashtag_id AND mptpi.`mtr_portfolio_id_1`=22028138 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9851297, 0.02977487521685605, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22028138_03-04-2025_18_37_05.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22028139, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22028140, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22028141, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22028142, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22028143, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22028144, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22028145, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22028146, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22028147, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22028148, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22028149, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22028150, 'pht': 3726}}") ON DUPLICATE KEY UPDATE qualite=VALUES(qualite), completion_json=VALUES(completion_json) ret update_qualite_results : None SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22027156,22027723,22028138) result : ((1349832087,), (1349832145,), (1349832153,), (1349832167,), (1349832188,), (1349832198,), (1349832287,), (1349832345,), (1349832660,), (1349832665,), (1349832669,), (1349832674,), (1349832677,), (1349832685,), (1349832701,), (1349832710,), (1349832717,), (1349832726,), (1349832734,), (1349832737,), (1349832746,), (1349832752,), (1349832760,), (1349832776,), (1349832841,), (1349832845,), (1349832849,), (1349832857,), (1349832893,), (1349832899,), (1349832907,), (1349832924,), (1349832930,), (1349833072,), (1349833091,), (1349833096,), (1349833112,), (1349833161,), (1349833162,), (1349833181,), (1349833182,), (1349833198,), (1349833200,), (1349833201,), (1349833207,), (1349833213,), (1349833219,), (1349833231,), (1349833244,), (1349833267,), (1349833272,), (1349833275,), (1349833280,), (1349833310,), (1349833319,), (1349833325,), (1349833330,), (1349833337,), (1349833576,), (1349833604,), (1349833640,), (1349833687,), (1349833823,), (1349833853,), (1349833882,), (1349833908,), (1349834184,), (1349834090,), (1349834132,), (1349834462,), (1349834476,), (1349834495,), (1349834526,), (1349834869,), (1349834884,), (1349834899,), (1349834905,), (1349834911,), (1349834926,), (1349834931,), (1349834933,), (1349834938,), (1349834940,), (1349834944,), (1349834946,), (1349834952,), (1349834999,), (1349835007,), (1349835036,), (1349835041,), (1349835048,), (1349835052,), (1349835358,), (1349835384,), (1349835398,), (1349835406,), (1349835411,), (1349835427,), (1349835441,), (1349835444,), (1349835451,), (1349835478,), (1349835482,), (1349835486,), (1349835490,), (1349835495,), (1349835582,), (1349835584,), (1349835585,), (1349835588,), (1349835589,), (1349835591,), (1349835593,), (1349835596,), (1349835598,), (1349835608,), (1349835609,), (1349835613,), (1349835796,), (1349835825,), (1349835873,), (1349836085,), (1349836093,), (1349836098,), (1349836129,), (1349836124,), (1349836146,), (1349836152,), (1349836157,), (1349836163,), (1349836169,), (1349836173,), (1349836513,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'03042025': {'nb_upload': 8, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22028138]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] map_info['map_portfolio_photo'] : {22028138: [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124]} final : True mtd_id 4302 list_pids : [1349836513, 1349836173, 1349836169, 1349836163, 1349836157, 1349836152, 1349836146, 1349836124] Looping around the photos to save general results len do output : 1 /22028138Didn't retrieve data . before output type Here is an output not treated by saveGeneral : Managing all output in save final without adding information in the mtr_datou_result ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196') ('4302', None, None, None, None, None, None, None, '2721196') ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 9 insert ignore into MTRPhoto.mtr_datou_result (mtd_id, mtr_portfolio_id,mtr_photo_id,result,result_long,result_double,hashtag_id,proba, mtr_current_id) values (%s,%s,%s,%s,%s,%s,%s,%s,%s) on duplicate key update mtr_portfolio_id = mtr_portfolio_id list_values : [('4302', None, '22028138', 'None', None, None, None, None, '2721196'), ('4302', '22028138', '1349836513', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836173', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836169', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836163', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836157', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836152', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836146', None, None, None, None, None, '2721196'), ('4302', '22028138', '1349836124', None, None, None, None, None, '2721196')] time used for this insertion : 0.013824224472045898 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.3124854564666748 time spend to save output : 0.01410818099975586 total time spend for step 5 : 0.32659363746643066 caffe_path_current : About to save ! 2 After save, about to update current ! ret : 2 len(input) + len(total_photo_id_missing) : 1 set_done_treatment DELETE from MTRPhoto.mtr_datou_current where id in (2721196) 2.20user 2.19system 0:14.00elapsed 31%CPU (0avgtext+0avgdata 160208maxresident)k 256inputs+6168outputs (26major+71871minor)pagefaults 0swaps