Open meelash opened 8 years ago
This happens whether automargins is on or off, detection set to page or content. I've attached my config.yaml file and a sample photo.
By the way this happens with a freshly-created, unmodified config.yaml file also, using all defaults.
How are you triggering the post-processing? From the web-interface or via the command-line? The webui-support for post-processing is still experimental, if you run into problems give the command-line a shot.
Thanks for the suggestion; I am triggering using the web-interface. However, I've confirmed that the issue is related to the quality of the scan. As you can see from the sample scan, I was just testing out the system without lights, etc. I've now installed lights and captured another set of scans and can confirm that with all the same settings, scantailor post processing fails on the poorly-lit set and not on the well-lit set.
In case it means anything to anyone, I threw in a log of the scantailor.margins variable on the line right before where the error is thrown and in the well-lit set of scans (doesn't fail) it prints this to console: spreadsplug.scantailor: the margins are: [2.5, 2.5, 2.5, 2.5] whereas for the poorly-lit set of scans (fails, example scan above) it prints this to console: spreadsplug.scantailor: the margins are: 2.5
I unfortunately don't have my development machine with me at the moment (for the next few months) or I would investigate further, but if anyone is interested in looking into it and needs anything from me to help repeat it, I'd be happy to help as much as I can.
Wow, that is really weird. The error occurs in a part of the code that is completely oblivious to what's in the images, so the quality should not have any effect. I suspect this is a bug in the way the web-interface initiates the post-processing (which is a bit over-engineered, tbh). Can you check if the error also occurs when you start the post-processing with the badly lit scan on the command-line?
huey.consumer.ConsumerThread: Unhandled exception in worker thread Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/spreads/vendor/huey/consumer.py", line 149, in process_task self.huey.execute(task) File "/usr/local/lib/python2.7/dist-packages/spreads/vendor/huey/api.py", line 236, in execute result = task.execute() File "/usr/local/lib/python2.7/dist-packages/spreads/vendor/huey/api.py", line 415, in execute return func(_args, _kwargs) File "/usr/local/lib/python2.7/dist-packages/spreadsplug/web/tasks.py", line 1 66, in process_workflow workflow.process() File "/usr/local/lib/python2.7/dist-packages/spreads/workflow.py", line 972, i n process self._run_hook('process', self.pages, processed_path) File "/usr/local/lib/python2.7/dist-packages/spreads/workflow.py", line 833, i n _run_hook getattr(plug, hook_name)(args) File "/usr/local/lib/python2.7/dist-packages/spreadsplug/scantailor.py", line 285, in process projectfile, out_dir) File "/usr/local/lib/python2.7/dist-packages/spreadsplug/scantailor.py", line 113, in _generate_configuration marginconf = self.config['margins'].as_str_seq() File "/usr/local/lib/python2.7/dist-packages/spreads/vendor/confit.py", line 3 98, in as_str_seq 'a list'.format(self.name) ConfigTypeError: scantailor.margins must be a whitespace-separated string or a l ist