Open denadai2 opened 1 year ago
It seems that if I removeint_domain
from ColumnSchema
everthing can be copied
class ColumnSchema(Feature):
@classmethod
def create_categorical(
cls,
name: str,
num_items: int,
shape: Optional[Union[Tuple[int, ...], List[int]]] = None,
value_count: Optional[Union[ValueCount, ValueCountList]] = None,
min_index: int = 0,
tags: Optional[TagsType] = None,
**kwargs,
) -> "ColumnSchema":
_tags: List[str] = [t.value for t in TagSet(tags or [])]
extra = _parse_shape_and_value_count(shape, value_count)
int_domain = IntDomain(name=name, min=min_index, max=num_items, is_categorical=True)
_tags = list(set(_tags + [Tags.CATEGORICAL.value]))
extra["type"] = FeatureType.INT
return cls(name=name, int_domain=int_domain, **extra, **kwargs).with_tags(_tags)
and it gets solved with betterproto 2.0, maybe because of https://github.com/danielgtaylor/python-betterproto/pull/339. However, this creates a dependency clash
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts. merlin-core 23.6.0 requires betterproto<2.0.0, but you have betterproto 2.0.0b6 which is incompatible.
Thanks for the detailed bug report and the fix.
You can try updating the dependencies in requirements.txt; there's a reasonable chance that it'll work. We're unfortunately not able to update our containers at this time but if you can test that it's working we'd love a PR with your solution.
Bug description
I have a bug just creating a schema programmatically. Can you help me on this?
thx
Steps/Code to reproduce bug
I have
TypeError: cannot pickle 'mappingproxy' object
coming from
This happens even when I just do:
Environment details