Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 2 years ago.
Improve this question
I'm trying to use pyzbar to read multiple barcode, however it seems like I can't read multiple instead of only one big bounding boxes.
When you call pyzbar.decode it will decode all 1D barcodes in your image. For example:
from pyzbar.pyzbar import decode
from PIL import Image
for bar in decode(Image.open('benchmark.jpg')):
print(bar.data)
will print out
b'12345678'
b'12345678'
b'0000123456784'
However in your case all barcodes are identical so pyzbar just returns a list with a single element. It would work if they were different however.
Related
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 6 days ago.
Improve this question
I'm having trouble installing opencv. Is it possible to get contours from a picture without using opencv in python?
You could iterate over the pixels using a for loop, darken each pixel until you’ve got your more prominent values, then create an array of vectors dependant on the outline, tensorflow posenet does this
OpenCV is more widely used for this purpose, but you can also do great things with:
Scikit-image find_contours measure: Check code & sample here
PIL/Pillow: For simpler uses. Check this example
Tensoflow: For more advanced use, there are some approaches too using Deep Learning for this. Just found this sample searching Github
Pytorch: Also via deep learning. Check this other sample
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 9 days ago.
Improve this question
I have a DEM ESRI ASCII raster file that I am trying to run a 2D model with on Flood Modeller software but I keep getting an error that it cannot read the NCOLS.
I have tried to open the file in Python but I get an error saying could not convert string to float.Images show Python error and Flood Modeller log file](https://i.stack.imgur.com/mVoud.jpg)
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 1 year ago.
Improve this question
I have two array one with shape (320,1) and one with (850,1) how should I combine the two array. I tried np.append however it seems to be an error.
Assuming the two arrays are called arr1 and arr2, you could try the following code:
arr3 = np.append(arr1,arr2).reshape((-1,1))
The reshape is needed to make sure the final shape is (1170,1) instead of (1170,)
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 1 year ago.
Improve this question
Having a df of data, doing:
fig=px.line(df, x='date', y='px', color='description')
The following graph is rendered like the image attached. Is this an expected behavior? How do I make dots connect only in a time-ordered fashion?
Yes, this is observed in plotly plots.
The data is required to be sorted before the plotting.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking for code must demonstrate a minimal understanding of the problem being solved. Include attempted solutions, why they didn't work, and the expected results. See also: Stack Overflow question checklist
Closed 9 years ago.
Improve this question
I would like to know whether it is possible to carry out such an operation, that one picture is placed into another one at exact coordinates, automatedly.
I have a set consisting of 20 pairs of images of fixed size. I need to merge the pairs by placing first image of a pair to a fixed position on the second image.
I might need to do this mergers several times in future, so I am interested if there is a chance to write a scrypt in Python/Perl or any other simple language to handle this task. I am now using GIMP scripts, but most of the work still needs to be carried out manually...
Anyway, if this is not an option, I am asking someone to be so kind and briefly explain why is it so.
Thanks!
a lot of recepies ImageMagick v6 Examples -- Compositing Images. And you need perl-magick.