Package Details: python-flax 0.12.5-1

Git Clone URL: https://aur.archlinux.org/python-flax.git (read-only, click to copy)
Package Base: python-flax
Description: A neural network library and ecosystem for JAX designed for flexibility
Upstream URL: https://github.com/google/flax
Keywords: deep-learning jax
Licenses: Apache-2.0
Groups: jax
Submitter: wjhandley
Maintainer: wjhandley (daskol)
Last Packager: wjhandley
Votes: 5
Popularity: 0.002161
First Submitted: 2021-05-25 18:34 (UTC)
Last Updated: 2026-03-09 12:17 (UTC)

Latest Comments

1 2 Next › Last »

daskol commented on 2026-02-10 20:42 (UTC)

@carlosal1015 Ah, usual Python compatibility issues... The issue has been fixed on Jan 5 and published in release v0.12.3. I bumped minor version.

carlosal1015 commented on 2026-02-10 10:57 (UTC)

Successfully built flax-0.12.0-py3-none-any.whl
==> Starting check()...
Traceback (most recent call last):
  File "<string>", line 1, in <module>
    import flax
  File "/build/python-flax/src/flax-0.12.0/flax/__init__.py", line 26, in <module>
    from flax import linen
  File "/build/python-flax/src/flax-0.12.0/flax/linen/__init__.py", line 39, in <module>
    from .activation import (
    ...<26 lines>...
    )
  File "/build/python-flax/src/flax-0.12.0/flax/linen/activation.py", line 21, in <module>
    from flax.linen.module import compact
  File "/build/python-flax/src/flax-0.12.0/flax/linen/module.py", line 3173, in <module>
    class CompactNameScope(Module):
    ...<5 lines>...
        return self.fn(self.module_fn(), *args, **kwargs)
  File "/build/python-flax/src/flax-0.12.0/flax/linen/module.py", line 1042, in __init_subclass__
    cls._customized_dataclass_transform(kw_only)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
  File "/build/python-flax/src/flax-0.12.0/flax/linen/module.py", line 1114, in _customized_dataclass_transform
    kw_only_dataclasses.dataclass(
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
      cls,
      ^^^^
    ...<2 lines>...
      extra_fields=extra_fields,
      ^^^^^^^^^^^^^^^^^^^^^^^^^^
    )  # pytype: disable=wrong-keyword-args
    ^
  File "/build/python-flax/src/flax-0.12.0/flax/linen/kw_only_dataclasses.py", line 125, in dataclass
    return wrap if cls is None else wrap(cls)
                                    ~~~~^^^^^
  File "/build/python-flax/src/flax-0.12.0/flax/linen/kw_only_dataclasses.py", line 123, in wrap
    return _process_class(cls, extra_fields=extra_fields, **kwargs)
  File "/build/python-flax/src/flax-0.12.0/flax/linen/kw_only_dataclasses.py", line 191, in _process_class
    cls_annotations = cls.__dict__['__annotations__']
                      ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
KeyError: '__annotations__'
==> ERROR: A failure occurred in check().
    Aborting...

micwoj92 commented on 2025-02-17 00:39 (UTC)

Dep python-tensorstore not needed.

zxeoc commented on 2023-09-21 07:04 (UTC)

@daskol I'm sorry.

daskol commented on 2023-09-20 20:36 (UTC)

@zxeoc Do not paste large outputs in comments, please.

The issue is in python-etils which is a transitive dependency for python-flax.

zxeoc commented on 2023-09-20 19:41 (UTC) (edited on 2023-09-21 07:09 (UTC) by zxeoc)

I got an error when trying to install it on my laptop.

E   ModuleNotFoundError: No module named 'mediapy'
E   
E   Each etils sub-modules require deps to be installed separately (e.g. `from etils import ecolab` -> `pip install etils[ecolab]`)
...
==> ERROR: A failure occurred in check().
    Aborting...
error: failed to build 'python-etils-1.5.0-1': 
error: can't build python-orbax-checkpoint-0.2.7-2, deps not satisfied: python-etils
error: can't build python-flax-0.7.1-5, deps not satisfied: python-orbax-checkpoint
error: packages failed to build: python-etils-1.5.0-1  python-orbax-checkpoint-0.2.7-2  python-flax-0.7.1-5

daskol commented on 2023-07-29 17:47 (UTC) (edited on 2023-07-29 18:00 (UTC) by daskol)

Why two source=(...)?

@Henry-ZHR It was a typo. Sorry. Only the latest one is actual source.

There are several issues. The first one is that Flax Team for some reason does not publish(?) or update package on PyPI (it is recommened way to get sources). The second one is flax/version.py is not updated properly on regular basis (see this PR).

Henry-ZHR commented on 2023-07-29 17:06 (UTC)

Why two source=(...)?

daskol commented on 2023-02-20 13:13 (UTC) (edited on 2023-02-20 13:20 (UTC) by daskol)

@wjhandley Thanks! I've pushed a commit right with fixes suggested earlier. Indeed, python-flax was added by a mistake when I tried to resolve circular dependency between python-flax and python-orbax (see https://github.com/google/flax/issues/2707 for details).

wjhandley commented on 2023-02-20 11:18 (UTC)

Hi daskol. Should it depend on python-flax?

I've made you a co-maintainer if you want to adjust this directly.