Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem running 'example_runcounting' #1

Open
althorneywork opened this issue Aug 7, 2024 · 0 comments
Open

Problem running 'example_runcounting' #1

althorneywork opened this issue Aug 7, 2024 · 0 comments

Comments

@althorneywork
Copy link

runfile('C:/Users/alice./Desktop/Documents/Projects/countoscope_old-main/example_runcounting.py', wdir='C:/Users/alice./Desktop/Documents/Projects/countoscope_old-main')
Reloaded modules: countoscope
Will use 12 threads
Reading data from array
Done with data read
Compiling fast counting function
Traceback (most recent call last):

File "C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\example_runcounting.py", line 27, in
results = countoscope.calculate_nmsd(data=data, window_size_x=Lx, window_size_y=Ly, box_sizes=box_sizes, sep_sizes=sep_sizes)

File "C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py", line 500, in calculate_nmsd
CountMs, box_xs, box_ys = count_boxes(Xs, Ys, window_size_x=window_size_x, window_size_y=window_size_y,

File "C:\Users\alice.\Anaconda3\lib\site-packages\numba\core\dispatcher.py", line 468, in _compile_for_args
error_rewrite(e, 'typing')

File "C:\Users\alice.\Anaconda3\lib\site-packages\numba\core\dispatcher.py", line 409, in error_rewrite
raise e.with_traceback(None)

TypingError: Failed in nopython mode pipeline (step: nopython frontend)
Failed in nopython mode pipeline (step: nopython frontend)
Use of unsupported NumPy function 'numpy.isclose' or unsupported use of the function.

File "countoscope.py", line 191:
def approx_lte(x, y):

# floating-point safe version of x <= y
return x <= y or bool(np.isclose(x, y))
^

During: typing of get attribute at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (191)

File "countoscope.py", line 191:
def approx_lte(x, y):

# floating-point safe version of x <= y
return x <= y or bool(np.isclose(x, y))
^

During: resolving callee type: type(CPUDispatcher(<function approx_lte at 0x00000292319015E0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (211)

During: resolving callee type: type(CPUDispatcher(<function approx_lte at 0x00000292319015E0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (212)

During: resolving callee type: type(CPUDispatcher(<function approx_lte at 0x00000292319015E0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (211)

File "countoscope.py", line 211:
def do_counting_at_boxsize_new(x, y, window_size_x, window_size_y, box_size_x, box_size_y, offset_x, offset_y, num_timesteps, shift_size_x, shift_size_y):

assert approx_lte(offset_x + (num_boxes_x-1)*shift_size_x + 1*box_size_x, window_size_x) # make sure that the final box doesn't overlap the edge of the window
^

During: resolving callee type: type(CPUDispatcher(<function do_counting_at_boxsize_new at 0x0000029231901AF0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (351)

During: resolving callee type: type(CPUDispatcher(<function do_counting_at_boxsize_new at 0x0000029231901AF0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (370)

During: resolving callee type: type(CPUDispatcher(<function do_counting_at_boxsize_new at 0x0000029231901AF0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (351)

During: resolving callee type: type(CPUDispatcher(<function do_counting_at_boxsize_new at 0x0000029231901AF0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (370)

During: resolving callee type: type(CPUDispatcher(<function do_counting_at_boxsize_new at 0x0000029231901AF0>))
During: typing of call at C:\Users\alice.\Desktop\Documents\Projects\countoscope_old-main\countoscope.py (351)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant