insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 22190465 , 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=22190456 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='metal' 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 (22190465) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190466 , 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=22190456 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='papier' 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 (22190466) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190467 , 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=22190456 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 (22190467) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190468 , 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=22190456 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 (22190468) result : ((1351035116,), (1351035117,), (1351035118,), (1351035140,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190469 , 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=22190456 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='plastique' 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 (22190469) result : ((1351035119,), (1351035141,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190470 , 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=22190456 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='mal_croppe' 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 (22190470) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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 22190471 , 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=22190456 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='cartonnette' 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 (22190471) result : ((1351035131,), (1351035132,), (1351035133,), (1351035134,), (1351035135,), (1351035136,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (22190456) result : ((1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) 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`=22190456 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_brun','metal','plastique','papier','Teint_Dans_La_Masse','flou','mal_croppe','autre_refus','kraft','cartonnette','Carton_gris','environnement')) 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`=22190456 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('Carton_brun','metal','plastique','papier','Teint_Dans_La_Masse','flou','mal_croppe','autre_refus','kraft','cartonnette','Carton_gris','environnement')) AND mptpi.`min_score`=0.5 To do returned map {'flou': {'main_port_id': 22190456, 'sub_port_id': 22190472, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665562, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'kraft': {'main_port_id': 22190456, 'sub_port_id': 22190473, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665563, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'Carton_gris': {'main_port_id': 22190456, 'sub_port_id': 22190474, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665564, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'Teint_Dans_La_Masse': {'main_port_id': 22190456, 'sub_port_id': 22190475, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665565, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'autre_refus': {'main_port_id': 22190456, 'sub_port_id': 22190476, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665566, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'metal': {'main_port_id': 22190456, 'sub_port_id': 22190477, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665567, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'papier': {'main_port_id': 22190456, 'sub_port_id': 22190478, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665568, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'environnement': {'main_port_id': 22190456, 'sub_port_id': 22190479, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665569, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'Carton_brun': {'main_port_id': 22190456, 'sub_port_id': 22190480, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665570, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'plastique': {'main_port_id': 22190456, 'sub_port_id': 22190481, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665571, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'mal_croppe': {'main_port_id': 22190456, 'sub_port_id': 22190482, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665572, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}, 'cartonnette': {'main_port_id': 22190456, 'sub_port_id': 22190483, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14665573, 'last_updated_at': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_desc': datetime.datetime(2025, 4, 18, 11, 51), 'last_updated_at_asc': datetime.datetime(2025, 4, 18, 11, 51)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190472,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190460 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190473,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190461 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190474,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190462 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190475,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190463 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190476,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190464 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190477,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190465 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190478,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190466 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190479,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190467 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190480,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190468 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190481,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190469 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190482,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190470 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 22190483,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 22190471 lien utilise dans velours : https://www.fotonower.com/velours/22190472,22190473,22190474,22190475,22190476,22190477,22190478,22190479,22190480,22190481,22190482,22190483?tags=flou,kraft,Carton_gris,Teint_Dans_La_Masse,autre_refus,metal,papier,environnement,Carton_brun,plastique,mal_croppe,cartonnette After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22190456]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] map_info['map_portfolio_photo'] : {22190456: [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723, 1351034641, 1351034637, 1351034632, 1351034628, 1351034589, 1351034586, 1351034581, 1351034550, 1351034518, 1351034154, 1351034135, 1351034116, 1351034089, 1351034064, 1351033851, 1351033748]} final : False mtd_id 4302 list_pids : [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] Looping around the photos to save general results len do output : 1 /22190456. 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, '2736468') ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 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, '22190456', "{'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471}", None, None, None, None, '2736468'), ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468')] time used for this insertion : 0.013888835906982422 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.4936769008636475 time spend to save output : 0.01423788070678711 total time spend for step 1 : 1.5079147815704346 step2:final Fri Apr 18 11:53:00 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 (22190456) 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 22190456 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1351033851,1351033748,1351034154,1351034135,1351034116,1351034089,1351034064,1351034589,1351034586,1351034581,1351034550,1351034518,1351034641,1351034637,1351034632,1351034628,1351034812,1351034796,1351034757,1351034723,1351035089,1351035087,1351035065,1351035049,1351035036,1351034989); 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([22190456]) Inside saveOutput : final : False verbose : True original output for save of step final : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} new output for save of step final : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] map_info['map_portfolio_photo'] : {22190456: [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723, 1351034641, 1351034637, 1351034632, 1351034628, 1351034589, 1351034586, 1351034581, 1351034550, 1351034518, 1351034154, 1351034135, 1351034116, 1351034089, 1351034064, 1351033851, 1351033748]} final : False mtd_id 4302 list_pids : [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] Looping around the photos to save general results len do output : 10 /1351035089.Didn't retrieve data . /1351035087.Didn't retrieve data . /1351035065.Didn't retrieve data . /1351035049.Didn't retrieve data . /1351035036.Didn't retrieve data . /1351034989.Didn't retrieve data . /1351034812.Didn't retrieve data . /1351034796.Didn't retrieve data . /1351034757.Didn't retrieve data . /1351034723.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, '2736468') ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 30 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', '22190456', '1351035089', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351035087', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351035065', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351035049', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351035036', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351034989', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351034812', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351034796', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351034757', '0.10106669478114777', None, None, None, None, '2736468'), ('4302', '22190456', '1351034723', '0.10106669478114777', None, None, None, None, '2736468')] time used for this insertion : 0.016412019729614258 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.06975746154785156 time spend to save output : 0.016953706741333008 total time spend for step 2 : 0.08671116828918457 step3:velours_tree Fri Apr 18 11:53:00 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 : {22190456: [{'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471}]} input_args_next_step : {22190456: ()} output_args : {22190456: [{'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471}]} args : 22190456 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 : ({'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22190456) 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([22190456]) 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.41684889793395996 time spend to save output : 4.673004150390625e-05 total time spend for step 3 : 0.41689562797546387 step4:send_mail_cod Fri Apr 18 11:53:01 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 : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} input_args_next_step : {1351035089: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351035089 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351035087 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351035065 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351035049 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351035036 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351034989 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351034812 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351034796 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351034757 depend.output_id : 0 input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ()} output_args : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',)} args : 1351034723 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 : {22190456: [{'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471}]} input_args_next_step : {1351035089: ('0.10106669478114777',), 1351035087: ('0.10106669478114777',), 1351035065: ('0.10106669478114777',), 1351035049: ('0.10106669478114777',), 1351035036: ('0.10106669478114777',), 1351034989: ('0.10106669478114777',), 1351034812: ('0.10106669478114777',), 1351034796: ('0.10106669478114777',), 1351034757: ('0.10106669478114777',), 1351034723: ('0.10106669478114777',), 22190456: ()} output_args : {22190456: [{'flou': 22190460, 'kraft': 22190461, 'Carton_gris': 22190462, 'Teint_Dans_La_Masse': 22190463, 'autre_refus': 22190464, 'metal': 22190465, 'papier': 22190466, 'environnement': 22190467, 'Carton_brun': 22190468, 'plastique': 22190469, 'mal_croppe': 22190470, 'cartonnette': 22190471}]} args : 22190456 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 :11, first value : ('0.10106669478114777',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22190456) 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 (1351035089,1351035087,1351035065,1351035049,1351035036,1351034989,1351034812,1351034796,1351034757,1351034723) Found this number of photos: 10 ##### Call download_photos : nb_thread : 5 begin to download photo : 1351034723 begin to download photo : 1351034812 begin to download photo : 1351035049 begin to download photo : 1351035089 download finish for photo 1351034723 begin to download photo : 1351034757 download finish for photo 1351035089 download finish for photo 1351035049 begin to download photo : 1351035065 download finish for photo 1351034812 begin to download photo : 1351034989 download finish for photo 1351034757 begin to download photo : 1351034796 download finish for photo 1351034989 begin to download photo : 1351035036 download finish for photo 1351035065 begin to download photo : 1351035087 download finish for photo 1351034796 download finish for photo 1351035087 download finish for photo 1351035036 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette221904601744969981/ length of list_filenames : 10 ; length of list_pids : 10 ; length of list_args : 10 results_Auto_P22190456_18-04-2025_11_53_01.pdf 22190460 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=22190460 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221904601744969981 22190461 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=22190461 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035120: '1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785275_0.png'} change filename to text .imagette221904611744969981/ imagette221904611744969981/1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785275_0.png.png wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/402967348acf1ac2d4cba9e3fc85ab04_4102960.png imagette221904611744969981 22190464 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=22190464 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035111: '1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785149_0.png'} change filename to text .imagette221904641744969981/ imagette221904641744969981/1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785149_0.png.png imagette221904651744969981/ wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/168fc400095592628bba4d36b9f73369_99808651.png imagette221904641744969981 22190465 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=22190465 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221904651744969981 22190469 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=22190469 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035119: '1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785155_0.png', 1351035141: '1744969903_2465243_1351034628_e13a66509a67df19c8e1845dd07b4835_rle_crop_3753790126_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/83ba2e63daf6aba2a72327484f6d0603_91393254.png change filename to text .imagette221904691744969981/ imagette221904691744969981/1744969903_2465243_1351034628_e13a66509a67df19c8e1845dd07b4835_rle_crop_3753790126_0.png.png imagette221904691744969981/1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785155_0.png.png imagette221904701744969981/ wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/4d141502f64b7f6a9bc7c1f1fd15f690_40941240.png imagette221904691744969981 22190470 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=22190470 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221904701744969981 22190471 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=22190471 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035131: '1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789892_0.png', 1351035132: '1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789897_0.png', 1351035133: '1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789895_0.png', 1351035134: '1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789902_0.png', 1351035135: '1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789906_0.png', 1351035136: '1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789903_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/0d324bae8230ff555b5c7faf9897d057_26354302.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/b854a129da03bfb6dddfb2dbeec0b5be_48292024.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/0574f458bc1479d74162430f1e320591_45034236.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/a5439ad416228c1ca6e6ccb4929d00a1_6301500.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/16fb6be309e230a2287ad673d6a8896d_98933669.png change filename to text .imagette221904711744969981/ imagette221904711744969981/1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789897_0.png.png imagette221904711744969981/1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789892_0.png.png imagette221904711744969981/1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789903_0.png.png imagette221904711744969981/1744969903_2465243_1351034637_11399aca237323834745c28061ccb09f_rle_crop_3753789895_0.png.png imagette221904711744969981/1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789906_0.png.png imagette221904711744969981/1744969903_2465243_1351034632_864c77121b8e72982220aabad87644a1_rle_crop_3753789902_0.png.png wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/f1210d8fccce0906788e0602ed33ed9f_98509120.png imagette221904711744969981 22190462 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=22190462 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035112: '1744969871_3969623_1351034116_17948a2df0601a1612a8fa51d3904e02_rle_crop_3753785183_0.png'} change filename to text .imagette221904621744969982/ imagette221904621744969982/1744969871_3969623_1351034116_17948a2df0601a1612a8fa51d3904e02_rle_crop_3753785183_0.png.png imagette221904631744969982/ wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/6fe9acaa364f141f00a8bc678b465373_38130275.png imagette221904621744969982 22190463 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=22190463 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette221904631744969982 22190468 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=22190468 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1351035116: '1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785156_0.png', 1351035117: '1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785276_0.png', 1351035118: '1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785281_0.png', 1351035140: '1744969903_2465243_1351034628_e13a66509a67df19c8e1845dd07b4835_rle_crop_3753790130_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/5cfa72506fd3180fed1f5701213503d6_80475689.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/3de0c4010d9e2c4d3d2641f83237887d_23594916.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/0b24f42800030083178ea6fb35b06599_26884233.png change filename to text .imagette221904681744969982/ imagette221904681744969982/1744969871_3969623_1351034589_330985d9a69afbe894c5254e92d16f4b_rle_crop_3753785156_0.png.png imagette221904681744969982/1744969903_2465243_1351034628_e13a66509a67df19c8e1845dd07b4835_rle_crop_3753790130_0.png.png imagette221904681744969982/1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785276_0.png.png imagette221904681744969982/1744969871_3969623_1351034064_012b760916c99e202ee60154de8eaab3_rle_crop_3753785281_0.png.png wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/2eb0005740698bbf45875d116120a490_80210149.png imagette221904681744969982 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=22190456 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/22190472,22190473,22190474,22190475,22190476,22190477,22190478,22190479,22190480,22190481,22190482,22190483?tags=flou,kraft,Carton_gris,Teint_Dans_La_Masse,autre_refus,metal,papier,environnement,Carton_brun,plastique,mal_croppe,cartonnette your option no_mail is active, we will not send the real mail to your client args[1351035089] : ('0.10106669478114777',) no score found for photo 1351035089 We are sending mail with results at report@fotonower.com args[1351035087] : ('0.10106669478114777',) no score found for photo 1351035087 We are sending mail with results at report@fotonower.com args[1351035065] : ('0.10106669478114777',) no score found for photo 1351035065 We are sending mail with results at report@fotonower.com args[1351035049] : ('0.10106669478114777',) no score found for photo 1351035049 We are sending mail with results at report@fotonower.com args[1351035036] : ('0.10106669478114777',) no score found for photo 1351035036 We are sending mail with results at report@fotonower.com args[1351034989] : ('0.10106669478114777',) no score found for photo 1351034989 We are sending mail with results at report@fotonower.com args[1351034812] : ('0.10106669478114777',) no score found for photo 1351034812 We are sending mail with results at report@fotonower.com args[1351034796] : ('0.10106669478114777',) no score found for photo 1351034796 We are sending mail with results at report@fotonower.com args[1351034757] : ('0.10106669478114777',) no score found for photo 1351034757 We are sending mail with results at report@fotonower.com args[1351034723] : ('0.10106669478114777',) no score found for photo 1351034723 We are sending mail with results at report@fotonower.com refus_total : 0.10106669478114777 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=22190456 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_P22190456_18-04-2025_11_53_01.pdf results_Auto_P22190456_18-04-2025_11_53_01.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22190456_18-04-2025_11_53_01.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','22190456','results_Auto_P22190456_18-04-2025_11_53_01.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22190456_18-04-2025_11_53_01.pdf','pdf','','0.15','0.10106669478114777') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22190456]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] map_info['map_portfolio_photo'] : {22190456: [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723, 1351034641, 1351034637, 1351034632, 1351034628, 1351034589, 1351034586, 1351034581, 1351034550, 1351034518, 1351034154, 1351034135, 1351034116, 1351034089, 1351034064, 1351033851, 1351033748]} final : False mtd_id 4302 list_pids : [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] 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, '2736468') ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 10 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', '22190456', '1351035089', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468')] time used for this insertion : 0.015283823013305664 save_final save missing photos in datou_result : time spend for datou_step_exec : 2.423384189605713 time spend to save output : 0.015491962432861328 total time spend for step 4 : 2.438876152038574 step5:split_time_score Fri Apr 18 11:53:03 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 : ['22190456'] 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 : [('22190456',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (22190456) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1351035089: {'path': 'temp/1744969981_2423170_1351035089_c3087ea2ddb19a843b38bd39da6a77a8.jpg', 'extension': 'jpg'}, 1351034723: {'path': 'temp/1744969981_2423170_1351034723_482878c935b6fbef94e228ba0dd98e62.jpg', 'extension': 'jpg'}, 1351034757: {'path': 'temp/1744969981_2423170_1351034757_0a8f1a9309875b21ad56849122c15a5d.jpg', 'extension': 'jpg'}, 1351034796: {'path': 'temp/1744969981_2423170_1351034796_72a922c2ab258f649e6fd9b341f313e2.jpg', 'extension': 'jpg'}, 1351035049: {'path': 'temp/1744969981_2423170_1351035049_13084ad87930ac565bce754ab2314af4.jpg', 'extension': 'jpg'}, 1351035065: {'path': 'temp/1744969981_2423170_1351035065_c2a90029c195531d1a4ba8dc33190dde.jpg', 'extension': 'jpg'}, 1351035087: {'path': 'temp/1744969981_2423170_1351035087_806089fbf096af89739891bf7d334e23.jpg', 'extension': 'jpg'}, 1351034812: {'path': 'temp/1744969981_2423170_1351034812_09a31781618943021ae465ef445edd6d.jpg', 'extension': 'jpg'}, 1351034989: {'path': 'temp/1744969981_2423170_1351034989_6e5186615cebc29935eb2cd8d3100ad2.jpg', 'extension': 'jpg'}, 1351035036: {'path': 'temp/1744969981_2423170_1351035036_054ec626e8887572c20fad49f984b227.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 = 22190456; (('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 = 22190456 group by h (('11', 26),) 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=22190456 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 (22190456) 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 (22190456) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 18042025 22190456 Nombre de photos uploadées : 26 / 23040 (0%) 18042025 22190456 Nombre de photos taguées (types de déchets): 0 / 26 (0%) 18042025 22190456 Nombre de photos taguées (volume) : 0 / 26 (0%) [{'photo_id': 1351033851, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/e7d4b9bfcabdca63407747c020cb5caa.jpg', 'username': None, 'uploaded_at': 1744969567, 'text': 'image_18042025_11_45_24_10140.jpg'}, {'photo_id': 1351033748, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/bc0c0b6a4c5520dc4d1d6528459fbe6d.jpg', 'username': None, 'uploaded_at': 1744969567, 'text': 'image_18042025_11_45_35_10145.jpg'}, {'photo_id': 1351034154, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/065e240d79ad4dcb6bd7c127386ad1b1.jpg', 'username': None, 'uploaded_at': 1744969627, 'text': 'image_18042025_11_45_45_10140.jpg'}, {'photo_id': 1351034135, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/4/18/671a663fc184d0c00db23f6d534923a4.jpg', 'username': None, 'uploaded_at': 1744969627, 'text': 'image_18042025_11_46_04_10135.jpg 1e-05 for time 1, id_amount 3 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 2.1457672119140625e-06 elapsed_time : order_list_meta_photo_and_scores 7.62939453125e-06 ?????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.0013718605041503906 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 22190456, '2025-04-18' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1725253,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.02985548973083496 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= 1725253 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1725253, 'dashboard_run_id': 1734515, 'mtr_portfolio_id': 22187506, 'dashboard_result_id': 9977540, '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_P22187506_18-04-2025_11_16_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22187573, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22187574, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22187575, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22187576, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22187577, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22187578, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22187579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22187580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22187581, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22187582, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22187583, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22187584, 'pht': 3726}}"}, {'dashboat_entry_day': 1725253, 'dashboard_run_id': 1734515, 'mtr_portfolio_id': 22188563, 'dashboard_result_id': 9977541, '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_P22188563_18-04-2025_11_32_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22188630, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22188631, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22188632, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22188633, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22188634, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22188635, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22188636, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22188637, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22188638, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22188639, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22188640, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22188641, 'pht': 3726}}"}, {'dashboat_entry_day': 1725253, 'dashboard_run_id': 1734515, 'mtr_portfolio_id': 22189239, 'dashboard_result_id': 9977542, '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_P22189239_18-04-2025_11_47_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22189283, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22189284, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22189285, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22189286, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22189287, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22189288, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22189289, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22189290, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22189291, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22189292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22189293, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22189294, 'pht': 3726}}"}, {'dashboat_entry_day': 1725253, 'dashboard_run_id': 1734515, 'mtr_portfolio_id': 22190456, 'dashboard_result_id': 9977543, '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_P22190456_18-04-2025_11_51_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22190460, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22190461, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22190462, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22190463, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22190464, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22190465, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22190466, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22190467, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22190468, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22190469, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22190470, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22190471, 'pht': 3726}}"}] 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 = 22187506 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': 2736156, 'mtr_portfolio_id': 22187506, 'created_at': datetime.datetime(2025, 4, 18, 11, 16, 59), 'result': '0.07272767608181951', 'result_long': None, 'result_double': None}] Qualite : 0.07272767608181951 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22187506 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22187506_18-04-2025_11_16_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22187506 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_P22187506_18-04-2025_11_16_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22187573, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22187574, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22187575, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22187576, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22187577, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22187578, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22187579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22187580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22187581, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22187582, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22187583, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22187584, 'pht': 3726}}" where mtr_portfolio_id = 22187506 and dashboard_run_id = 1734515 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`=22187506 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9977540, 0.07272767608181951, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22187506_18-04-2025_11_16_59.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22187573, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22187574, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22187575, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22187576, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22187577, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22187578, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22187579, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22187580, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22187581, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22187582, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22187583, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22187584, '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 = 22188563 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': 2736330, 'mtr_portfolio_id': 22188563, 'created_at': datetime.datetime(2025, 4, 18, 11, 32, 59), 'result': '0.09224976272455014', 'result_long': None, 'result_double': None}] Qualite : 0.09224976272455014 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22188563 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22188563_18-04-2025_11_32_59.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22188563 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_P22188563_18-04-2025_11_32_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22188630, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22188631, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22188632, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22188633, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22188634, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22188635, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22188636, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22188637, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22188638, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22188639, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22188640, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22188641, 'pht': 3726}}" where mtr_portfolio_id = 22188563 and dashboard_run_id = 1734515 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`=22188563 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9977541, 0.09224976272455014, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22188563_18-04-2025_11_32_59.pdf', 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22188630, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22188631, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22188632, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22188633, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22188634, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22188635, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22188636, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22188637, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22188638, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22188639, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22188640, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22188641, '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 = 22189239 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': 2736395, 'mtr_portfolio_id': 22189239, 'created_at': datetime.datetime(2025, 4, 18, 11, 47), 'result': '0.051488758448127885', 'result_long': None, 'result_double': None}] Qualite : 0.051488758448127885 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22189239 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22189239_18-04-2025_11_47_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22189239 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_P22189239_18-04-2025_11_47_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22189283, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22189284, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22189285, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22189286, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22189287, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22189288, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22189289, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22189290, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22189291, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22189292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22189293, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22189294, 'pht': 3726}}" where mtr_portfolio_id = 22189239 and dashboard_run_id = 1734515 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`=22189239 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9977542, 0.051488758448127885, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22189239_18-04-2025_11_47_01.pdf', 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22189283, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22189284, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22189285, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22189286, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22189287, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22189288, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22189289, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22189290, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22189291, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22189292, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22189293, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 22189294, '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 = 22190456 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': 2736468, 'mtr_portfolio_id': 22190456, 'created_at': datetime.datetime(2025, 4, 18, 11, 53), 'result': '0.10106669478114777', 'result_long': None, 'result_double': None}] Qualite : 0.10106669478114777 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 22190456 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22190456_18-04-2025_11_53_01.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 22190456 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_P22190456_18-04-2025_11_53_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22190460, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22190461, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22190462, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22190463, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22190464, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22190465, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22190466, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22190467, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22190468, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22190469, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22190470, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22190471, 'pht': 3726}}" where mtr_portfolio_id = 22190456 and dashboard_run_id = 1734515 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`=22190456 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9977543, 0.10106669478114777, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P22190456_18-04-2025_11_53_01.pdf', 'flou': {'hashtag': 'flou', 'sub_port_id': 22190460, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 22190461, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 22190462, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 22190463, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 22190464, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 22190465, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 22190466, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 22190467, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 22190468, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 22190469, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 22190470, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 22190471, '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 (22187506,22188563,22189239,22190456) result : ((1351010812,), (1351010841,), (1351010870,), (1351010909,), (1351010956,), (1351011322,), (1351011470,), (1351011605,), (1351011633,), (1351011677,), (1351011711,), (1351012333,), (1351012447,), (1351012562,), (1351013278,), (1351013281,), (1351013289,), (1351013377,), (1351013458,), (1351013998,), (1351014026,), (1351014063,), (1351014093,), (1351014350,), (1351014403,), (1351014430,), (1351014497,), (1351014565,), (1351015171,), (1351015221,), (1351015931,), (1351016007,), (1351016088,), (1351016167,), (1351016266,), (1351016970,), (1351017096,), (1351017188,), (1351017225,), (1351017263,), (1351017279,), (1351017429,), (1351017433,), (1351017435,), (1351017445,), (1351017649,), (1351017650,), (1351017652,), (1351017838,), (1351017886,), (1351017922,), (1351017935,), (1351017942,), (1351017963,), (1351018205,), (1351018234,), (1351018265,), (1351018295,), (1351018324,), (1351018484,), (1351018492,), (1351018521,), (1351018563,), (1351018604,), (1351019084,), (1351019189,), (1351020275,), (1351020104,), (1351020179,), (1351020543,), (1351020658,), (1351020685,), (1351022396,), (1351022420,), (1351022961,), (1351023034,), (1351023482,), (1351023493,), (1351023531,), (1351024067,), (1351024093,), (1351024120,), (1351024148,), (1351024174,), (1351024205,), (1351024641,), (1351024671,), (1351024704,), (1351024734,), (1351024770,), (1351024793,), (1351024915,), (1351024942,), (1351024969,), (1351025332,), (1351025347,), (1351025351,), (1351025353,), (1351025629,), (1351025669,), (1351025698,), (1351025702,), (1351025707,), (1351025895,), (1351025915,), (1351025921,), (1351025923,), (1351026039,), (1351026066,), (1351026093,), (1351026097,), (1351026101,), (1351026306,), (1351026331,), (1351026353,), (1351026357,), (1351026381,), (1351026816,), (1351026604,), (1351026611,), (1351026627,), (1351026633,), (1351026799,), (1351027264,), (1351027291,), (1351027316,), (1351028629,), (1351028679,), (1351029157,), (1351030055,), (1351030077,), (1351030099,), (1351030109,), (1351030141,), (1351030169,), (1351030593,), (1351030643,), (1351030723,), (1351030872,), (1351030884,), (1351030911,), (1351030939,), (1351030969,), (1351031016,), (1351031493,), (1351031539,), (1351031565,), (1351031593,), (1351031622,), (1351031895,), (1351031922,), (1351031924,), (1351031927,), (1351032163,), (1351032191,), (1351032210,), (1351032236,), (1351032258,), (1351032264,), (1351032650,), (1351032659,), (1351032684,), (1351032729,), (1351033210,), (1351033221,), (1351033234,), (1351033368,), (1351033371,), (1351033374,), (1351033379,), (1351033407,), (1351033665,), (1351033668,), (1351033679,), (1351033853,), (1351033748,), (1351033851,), (1351034064,), (1351034089,), (1351034116,), (1351034135,), (1351034154,), (1351034518,), (1351034550,), (1351034581,), (1351034586,), (1351034589,), (1351034628,), (1351034632,), (1351034637,), (1351034641,), (1351034723,), (1351034757,), (1351034796,), (1351034812,), (1351034989,), (1351035036,), (1351035049,), (1351035065,), (1351035087,), (1351035089,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'18042025': {'nb_upload': 26, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([22190456]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] map_info['map_portfolio_photo'] : {22190456: [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723, 1351034641, 1351034637, 1351034632, 1351034628, 1351034589, 1351034586, 1351034581, 1351034550, 1351034518, 1351034154, 1351034135, 1351034116, 1351034089, 1351034064, 1351033851, 1351033748]} final : True mtd_id 4302 list_pids : [1351035089, 1351035087, 1351035065, 1351035049, 1351035036, 1351034989, 1351034812, 1351034796, 1351034757, 1351034723] Looping around the photos to save general results len do output : 1 /22190456Didn'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, '2736468') ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468') ('4302', None, None, None, None, None, None, None, '2736468') ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 11 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, '22190456', 'None', None, None, None, None, '2736468'), ('4302', '22190456', '1351035089', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035087', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035065', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035049', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351035036', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034989', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034812', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034796', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034757', None, None, None, None, None, '2736468'), ('4302', '22190456', '1351034723', None, None, None, None, None, '2736468')] time used for this insertion : 0.013732433319091797 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.35954761505126953 time spend to save output : 0.013932466506958008 total time spend for step 5 : 0.37348008155822754 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 (2736468) 2.05user 2.43system 0:08.01elapsed 55%CPU (0avgtext+0avgdata 159144maxresident)k 27392inputs+7616outputs (102major+63894minor)pagefaults 0swaps