-
Notifications
You must be signed in to change notification settings - Fork 12
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
refactor(entry_points): Removing legacy entry points #985
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
As a step towards #517 this commit removes the legacy entry points and their associated tests.
ns-rse
requested review from
SylviaWhittle,
MaxGamill-Sheffield and
llwiggins
October 28, 2024 16:21
The release of [skan-0.12.0]() introduced the below error where the type is wrong when `nbgraph()` uses `numba`. For now we pin `skan==0.11.1` ``` tests/tracing/test_disordered_tracing.py:1265: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ topostats/tracing/disordered_tracing.py:660: in disordered_trace_grain "branch_types": get_skan_image( topostats/tracing/disordered_tracing.py:697: in get_skan_image skan_skeleton = skan.Skeleton(skeleton_image, spacing=1e-9, value_is_height=True) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/skan/csr.py:532: in __init__ self.nbgraph = csr_to_nbgraph(graph, self.pixel_values) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/skan/csr.py:205: in csr_to_nbgraph return NBGraph( /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/experimental/jitclass/base.py:124: in __call__ return cls._ctor(*bind.args[1:], **bind.kwargs) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:442: in _compile_for_args raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:375: in _compile_for_args return_val = self.compile(tuple(argtypes)) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:905: in compile cres = self._compiler.compile(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:80: in compile status, retval = self._compile_cached(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:94: in _compile_cached retval = self._compile_core(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:107: in _compile_core cres = compiler.compile_extra(self.targetdescr.typing_context, /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:744: in compile_extra return pipeline.compile_extra(func) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:438: in compile_extra return self._compile_bytecode() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:506: in _compile_bytecode return self._compile_core() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:481: in _compile_core raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:472: in _compile_core pm.run(self.state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:364: in run raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:356: in run self._runPass(idx, pass_inst, state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_lock.py:35: in _acquire_compile_lock return func(*args, **kwargs) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:311: in _runPass mutated |= check(pss.run_pass, internal_state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:273: in check mangled = func(compiler_state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typed_passes.py:112: in run_pass typemap, return_type, calltypes, errs = type_inference_stage( /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typed_passes.py:93: in type_inference_stage errs = infer.propagate(raise_errors=raise_errors) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:1083: in propagate errors = self.constraints.propagate(self) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:182: in propagate raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:160: in propagate constraint(typeinfer) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:583: in __call__ self.resolve(typeinfer, typevars, fnty) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:606: in resolve sig = typeinfer.resolve_call(fnty, pos_args, kw_args) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typeinfer.py:1577: in resolve_call return self.context.resolve_function_type(fnty, pos_args, kw_args) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typing/context.py:196: in resolve_function_type res = self._resolve_user_function_type(func, args, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typing/context.py:248: in _resolve_user_function_type return func.get_call_type(self, args, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/types/misc.py:441: in get_call_type return self.ctor_template(context).apply(args, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typing/templates.py:350: in apply sig = generic(args, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/experimental/jitclass/base.py:269: in generic sig = disp_type.get_call_type(self.context, boundargs, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/types/functions.py:541: in get_call_type self.dispatcher.get_call_template(args, kws) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:318: in get_call_template self.compile(tuple(args)) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:905: in compile cres = self._compiler.compile(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:80: in compile status, retval = self._compile_cached(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:94: in _compile_cached retval = self._compile_core(args, return_type) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/dispatcher.py:107: in _compile_core cres = compiler.compile_extra(self.targetdescr.typing_context, /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:744: in compile_extra return pipeline.compile_extra(func) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:438: in compile_extra return self._compile_bytecode() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:506: in _compile_bytecode return self._compile_core() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:481: in _compile_core raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler.py:472: in _compile_core pm.run(self.state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:364: in run raise e /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:356: in run self._runPass(idx, pass_inst, state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_lock.py:35: in _acquire_compile_lock return func(*args, **kwargs) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:311: in _runPass mutated |= check(pss.run_pass, internal_state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/compiler_machinery.py:273: in check mangled = func(compiler_state) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/typed_passes.py:468: in run_pass lower.lower() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/lowering.py:187: in lower self.lower_normal_function(self.fndesc) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/lowering.py:226: in lower_normal_function entry_block_tail = self.lower_function_body() /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/lowering.py:256: in lower_function_body self.lower_block(block) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/lowering.py:270: in lower_block self.lower_inst(inst) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/lowering.py:564: in lower_inst return impl(self.builder, (target, value)) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/base.py:627: in wrapped return impl(self, builder, sig, args, attr) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/imputils.py:166: in res return real_impl(context, builder, sig, args, attr) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/experimental/jitclass/base.py:505: in set_attr_impl setattr(data, _mangle_attr(attr), val) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/cgutils.py:164: in __setattr__ self[self._datamodel.get_field_position(field)] = value /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/cgutils.py:178: in __setitem__ value = self._cast_member_from_value(index, value) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/cgutils.py:251: in _cast_member_from_value return model.as_data(self._builder, val) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/numba/core/datamodel/models.py:586: in as_data struct = builder.insert_value(struct, el, [i]) /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/llvmlite/ir/builder.py:983: in insert_value instr = instructions.InsertValue(self.block, agg, value, idx, name=name) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <[AttributeError("'InsertValue' object has no attribute '_name'") raised in repr()] InsertValue object at 0x7ccfbd4f6b90>, parent = <ir.Block 'B0' of type 'label'> agg = <ir.InsertValue '.258' of type '{i8*, i8*, i64, i64, double*, [1 x i64], [1 x i64]}', opname 'insertvalue', operands [...value=<llvmlite.ir.values._Undefined object at 0x7cd0142cda50>>, <ir.Argument 'arg.node_props.6.0' of type i64>]>]>]>]> elem = <ir.ExtractValue 'extracted.data.22' of type 'float*', opname 'extractvalue', operands [<ir.InsertValue 'inserted.stri...' value=<llvmlite.ir.values._Undefined object at 0x7cd0142cda50>>, <ir.Argument 'arg.node_props.6.0' of type i64>]>]>]> indices = [4], name = '' def __init__(self, parent, agg, elem, indices, name=''): typ = agg.type try: for i in indices: typ = typ.elements[i] except (AttributeError, IndexError): raise TypeError("Can't index at %r in %s" % (list(indices), agg.type)) if elem.type != typ: > raise TypeError("Can only insert %s at %r in %s: got %s" % (typ, list(indices), agg.type, elem.type)) E TypeError: Can only insert double* at [4] in {i8*, i8*, i64, i64, double*, [1 x i64], [1 x i64]}: got float* /home/neil/.virtualenvs/topostats-311b/lib/python3.11/site-packages/llvmlite/ir/instructions.py:702: TypeError __________________________________________________________________________________________ tests/test_run_topostats.py ___________________________________________________________________________________________ ```
ns-rse
force-pushed
the
ns-rse/517-remove-old-entry-points
branch
from
October 29, 2024 14:26
68913a9
to
4dd47d8
Compare
SylviaWhittle
approved these changes
Oct 30, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Always very happy to remove code!
Thanks @SylviaWhittle merged so you're good to rebase onto |
This was referenced Nov 13, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As a step towards #517 this commit removes the legacy entry points and their associated tests.