python /home/admin/mtr/script_for_cron.py -j datou_current3 -m 20 -a ' -a 4302 -v ' -s datou_current_4302 -M 0 -S 0 -U 95,95,120 import MySQLdb succeeded Import error (python version) ['/Users/moilerat/Documents/Fotonower/install/caffe/distribute/python', '/home/admin/workarea/git/Velours/python/prod', '/home/admin/workarea/install/caffe_cuda8_python3/python', '/home/admin/workarea/install/darknet', '/home/admin/workarea/git/Velours/python', '/home/admin/workarea/install/caffe_frcnn_python3/py-faster-rcnn/caffe-fast-rcnn/python', '/home/admin/mtr/.credentials', '/home/admin/workarea/install/caffe/python', '/home/admin/workarea/install/caffe_frcnn/py-faster-rcnn/tools', '/home/admin/workarea/git/fotonowerpip', '/home/admin/workarea/install/segment-anything', '/home/admin/workarea/git/pyfvs', '/usr/lib/python38.zip', '/usr/lib/python3.8', '/usr/lib/python3.8/lib-dynload', '/home/admin/.local/lib/python3.8/site-packages', '/usr/local/lib/python3.8/dist-packages', '/usr/lib/python3/dist-packages'] Namespace(auto=False, cert_args='/home/fotonower/https/cert.pem', contextDataFile='', custom_size=0, database='', datou_id='4302', datou_id_excluded='', fifo=False, host='', is_cpu_mode=False, job='batch_current', json_args='', key_args='/home/fotonower/https/vision.fotonower.com.key', limit=1000, list_photo_ids='', local='', mtr_current_id=0, mtr_portfolio_ids='', nb_thread=1, no_current=False, offset=0, only_client=False, output_file='', password='', port=5100, rand=0, save=2, use_client=False, user_id=440, username='', verbose=True) process id : 1434065 load datou : 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 ! Unexpected type seems boolean for variable list_input_json ERROR or WARNING : can't parse json string Expecting value: line 1 column 1 (char 0) Tried to parse : None was removed should we ? donnée sous forme de texte was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? id de la photo (peut être local ou global) was removed should we ? donnée sous forme de texte was removed should we ? donnée sous forme de texte was removed should we ? donnée sous forme de texte was removed should we ? None was removed should we ? donnée sous forme de nombre was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? (photo_id, hashtag_id, score_max) was removed should we ? donnée sous forme de texte was removed should we ? None was removed should we ? donnée sous forme de texte was removed should we ? [ptf_id0,ptf_id1...] was removed should we ? load thcls load pdts Running datou job : batch_current 4302 [] TODO datou_current to load to do maybe to take outside batchDatouExec SELECT * from MTRPhoto.mtr_datou_current where state = 0 AND mtr_portfolio_id is not NULL AND mtd_id = 4302 order by created_at desc LIMIT 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2701529) updating current state to 1 UPDATE MTRPhoto.mtr_datou_current SET state=1, hostname='marlene' WHERE id in (2701529) SELECT count(*) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840944 AND hide_status = 0 list_input_json: [] Current got : datou_id : 4302, datou_cur_ids : ['2701529'] with mtr_portfolio_ids : ['21840944'] and first list_photo_ids : [] new path : /proc/1434065/ Name: python3 Umask: 0002 State: R (running) Tgid: 1434065 Ngid: 0 Pid: 1434065 PPid: 1434064 TracerPid: 0 Uid: 1006 1006 1006 1006 Gid: 1009 1009 1009 1009 FDSize: 64 Groups: 27 1009 1026 NStgid: 1434065 NSpid: 1434065 NSpgid: 1431427 NSsid: 1431427 VmPeak: 1106928 kB VmSize: 1106928 kB VmLck: 0 kB VmPin: 0 kB VmHWM: 98696 kB VmRSS: 98696 kB RssAnon: 59756 kB RssFile: 38940 kB RssShmem: 0 kB VmData: 865676 kB VmStk: 132 kB VmExe: 2644 kB VmLib: 130468 kB VmPTE: 596 kB VmSwap: 0 kB HugetlbPages: 0 kB CoreDumping: 0 THP_enabled: 1 Threads: 1 SigQ: 0/63054 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000001001000 SigCgt: 0000000180000002 CapInh: 0000000000000000 CapPrm: 0000000000000000 CapEff: 0000000000000000 CapBnd: 000001ffffffffff CapAmb: 0000000000000000 NoNewPrivs: 0 Seccomp: 0 Seccomp_filters: 0 Speculation_Store_Bypass: thread vulnerable SpeculationIndirectBranch: conditional enabled Cpus_allowed: ffffffff,ffffffff,ffffffff,ffffffff Cpus_allowed_list: 0-127 Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 Mems_allowed_list: 0 voluntary_ctxt_switches: 52 nonvoluntary_ctxt_switches: 100 {'Name': 'python3', 'Umask': '0002', 'State': 'R (running)', 'Tgid': '1434065', 'Ngid': '0', 'Pid': '1434065', 'PPid': '1434064', 'TracerPid': '0', 'Uid': '1006,1006,1006,1006', 'Gid': '1009,1009,1009,1009', 'FDSize': '64', 'Groups': '27 1009 1026', 'NStgid': '1434065', 'NSpid': '1434065', 'NSpgid': '1431427', 'NSsid': '1431427', 'VmPeak': '1106928 kB', 'VmSize': '1106928 kB', 'VmLck': '0 kB', 'VmPin': '0 kB', 'VmHWM': '98696 kB', 'VmRSS': '98696 kB', 'RssAnon': '59756 kB', 'RssFile': '38940 kB', 'RssShmem': '0 kB', 'VmData': '865676 kB', 'VmStk': '132 kB', 'VmExe': '2644 kB', 'VmLib': '130468 kB', 'VmPTE': '596 kB', 'VmSwap': '0 kB', 'HugetlbPages': '0 kB', 'CoreDumping': '0', 'THP_enabled': '1', 'Threads': '1', 'SigQ': '0/63054', 'SigPnd': '0000000000000000', 'ShdPnd': '0000000000000000', 'SigBlk': '0000000000000000', 'SigIgn': '0000000001001000', 'SigCgt': '0000000180000002', 'CapInh': '0000000000000000', 'CapPrm': '0000000000000000', 'CapEff': '0000000000000000', 'CapBnd': '000001ffffffffff', 'CapAmb': '0000000000000000', 'NoNewPrivs': '0', 'Seccomp': '0', 'Seccomp_filters': '0', 'Speculation_Store_Bypass': 'thread vulnerable', 'SpeculationIndirectBranch': 'conditional enabled', 'Cpus_allowed': 'ffffffff,ffffffff,ffffffff,ffffffff', 'Cpus_allowed_list': '0-127', 'Mems_allowed': '00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001', 'Mems_allowed_list': '0', 'voluntary_ctxt_switches': '52', 'nonvoluntary_ctxt_switches': '100'} ('datou_batch_current', '1434065', '1106928', '0', '1106928', '865676', '98696', b'', 'marlene', '2701529') insert ignore into MTRAdmin.mem_info (script_name, PID, VMpeak,VMswap,VMsize,VMdata,VMrss,GPU_ram, hostname, mtr_current_id) VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,%s) Inside batchDatouExec : verbose : True ##### chargement datou 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 List Step Type Loaded in datou : ventilate_hashtags_in_portfolio, final, velours_tree, send_mail_cod, split_time_score over limit max, limiting to limit_max 200 list_input_json : [] ##### fin chargement datou ##### chargement data ##### Call load_data_input : nb_thread : 1 origin SELECT ph.photo_id, ph.url FROM MTRBack.photos ph WHERE ph.photo_id IN (SELECT mtr_photo_id from MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (21840944) and hide_status = 0 ) AND ph.photo_id not in (SELECT mtr_photo_id from MTRPhoto.mtr_datou_result_search where mtr_current_id in (2701529 ) ) ORDER BY ph.photo_id DESC LIMIT 0, 200 We have 1 , {} SELECT mtr_photo_id, mtr_portfolio_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id in (21840944) AND hide_status = 0 ORDER by mtr_photo_id desc LIMIT 0, 200 list_result: [{'photo_id': 1348237132, 'portfolio_id': 21840944}, {'photo_id': 1348237120, 'portfolio_id': 21840944}, {'photo_id': 1348237046, 'portfolio_id': 21840944}, {'photo_id': 1348237021, 'portfolio_id': 21840944}, {'photo_id': 1348236995, 'portfolio_id': 21840944}, {'photo_id': 1348236704, 'portfolio_id': 21840944}, {'photo_id': 1348236701, 'portfolio_id': 21840944}, {'photo_id': 1348236575, 'portfolio_id': 21840944}, {'photo_id': 1348236544, 'portfolio_id': 21840944}, {'photo_id': 1348236538, 'portfolio_id': 21840944}, {'photo_id': 1348236475, 'portfolio_id': 21840944}, {'photo_id': 1348236468, 'portfolio_id': 21840944}, {'photo_id': 1348236463, 'portfolio_id': 21840944}, {'photo_id': 1348236457, 'portfolio_id': 21840944}, {'photo_id': 1348236453, 'portfolio_id': 21840944}, {'photo_id': 1348236399, 'portfolio_id': 21840944}, {'photo_id': 1348236387, 'portfolio_id': 21840944}, {'photo_id': 1348236277, 'portfolio_id': 21840944}, {'photo_id': 1348236266, 'portfolio_id': 21840944}, {'photo_id': 1348236257, 'portfolio_id': 21840944}, {'photo_id': 1348236216, 'portfolio_id': 21840944}, {'photo_id': 1348236206, 'portfolio_id': 21840944}, {'photo_id': 1348236176, 'portfolio_id': 21840944}, {'photo_id': 1348236172, 'portfolio_id': 21840944}, {'photo_id': 1348236162, 'portfolio_id': 21840944}, {'photo_id': 1348236158, 'portfolio_id': 21840944}, {'photo_id': 1348236154, 'portfolio_id': 21840944}, {'photo_id': 1348236149, 'portfolio_id': 21840944}, {'photo_id': 1348236034, 'portfolio_id': 21840944}, {'photo_id': 1348236023, 'portfolio_id': 21840944}, {'photo_id': 1348236019, 'portfolio_id': 21840944}] map_portfolio_id_photo_id: {21840944: [1348237132, 1348237120, 1348237046, 1348237021, 1348236995, 1348236704, 1348236701, 1348236575, 1348236544, 1348236538, 1348236475, 1348236468, 1348236463, 1348236457, 1348236453, 1348236399, 1348236387, 1348236277, 1348236266, 1348236257, 1348236216, 1348236206, 1348236176, 1348236172, 1348236162, 1348236158, 1348236154, 1348236149, 1348236034, 1348236023, 1348236019]} ##### Call download_photos : nb_thread : 1 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos ##### After load_data_input time to download the photos : 0.015066385269165039 #### fin chargement data Blocking on flush ? No conitnuing About to test input to load Calling datou_exec Inside datou_exec : verbose : True number of steps : 5 step1:ventilate_hashtags_in_portfolio Fri Mar 28 11:42:58 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 After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (21840944) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {} map_subphoto_mainphoto : {} beginning of datou step ventilate_hashtags_in_portfolio : To implement ! To do loadFromThcl(), then load ParamDescType : thcl2725 get_desc_type_from_thcl : type of cat SELECT id, mtr_user_id, name, pb_hashtag_id, hashtag_id_list, button_legend_list, portfolio_id_lists, photo_hashtag_type, photo_desc_type, svm_limit, limit_tagging, is_public, live, created_at, updated_at, type_classification FROM MTRDatou.classification_theme WHERE `id` IN (2725) thcls : [{'id': 2725, 'mtr_user_id': 31, 'name': 'learn_qualipapia_rle_210302_2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Carton_brun,Carton_gris,Teint_Dans_La_Masse,autre_refus,cartonnette,environnement,kraft,metal,papier,plastique', 'svm_portfolios_learning': '3460440,3460441,3460446,3460434,3460439,3467416,3460442,3460443,3486028,3460445', 'photo_hashtag_type': 3410, 'photo_desc_type': 5186, 'type_classification': 'caffe', 'hashtag_id_list': '2107753024,2107753020,2107752385,2107752406,702398920,493012381,493202403,492628673,492668766,492725882'}] thcl {'id': 2725, 'mtr_user_id': 31, 'name': 'learn_qualipapia_rle_210302_2', 'pb_hashtag_id': 0, 'live': b'\x00', 'list_hashtags': 'Carton_brun,Carton_gris,Teint_Dans_La_Masse,autre_refus,cartonnette,environnement,kraft,metal,papier,plastique', 'svm_portfolios_learning': '3460440,3460441,3460446,3460434,3460439,3467416,3460442,3460443,3486028,3460445', 'photo_hashtag_type': 3410, 'photo_desc_type': 5186, 'type_classification': 'caffe', 'hashtag_id_list': '2107753024,2107753020,2107752385,2107752406,702398920,493012381,493202403,492628673,492668766,492725882'} Update svm_hashtag_type_desc : 5186 remove imagettes from duplicated photo Iterating over portfolio : 21840944 get user id for portfolio 21840944 get sub ptf for main ptf 21840944, type 3726 and hashtags ['kraft', 'metal', 'cartonnette', 'Carton_brun', 'Teint_Dans_La_Masse', 'mal_croppe', 'autre_refus', 'plastique', 'flou', 'environnement', 'papier', 'Carton_gris'] 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`=21840944 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('kraft','metal','cartonnette','Carton_brun','Teint_Dans_La_Masse','mal_croppe','autre_refus','plastique','flou','environnement','papier','Carton_gris')) 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`=21840944 AND mptpi.`type`=3726 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('kraft','metal','cartonnette','Carton_brun','Teint_Dans_La_Masse','mal_croppe','autre_refus','plastique','flou','environnement','papier','Carton_gris')) AND mptpi.`min_score`=0.5 To do returned map {'environnement': {'main_port_id': 21840944, 'sub_port_id': 21840945, 'hashtag': 'environnement', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356383, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'Carton_brun': {'main_port_id': 21840944, 'sub_port_id': 21840946, 'hashtag': 'Carton_brun', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356384, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'Teint_Dans_La_Masse': {'main_port_id': 21840944, 'sub_port_id': 21840947, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356385, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'kraft': {'main_port_id': 21840944, 'sub_port_id': 21840948, 'hashtag': 'kraft', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356386, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'autre_refus': {'main_port_id': 21840944, 'sub_port_id': 21840949, 'hashtag': 'autre_refus', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356387, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'papier': {'main_port_id': 21840944, 'sub_port_id': 21840950, 'hashtag': 'papier', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356388, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'flou': {'main_port_id': 21840944, 'sub_port_id': 21840951, 'hashtag': 'flou', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356389, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'mal_croppe': {'main_port_id': 21840944, 'sub_port_id': 21840952, 'hashtag': 'mal_croppe', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356390, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'metal': {'main_port_id': 21840944, 'sub_port_id': 21840953, 'hashtag': 'metal', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356391, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'cartonnette': {'main_port_id': 21840944, 'sub_port_id': 21840954, 'hashtag': 'cartonnette', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356392, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'plastique': {'main_port_id': 21840944, 'sub_port_id': 21840955, 'hashtag': 'plastique', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356393, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}, 'Carton_gris': {'main_port_id': 21840944, 'sub_port_id': 21840956, 'hashtag': 'Carton_gris', 'pht': 3726, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356394, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 36, 58)}} insert ignore into MTRUser.mtr_portfolio_photos (mtr_portfolio_id, mtr_photo_id, mtr_user_id,created_at) SELECT 21840945 , 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=21840944 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 (21840945) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840946 , 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=21840944 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 (21840946) result : ((1348236317,), (1348237403,), (1348237405,), (1348237433,), (1348237434,), (1348237435,), (1348237436,), (1348237437,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840947 , 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=21840944 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Teint_Dans_La_Masse' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840947) result : ((1348236789,), (1348237368,), (1348237369,), (1348237370,), (1348237371,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840948 , 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=21840944 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='kraft' 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 (21840948) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840949 , 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=21840944 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='autre_refus' 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 (21840949) result : ((1348236792,), (1348237422,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840950 , 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=21840944 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 (21840950) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840951 , 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=21840944 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='flou' 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 (21840951) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840952 , 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=21840944 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 (21840952) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840953 , 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=21840944 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 (21840953) result : () SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840954 , 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=21840944 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 (21840954) result : ((1348236315,), (1348236316,), (1348236805,), (1348237394,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840955 , 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=21840944 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 (21840955) result : ((1348236815,), (1348236816,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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 21840956 , 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=21840944 AND mpp.mtr_photo_id=chi.photo_id AND chi.id=csp.crop_hashtag_id AND chi.score>0.5 AND chi.type=3726 AND chi.hashtag_id=h.hashtag_id AND h.hashtag='Carton_gris' GROUP BY csp.crop_hashtag_id, csp.created_at order by csp.created_at desc) as a group by crop_hashtag_id; SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840956) result : ((1348236312,), (1348236799,), (1348236800,), (1348236801,), (1348236803,), (1348237382,)) SELECT mtr_photo_id FROM MTRUser.mtr_portfolio_photos WHERE mtr_portfolio_id IN (21840944) result : ((1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) 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`=21840944 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('kraft','metal','cartonnette','Carton_brun','Teint_Dans_La_Masse','mal_croppe','autre_refus','plastique','flou','environnement','papier','Carton_gris')) 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`=21840944 AND mptpi.`type`=4417 AND mptpi.`hashtag_id` in (select hashtag_id FROM MTRBack.hashtags where hashtag in ('kraft','metal','cartonnette','Carton_brun','Teint_Dans_La_Masse','mal_croppe','autre_refus','plastique','flou','environnement','papier','Carton_gris')) AND mptpi.`min_score`=0.5 To do returned map {'environnement': {'main_port_id': 21840944, 'sub_port_id': 21840957, 'hashtag': 'environnement', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356395, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'Carton_brun': {'main_port_id': 21840944, 'sub_port_id': 21840958, 'hashtag': 'Carton_brun', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356396, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'Teint_Dans_La_Masse': {'main_port_id': 21840944, 'sub_port_id': 21840959, 'hashtag': 'Teint_Dans_La_Masse', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356397, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'kraft': {'main_port_id': 21840944, 'sub_port_id': 21840960, 'hashtag': 'kraft', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356398, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'autre_refus': {'main_port_id': 21840944, 'sub_port_id': 21840961, 'hashtag': 'autre_refus', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356399, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'papier': {'main_port_id': 21840944, 'sub_port_id': 21840962, 'hashtag': 'papier', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356400, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'flou': {'main_port_id': 21840944, 'sub_port_id': 21840963, 'hashtag': 'flou', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356401, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'mal_croppe': {'main_port_id': 21840944, 'sub_port_id': 21840964, 'hashtag': 'mal_croppe', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356402, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'metal': {'main_port_id': 21840944, 'sub_port_id': 21840965, 'hashtag': 'metal', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356403, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'cartonnette': {'main_port_id': 21840944, 'sub_port_id': 21840966, 'hashtag': 'cartonnette', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356404, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'plastique': {'main_port_id': 21840944, 'sub_port_id': 21840967, 'hashtag': 'plastique', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356405, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 37), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}, 'Carton_gris': {'main_port_id': 21840944, 'sub_port_id': 21840968, 'hashtag': 'Carton_gris', 'pht': 4417, 'min_score': 0.5, 'mtr_user_id': 979, 'id': 14356406, 'last_updated_at': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_desc': datetime.datetime(2025, 3, 28, 11, 39, 57), 'last_updated_at_asc': datetime.datetime(2025, 3, 28, 11, 37)}} insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840957,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840945 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840958,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840946 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840959,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840947 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840960,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840948 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840961,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840949 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840962,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840950 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840963,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840951 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840964,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840952 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840965,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840953 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840966,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840954 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840967,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840955 insert ignore into MTRUser.mtr_portfolio_photos(mtr_portfolio_id,mtr_photo_id,mtr_user_id) select 21840968,mtr_photo_id,mtr_user_id from MTRUser.mtr_portfolio_photos where mtr_portfolio_id = 21840956 lien utilise dans velours : https://www.fotonower.com/velours/21840957,21840958,21840959,21840960,21840961,21840962,21840963,21840964,21840965,21840966,21840967,21840968?tags=environnement,Carton_brun,Teint_Dans_La_Masse,kraft,autre_refus,papier,flou,mal_croppe,metal,cartonnette,plastique,Carton_gris After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([21840944]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : ventilate_hashtags_in_portfolio we use saveGeneral [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] map_info['map_portfolio_photo'] : {21840944: [1348237132, 1348237120, 1348237046, 1348237021, 1348236995, 1348236704, 1348236701, 1348236575, 1348236544, 1348236538, 1348236475, 1348236468, 1348236463, 1348236457, 1348236453, 1348236399, 1348236387, 1348236277, 1348236266, 1348236257, 1348236216, 1348236206, 1348236176, 1348236172, 1348236162, 1348236158, 1348236154, 1348236149, 1348236034, 1348236023, 1348236019]} final : False mtd_id 4302 list_pids : [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] Looping around the photos to save general results len do output : 1 /21840944. 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, '2701529') ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 6 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, '21840944', "{'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956}", None, None, None, None, '2701529'), ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529')] time used for this insertion : 0.013134956359863281 save_final save missing photos in datou_result : time spend for datou_step_exec : 1.460603952407837 time spend to save output : 0.01339268684387207 total time spend for step 1 : 1.473996639251709 step2:final Fri Mar 28 11:42:59 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 (21840944) 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 21840944 : SELECT photo_id, hashtag_id, ratio from MTRPhoto.photo_carac_ratio where hashtag_type = 3726 and photo_id in (1348236034,1348236023,1348236019,1348236176,1348236172,1348236162,1348236158,1348236154,1348236149,1348236277,1348236266,1348236206,1348236257,1348236216,1348236399,1348236387,1348236475,1348236468,1348236463,1348236457,1348236453,1348236575,1348236544,1348236538,1348236704,1348236701,1348237046,1348237021,1348236995,1348237132,1348237120); 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([21840944]) Inside saveOutput : final : False verbose : True original output for save of step final : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} new output for save of step final : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] map_info['map_portfolio_photo'] : {21840944: [1348237132, 1348237120, 1348237046, 1348237021, 1348236995, 1348236704, 1348236701, 1348236575, 1348236544, 1348236538, 1348236475, 1348236468, 1348236463, 1348236457, 1348236453, 1348236399, 1348236387, 1348236277, 1348236266, 1348236257, 1348236216, 1348236206, 1348236176, 1348236172, 1348236162, 1348236158, 1348236154, 1348236149, 1348236034, 1348236023, 1348236019]} final : False mtd_id 4302 list_pids : [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] Looping around the photos to save general results len do output : 5 /1348237132.Didn't retrieve data . /1348237120.Didn't retrieve data . /1348237046.Didn't retrieve data . /1348237021.Didn't retrieve data . /1348236995.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, '2701529') ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 15 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', '21840944', '1348237132', '0.03237440676718019', None, None, None, None, '2701529'), ('4302', '21840944', '1348237120', '0.03237440676718019', None, None, None, None, '2701529'), ('4302', '21840944', '1348237046', '0.03237440676718019', None, None, None, None, '2701529'), ('4302', '21840944', '1348237021', '0.03237440676718019', None, None, None, None, '2701529'), ('4302', '21840944', '1348236995', '0.03237440676718019', None, None, None, None, '2701529')] time used for this insertion : 0.014797449111938477 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.0665440559387207 time spend to save output : 0.015215158462524414 total time spend for step 2 : 0.08175921440124512 step3:velours_tree Fri Mar 28 11:42:59 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 : {21840944: [{'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956}]} input_args_next_step : {21840944: ()} output_args : {21840944: [{'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956}]} args : 21840944 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 : ({'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956},) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (21840944) 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([21840944]) 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.34641075134277344 time spend to save output : 5.507469177246094e-05 total time spend for step 3 : 0.3464658260345459 step4:send_mail_cod Fri Mar 28 11:42:59 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 : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} input_args_next_step : {1348237132: ()} output_args : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} args : 1348237132 depend.output_id : 0 input_args_next_step : {1348237132: ('0.03237440676718019',), 1348237120: ()} output_args : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} args : 1348237120 depend.output_id : 0 input_args_next_step : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ()} output_args : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} args : 1348237046 depend.output_id : 0 input_args_next_step : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ()} output_args : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} args : 1348237021 depend.output_id : 0 input_args_next_step : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ()} output_args : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',)} args : 1348236995 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 : {21840944: [{'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956}]} input_args_next_step : {1348237132: ('0.03237440676718019',), 1348237120: ('0.03237440676718019',), 1348237046: ('0.03237440676718019',), 1348237021: ('0.03237440676718019',), 1348236995: ('0.03237440676718019',), 21840944: ()} output_args : {21840944: [{'environnement': 21840945, 'Carton_brun': 21840946, 'Teint_Dans_La_Masse': 21840947, 'kraft': 21840948, 'autre_refus': 21840949, 'papier': 21840950, 'flou': 21840951, 'mal_croppe': 21840952, 'metal': 21840953, 'cartonnette': 21840954, 'plastique': 21840955, 'Carton_gris': 21840956}]} args : 21840944 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 :6, first value : ('0.03237440676718019',) After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (21840944) 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 (1348237132,1348237120,1348237046,1348237021,1348236995) Found this number of photos: 5 ##### Call download_photos : nb_thread : 5 begin to download photo : 1348236995 begin to download photo : 1348237046 begin to download photo : 1348237132 download finish for photo 1348237046 begin to download photo : 1348237120 download finish for photo 1348237132 download finish for photo 1348236995 begin to download photo : 1348237021 download finish for photo 1348237120 download finish for photo 1348237021 we have missing 0 photos in the step downloads : photo missing : [] try to delete the photos missing in DB ##### After download_photos imagette218409481743158580/ length of list_filenames : 5 ; length of list_pids : 5 ; length of list_args : 5 results_Auto_P21840944_28-03-2025_11_43_00.pdf 21840948 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=21840948 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette218409481743158580 21840949 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=21840949 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236792: '1743158273_1044907_1348236154_da35211b10b2dd6cd144926554794041_rle_crop_3736088536_0.png', 1348237422: '1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093048_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/0ce87394bb082872a28a61ffdd3cf5c9_31815281.png change filename to text .imagette218409491743158580/ imagette218409491743158580/1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093048_0.png.png imagette218409491743158580/1743158273_1044907_1348236154_da35211b10b2dd6cd144926554794041_rle_crop_3736088536_0.png.png imagette218409511743158580/ imagette218409521743158580/ imagette218409531743158580/ wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/657e0f8fa1f60293b0706d42652002f2_59295126.png imagette218409491743158580 21840951 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=21840951 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette218409511743158580 21840952 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=21840952 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette218409521743158580 21840953 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=21840953 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {} imagette218409531743158580 21840954 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=21840954 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236315: '1743158067_1371842_1348236023_be4518e7c8928bda7f0b0a973dcd2134_rle_crop_3736084534_0.png', 1348236316: '1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084550_0.png', 1348236805: '1743158306_1377461_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088502_0.png', 1348237394: '1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088909_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/78dfccd5c9a314d5f5d484a65a9e7045_35319206.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/3e5bd5c0cb3c319c9571d275be78c1fc_11076562.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/52b3dc799c9c1816473b275891d304a6_52762894.png change filename to text .imagette218409541743158580/ imagette218409541743158580/1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088909_0.png.png imagette218409541743158580/1743158067_1371842_1348236023_be4518e7c8928bda7f0b0a973dcd2134_rle_crop_3736084534_0.png.png imagette218409541743158580/1743158306_1377461_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088502_0.png.png imagette218409541743158580/1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084550_0.png.png wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/dc30477169d82015afe283378978aabe_38983582.png imagette218409541743158580 21840955 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=21840955 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236815: '1743158273_1044907_1348236172_12aac54f9d6e1f221b328b820693c71a_rle_crop_3736088456_0.png', 1348236816: '1743158273_1044907_1348236172_12aac54f9d6e1f221b328b820693c71a_rle_crop_3736088458_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/6a4db4e48809a655b98b0eb2f43b2b90_20280256.png change filename to text .imagette218409551743158580/ imagette218409551743158580/1743158273_1044907_1348236172_12aac54f9d6e1f221b328b820693c71a_rle_crop_3736088458_0.png.png imagette218409551743158580/1743158273_1044907_1348236172_12aac54f9d6e1f221b328b820693c71a_rle_crop_3736088456_0.png.png wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/89fc86b22bce0c1799d572e1ead2c851_61039323.png imagette218409551743158580 21840946 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=21840946 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236317: '1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084552_0.png', 1348237403: '1743158472_1050084_1348236453_06d60f6bffbfc21ddd4a98b8c9677b61_rle_crop_3736089714_0.png', 1348237405: '1743158472_1050084_1348236453_06d60f6bffbfc21ddd4a98b8c9677b61_rle_crop_3736089712_0.png', 1348237433: '1743158492_1050267_1348236704_f48df4157e57a4ed61799796aee32736_rle_crop_3736093041_0.png', 1348237434: '1743158492_1050267_1348236704_f48df4157e57a4ed61799796aee32736_rle_crop_3736093035_0.png', 1348237435: '1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093051_0.png', 1348237436: '1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093049_0.png', 1348237437: '1743158492_1050267_1348236538_08833307b0341a9c399f8dec96b16a75_rle_crop_3736093065_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/b75acc2dd8411ec86d106f6cf51f4328_88828264.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/ac183533d7feb7e6fb6a2512e67990c7_12173356.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/980eba1581c7a2a265dad9b1f4b9151d_45535957.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/18a3dd48adb1f5ca96d5c69118ae8587_99164475.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/c63066f0e5b08fd6fa5b7f605ebc06aa_17111924.png change filename to text .wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/5b4fa30de006db6ff489b9aac682c3c9_36340538.png change filename to text .wget -O 7.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/fcf7abf56b887ca745a3242f3a32f85e_26599772.png change filename to text .imagette218409461743158580/ imagette218409461743158580/1743158492_1050267_1348236704_f48df4157e57a4ed61799796aee32736_rle_crop_3736093035_0.png.png imagette218409461743158580/1743158472_1050084_1348236453_06d60f6bffbfc21ddd4a98b8c9677b61_rle_crop_3736089714_0.png.png imagette218409461743158580/1743158492_1050267_1348236538_08833307b0341a9c399f8dec96b16a75_rle_crop_3736093065_0.png.png imagette218409461743158580/1743158492_1050267_1348236704_f48df4157e57a4ed61799796aee32736_rle_crop_3736093041_0.png.png imagette218409461743158580/1743158472_1050084_1348236453_06d60f6bffbfc21ddd4a98b8c9677b61_rle_crop_3736089712_0.png.png imagette218409461743158580/1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093049_0.png.png imagette218409461743158580/1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084552_0.png.png imagette218409461743158580/1743158492_1050267_1348236544_0e09d078f6d866ee80501e2c59cb1f80_rle_crop_3736093051_0.png.png wget -O 8.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/fba7cd7cc5ee062125d5bab7cc74c56c_85032837.png imagette218409461743158580 21840947 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=21840947 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236789: '1743158273_1044907_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088505_0.png', 1348237368: '1743158472_1050084_1348236575_2f3bd733bc0d451aaefcc0cbc2d2a977_rle_crop_3736091918_0.png', 1348237369: '1743158472_1050084_1348236468_6504190244b6e06b9d87a2054f6cd5be_rle_crop_3736088893_0.png', 1348237370: '1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088918_0.png', 1348237371: '1743158472_1050084_1348236457_a474b61e1d8001f64f59313eb1aac944_rle_crop_3736089676_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/45b7ba3a6714a10bf5d5e02ece2b2cb6_95684130.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/e033129c5d562ba8e21151e57544ec08_5997059.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/e02cca417e90456dffc13a1da2309cf4_30460938.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/4ca6f63e25bcdd6f0acf4c73970deacb_32958039.png change filename to text .imagette218409471743158581/ imagette218409471743158581/1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088918_0.png.png imagette218409471743158581/1743158472_1050084_1348236575_2f3bd733bc0d451aaefcc0cbc2d2a977_rle_crop_3736091918_0.png.png imagette218409471743158581/1743158472_1050084_1348236457_a474b61e1d8001f64f59313eb1aac944_rle_crop_3736089676_0.png.png imagette218409471743158581/1743158273_1044907_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088505_0.png.png imagette218409471743158581/1743158472_1050084_1348236468_6504190244b6e06b9d87a2054f6cd5be_rle_crop_3736088893_0.png.png wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/4d7c4c7767463f26c8cbd125f14c4b6e_39021774.png imagette218409471743158581 21840956 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=21840956 AND mpp.hide_status=0 ORDER BY mpp.order LIMIT 0, 20 map_photo_id_text : {1348236312: '1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084554_0.png', 1348236799: '1743158273_1044907_1348236162_8f54522866af764083007af211933a98_rle_crop_3736088481_0.png', 1348236800: '1743158273_1044907_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088506_0.png', 1348236801: '1743158273_1044907_1348236154_da35211b10b2dd6cd144926554794041_rle_crop_3736088537_0.png', 1348236803: '1743158273_1044907_1348236149_0175e9c28166ebb0d639532eb5398448_rle_crop_3736088600_0.png', 1348237382: '1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088919_0.png'} change filename to text .wget -O 1.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/ea60c88eae9f4d8a33cfc77d4a40f22b_39409197.png change filename to text .wget -O 2.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/cf5d52389f9f215b5b83d516e993b88c_4525651.png change filename to text .wget -O 3.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/d6ee1c3c6f0509a74c0e6918e7609f9e_55295845.png change filename to text .wget -O 4.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/ca049f81c938348d9c83b48b3d2d1c08_8743565.png change filename to text .wget -O 5.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/dcd71aad3cddb6695bf7cff850966ff6_98768488.png change filename to text .imagette218409561743158581/ imagette218409561743158581/1743158067_1371842_1348236019_a49edc7d3929ccb9de6e2efa4d8e9606_rle_crop_3736084554_0.png.png imagette218409561743158581/1743158273_1044907_1348236162_8f54522866af764083007af211933a98_rle_crop_3736088481_0.png.png imagette218409561743158581/1743158472_1050084_1348236463_c25a2950e71ce525dfecd5406883c7de_rle_crop_3736088919_0.png.png imagette218409561743158581/1743158273_1044907_1348236149_0175e9c28166ebb0d639532eb5398448_rle_crop_3736088600_0.png.png imagette218409561743158581/1743158273_1044907_1348236154_da35211b10b2dd6cd144926554794041_rle_crop_3736088537_0.png.png imagette218409561743158581/1743158273_1044907_1348236158_e09dca4231f1315c065f238a5d8a3ec7_rle_crop_3736088506_0.png.png wget -O 6.png http://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/a37e5f947281fa2b9bbf588523680c3c_9963289.png imagette218409561743158581 SELECT h.hashtag,pcr.value FROM MTRUser.portfolio_carac_ratio pcr, MTRBack.hashtags h where pcr.portfolio_id=21840944 and hashtag_type = 3726 and pcr.hashtag_id = h.hashtag_id; velour_link : https://www.fotonower.com/velours/21840957,21840958,21840959,21840960,21840961,21840962,21840963,21840964,21840965,21840966,21840967,21840968?tags=environnement,Carton_brun,Teint_Dans_La_Masse,kraft,autre_refus,papier,flou,mal_croppe,metal,cartonnette,plastique,Carton_gris your option no_mail is active, we will not send the real mail to your client args[1348237132] : ('0.03237440676718019',) no score found for photo 1348237132 We are sending mail with results at report@fotonower.com args[1348237120] : ('0.03237440676718019',) no score found for photo 1348237120 We are sending mail with results at report@fotonower.com args[1348237046] : ('0.03237440676718019',) no score found for photo 1348237046 We are sending mail with results at report@fotonower.com args[1348237021] : ('0.03237440676718019',) no score found for photo 1348237021 We are sending mail with results at report@fotonower.com args[1348236995] : ('0.03237440676718019',) no score found for photo 1348236995 We are sending mail with results at report@fotonower.com refus_total : 0.03237440676718019 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=21840944 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_P21840944_28-03-2025_11_43_00.pdf results_Auto_P21840944_28-03-2025_11_43_00.pdf uploaded to url https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840944_28-03-2025_11_43_00.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','21840944','results_Auto_P21840944_28-03-2025_11_43_00.pdf','https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840944_28-03-2025_11_43_00.pdf','pdf','','0.14','0.03237440676718019') After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([21840944]) Inside saveOutput : final : False verbose : True saveOutput not yet implemented for datou_step.type : send_mail_cod we use saveGeneral [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] map_info['map_portfolio_photo'] : {21840944: [1348237132, 1348237120, 1348237046, 1348237021, 1348236995, 1348236704, 1348236701, 1348236575, 1348236544, 1348236538, 1348236475, 1348236468, 1348236463, 1348236457, 1348236453, 1348236399, 1348236387, 1348236277, 1348236266, 1348236257, 1348236216, 1348236206, 1348236176, 1348236172, 1348236162, 1348236158, 1348236154, 1348236149, 1348236034, 1348236023, 1348236019]} final : False mtd_id 4302 list_pids : [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] 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, '2701529') ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 5 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', '21840944', '1348237132', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529')] time used for this insertion : 0.012414932250976562 save_final save missing photos in datou_result : time spend for datou_step_exec : 3.13849139213562 time spend to save output : 0.012590646743774414 total time spend for step 4 : 3.1510820388793945 step5:split_time_score Fri Mar 28 11:43: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 : ['21840944'] 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 : [('21840944',)] After prepare type args : select max(UNIX_TIMESTAMP(created_at)) from MTRUser.mtr_portfolio_photos where mtr_portfolio_id in (21840944) Here we display some param of map_info ! map_filenames : {} map_photo_id_path_extension : {1348237132: {'path': 'temp/1743158579_1434065_1348237132_98167adb5204ad465279c3ef95c2925e.jpg', 'extension': 'jpg'}, 1348237046: {'path': 'temp/1743158579_1434065_1348237046_f4a8844d0f866de0ead80bbd252aa43e.jpg', 'extension': 'jpg'}, 1348237120: {'path': 'temp/1743158579_1434065_1348237120_cee997f77f6fa862339b7788d3aa0d28.jpg', 'extension': 'jpg'}, 1348236995: {'path': 'temp/1743158579_1434065_1348236995_9e39fdf75e7f65551762fef20eebf058.jpg', 'extension': 'jpg'}, 1348237021: {'path': 'temp/1743158579_1434065_1348237021_78d9f6635ed69d06ea3a3bcf0dfba03a.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 = 21840944; (('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 = 21840944 group by h (('11', 31),) 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=21840944 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 (21840944) 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 (21840944) AND cps.thcl in (758) order by cps.score desc LIMIT 0, 100000 ERROR counted https://github.com/fotonower/Velours/issues/663#issuecomment-421136223 {} 28032025 21840944 Nombre de photos uploadées : 31 / 23040 (0%) 28032025 21840944 Nombre de photos taguées (types de déchets): 0 / 31 (0%) 28032025 21840944 Nombre de photos taguées (volume) : 0 / 31 (0%) [{'photo_id': 1348236034, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/f2749a36a8100dae32c3a3af82afdb7f.jpg', 'username': None, 'uploaded_at': 1743157939, 'text': 'image_28032025_11_30_04_010163m0.jpg 1e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1348236023, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/be4518e7c8928bda7f0b0a973dcd2134.jpg', 'username': None, 'uploaded_at': 1743157939, 'text': 'image_28032025_11_30_14_010136m0.jpg 2e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}, {'photo_id': 1348236019, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/a49edc7d3929ccb9de6e2efa4d8e9606.jpg', 'username': None, 'uploaded_at': 1743157939, 'text': 'image_28032025_11_30_34_010134m0.jpg 3.0000000000000004e-05 for time 1, id_amount 3 this amount prod time diff : 1e-05'}, {'photo_id': 1348236176, 'url': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/2025/3/28/7a8468cba5cc1b0cb972919e3107bc8c.jpg', 'username': None, 'uploaded_at': 1743157999, 'text': 'image_28032025_11_30_53_010137m0.jpg 4e-05 for time 1, id_amount 2 this amount prod time diff : 1e-05'}] 0 [] elapsed_time : load_data_split_time_score 2.86102294921875e-06 elapsed_time : order_list_meta_photo_and_scores 7.3909759521484375e-06 ??????????????????????????????? elapsed_time : fill_and_build_computed_from_old_data 0.00199127197265625 INSERT INTO `MTRPhoto`.`dashboard_entry_day` (`dashboard_place_id`, `mtr_portfolio_id`, `date`) VALUES ( 10, 21840944, '2025-03-28' ) ON DUPLICATE KEY UPDATE updated_at=NOW(); INSERT INTO `MTRPhoto`.`dashboard_run_ids` (`dashboard_entry_day`, `mtr_user_id`, `misc_info`) VALUES (1696037,979,"{}"); elapsed_time : insert_dashboard_record_day_entry 0.02404046058654785 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= 1696037 AND ded.last_run_id=dri.id AND dri.dashboard_entry_day=ded.id AND dri.id=dr.dashboard_run_id [{'dashboat_entry_day': 1696037, 'dashboard_run_id': 1705174, 'mtr_portfolio_id': 21838195, 'dashboard_result_id': 9715969, '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_P21838195_28-03-2025_11_03_30.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21838212, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21838213, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21838214, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21838215, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21838216, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21838217, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21838218, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21838219, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21838220, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21838221, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21838222, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21838223, 'pht': 3726}}"}, {'dashboat_entry_day': 1696037, 'dashboard_run_id': 1705174, 'mtr_portfolio_id': 21839015, 'dashboard_result_id': 9715970, '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_P21839015_28-03-2025_11_20_58.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 21839021, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21839022, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21839023, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21839024, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21839025, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21839026, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21839027, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21839028, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21839029, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21839030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21839031, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21839032, 'pht': 3726}}"}, {'dashboat_entry_day': 1696037, 'dashboard_run_id': 1705174, 'mtr_portfolio_id': 21840138, 'dashboard_result_id': 9715971, '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_P21840138_28-03-2025_11_33_28.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840252, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840253, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840254, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840256, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840257, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840258, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840259, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840260, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840261, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840262, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840263, 'pht': 3726}}"}, {'dashboat_entry_day': 1696037, 'dashboard_run_id': 1705174, 'mtr_portfolio_id': 21840944, 'dashboard_result_id': 9715972, '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_P21840944_28-03-2025_11_39_58.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840945, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840946, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840947, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840948, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840949, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840950, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840952, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840953, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840954, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840955, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840956, '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 = 21838195 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': 2701293, 'mtr_portfolio_id': 21838195, 'created_at': datetime.datetime(2025, 3, 28, 11, 3, 29), 'result': '0.026421518914189656', 'result_long': None, 'result_double': None}] Qualite : 0.026421518914189656 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 21838195 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21838195_28-03-2025_11_03_30.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 21838195 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_P21838195_28-03-2025_11_03_30.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21838212, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21838213, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21838214, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21838215, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21838216, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21838217, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21838218, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21838219, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21838220, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21838221, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21838222, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21838223, 'pht': 3726}}" where mtr_portfolio_id = 21838195 and dashboard_run_id = 1705174 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`=21838195 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9715969, 0.026421518914189656, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21838195_28-03-2025_11_03_30.pdf', 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21838212, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21838213, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21838214, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21838215, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21838216, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21838217, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21838218, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21838219, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21838220, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21838221, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21838222, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21838223, '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 = 21839015 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': 2701403, 'mtr_portfolio_id': 21839015, 'created_at': datetime.datetime(2025, 3, 28, 11, 20, 58), 'result': '0.038893714476781555', 'result_long': None, 'result_double': None}] Qualite : 0.038893714476781555 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 21839015 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21839015_28-03-2025_11_20_58.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 21839015 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_P21839015_28-03-2025_11_20_58.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 21839021, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21839022, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21839023, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21839024, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21839025, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21839026, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21839027, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21839028, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21839029, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21839030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21839031, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21839032, 'pht': 3726}}" where mtr_portfolio_id = 21839015 and dashboard_run_id = 1705174 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`=21839015 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9715970, 0.038893714476781555, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21839015_28-03-2025_11_20_58.pdf', 'papier': {'hashtag': 'papier', 'sub_port_id': 21839021, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21839022, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21839023, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21839024, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21839025, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21839026, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21839027, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21839028, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21839029, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21839030, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21839031, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21839032, '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 = 21840138 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': 2701463, 'mtr_portfolio_id': 21840138, 'created_at': datetime.datetime(2025, 3, 28, 11, 33, 27), 'result': '0.05185217229605837', 'result_long': None, 'result_double': None}] Qualite : 0.05185217229605837 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 21840138 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840138_28-03-2025_11_33_28.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 21840138 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_P21840138_28-03-2025_11_33_28.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840252, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840253, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840254, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840256, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840257, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840258, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840259, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840260, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840261, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840262, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840263, 'pht': 3726}}" where mtr_portfolio_id = 21840138 and dashboard_run_id = 1705174 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`=21840138 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9715971, 0.05185217229605837, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840138_28-03-2025_11_33_28.pdf', 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840252, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840253, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840254, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840255, 'pht': 3726}, 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840256, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840257, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840258, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840259, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840260, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840261, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840262, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840263, '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 = 21840944 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': 2701529, 'mtr_portfolio_id': 21840944, 'created_at': datetime.datetime(2025, 3, 28, 11, 42, 59), 'result': '0.03237440676718019', 'result_long': None, 'result_double': None}] Qualite : 0.03237440676718019 select url from MTRUser.mtr_files where mtd_id = 4302 and mtr_portfolio_id = 21840944 order by file_id desc limit 1 find url: https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840944_28-03-2025_11_43_00.pdf select completion_json, dashboard_run_id from MTRPhoto.dashboard_results where mtr_portfolio_id = 21840944 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_P21840944_28-03-2025_11_43_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840945, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840946, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840947, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840948, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840949, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840950, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840952, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840953, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840954, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840955, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840956, 'pht': 3726}}" where mtr_portfolio_id = 21840944 and dashboard_run_id = 1705174 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`=21840944 AND mptpi.`type`=3726 To do INSERT IGNORE INTO MTRPhoto.dashboard_results (id, qualite, completion_json) VALUES (9715972, 0.03237440676718019, "{'max_time_prod_two_photos': 0, 'url_report': 'https://storage.sbg.cloud.ovh.net/v1/AUTH_3b171620e76e4af496c5fd050759c9f0/media.fotonower.com/results_Auto_P21840944_28-03-2025_11_43_00.pdf', 'environnement': {'hashtag': 'environnement', 'sub_port_id': 21840945, 'pht': 3726}, 'Carton_brun': {'hashtag': 'Carton_brun', 'sub_port_id': 21840946, 'pht': 3726}, 'Teint_Dans_La_Masse': {'hashtag': 'Teint_Dans_La_Masse', 'sub_port_id': 21840947, 'pht': 3726}, 'kraft': {'hashtag': 'kraft', 'sub_port_id': 21840948, 'pht': 3726}, 'autre_refus': {'hashtag': 'autre_refus', 'sub_port_id': 21840949, 'pht': 3726}, 'papier': {'hashtag': 'papier', 'sub_port_id': 21840950, 'pht': 3726}, 'flou': {'hashtag': 'flou', 'sub_port_id': 21840951, 'pht': 3726}, 'mal_croppe': {'hashtag': 'mal_croppe', 'sub_port_id': 21840952, 'pht': 3726}, 'metal': {'hashtag': 'metal', 'sub_port_id': 21840953, 'pht': 3726}, 'cartonnette': {'hashtag': 'cartonnette', 'sub_port_id': 21840954, 'pht': 3726}, 'plastique': {'hashtag': 'plastique', 'sub_port_id': 21840955, 'pht': 3726}, 'Carton_gris': {'hashtag': 'Carton_gris', 'sub_port_id': 21840956, '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 (21838195,21839015,21840138,21840944) result : ((1348227631,), (1348227673,), (1348227722,), (1348227914,), (1348227957,), (1348227974,), (1348228028,), (1348228068,), (1348228100,), (1348228353,), (1348228359,), (1348228361,), (1348228404,), (1348228405,), (1348228406,), (1348228447,), (1348228448,), (1348228449,), (1348228529,), (1348228530,), (1348228531,), (1348228544,), (1348228552,), (1348228553,), (1348228580,), (1348228584,), (1348228624,), (1348228626,), (1348228635,), (1348228636,), (1348228646,), (1348228662,), (1348228667,), (1348228696,), (1348228724,), (1348228744,), (1348228755,), (1348228772,), (1348228784,), (1348228791,), (1348228811,), (1348228834,), (1348228861,), (1348228868,), (1348228904,), (1348228909,), (1348228927,), (1348228940,), (1348228971,), (1348228983,), (1348229034,), (1348229063,), (1348229121,), (1348229217,), (1348229245,), (1348229248,), (1348229298,), (1348229302,), (1348229323,), (1348229329,), (1348229334,), (1348229369,), (1348229385,), (1348229391,), (1348229407,), (1348229413,), (1348229423,), (1348229507,), (1348229528,), (1348229536,), (1348229600,), (1348229680,), (1348229690,), (1348229727,), (1348229910,), (1348229916,), (1348229923,), (1348229929,), (1348229944,), (1348229945,), (1348229949,), (1348229950,), (1348229994,), (1348229989,), (1348230091,), (1348230095,), (1348230102,), (1348230109,), (1348230116,), (1348230161,), (1348230168,), (1348230173,), (1348230177,), (1348230180,), (1348230365,), (1348230409,), (1348230430,), (1348230641,), (1348230659,), (1348230673,), (1348230709,), (1348230917,), (1348230951,), (1348230985,), (1348231014,), (1348231037,), (1348231057,), (1348231554,), (1348231614,), (1348231679,), (1348231728,), (1348231775,), (1348232120,), (1348232212,), (1348232296,), (1348232383,), (1348232476,), (1348232612,), (1348232656,), (1348232712,), (1348232750,), (1348232791,), (1348232817,), (1348233004,), (1348233016,), (1348233021,), (1348233085,), (1348233094,), (1348233108,), (1348233129,), (1348233253,), (1348233305,), (1348233334,), (1348233350,), (1348233579,), (1348233583,), (1348233614,), (1348233798,), (1348233812,), (1348233838,), (1348233854,), (1348233889,), (1348233895,), (1348233905,), (1348233909,), (1348233911,), (1348233919,), (1348234059,), (1348233955,), (1348233958,), (1348233965,), (1348234214,), (1348234219,), (1348234225,), (1348234245,), (1348234249,), (1348234385,), (1348234388,), (1348234397,), (1348234406,), (1348234409,), (1348234674,), (1348234686,), (1348234691,), (1348234707,), (1348234721,), (1348234742,), (1348234818,), (1348234821,), (1348234827,), (1348234854,), (1348234939,), (1348234942,), (1348234947,), (1348234951,), (1348234955,), (1348235180,), (1348235191,), (1348235206,), (1348235278,), (1348235286,), (1348235291,), (1348235344,), (1348235351,), (1348235358,), (1348235449,), (1348235454,), (1348235463,), (1348235469,), (1348235473,), (1348235477,), (1348235509,), (1348235514,), (1348235529,), (1348235557,), (1348235562,), (1348235567,), (1348235591,), (1348235595,), (1348235597,), (1348235603,), (1348235700,), (1348235703,), (1348235715,), (1348235727,), (1348235801,), (1348235813,), (1348235825,), (1348235836,), (1348235858,), (1348235881,), (1348235898,), (1348235900,), (1348235905,), (1348235910,), (1348235917,), (1348235969,), (1348235971,), (1348235983,), (1348235999,), (1348236045,), (1348236019,), (1348236023,), (1348236034,), (1348236149,), (1348236154,), (1348236158,), (1348236162,), (1348236172,), (1348236176,), (1348236206,), (1348236216,), (1348236257,), (1348236266,), (1348236277,), (1348236387,), (1348236399,), (1348236453,), (1348236457,), (1348236463,), (1348236468,), (1348236475,), (1348236538,), (1348236544,), (1348236575,), (1348236701,), (1348236704,), (1348236995,), (1348237021,), (1348237046,), (1348237120,), (1348237132,)) NUMBER BATCH : 0 # DISPLAY ALL COLLECTED DATA : {'28032025': {'nb_upload': 31, 'nb_taggue_class': 0, 'nb_taggue_densite': 0}} After datou_step_exec type output : map_portfolio_photo : len 1 keys : dict_keys([21840944]) Inside saveOutput : final : True verbose : True saveOutput not yet implemented for datou_step.type : split_time_score we use saveGeneral [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] map_info['map_portfolio_photo'] : {21840944: [1348237132, 1348237120, 1348237046, 1348237021, 1348236995, 1348236704, 1348236701, 1348236575, 1348236544, 1348236538, 1348236475, 1348236468, 1348236463, 1348236457, 1348236453, 1348236399, 1348236387, 1348236277, 1348236266, 1348236257, 1348236216, 1348236206, 1348236176, 1348236172, 1348236162, 1348236158, 1348236154, 1348236149, 1348236034, 1348236023, 1348236019]} final : True mtd_id 4302 list_pids : [1348237132, 1348237120, 1348237046, 1348237021, 1348236995] Looping around the photos to save general results len do output : 1 /21840944Didn'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, '2701529') ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529') ('4302', None, None, None, None, None, None, None, '2701529') ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529') begin to insert list_values into mtr_datou_result : length of list_values in save_final : 6 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, '21840944', 'None', None, None, None, None, '2701529'), ('4302', '21840944', '1348237132', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237120', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237046', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348237021', None, None, None, None, None, '2701529'), ('4302', '21840944', '1348236995', None, None, None, None, None, '2701529')] time used for this insertion : 0.011955022811889648 save_final save missing photos in datou_result : time spend for datou_step_exec : 0.344404935836792 time spend to save output : 0.01213216781616211 total time spend for step 5 : 0.3565371036529541 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 (2701529) 2.07user 2.29system 0:09.25elapsed 47%CPU (0avgtext+0avgdata 159472maxresident)k 976inputs+6728outputs (10major+63742minor)pagefaults 0swaps