Giter VIP home page Giter VIP logo

numpy-posit's People

Contributors

87 avatar ahaldane avatar alexbrc avatar certik avatar cgohlke avatar charris avatar cournape avatar eric-jones avatar eric-wieser avatar jaimefrio avatar jarrodmillman avatar jayvius avatar juliantaylor avatar larsmans avatar matthew-brett avatar mattip avatar mhvk avatar mwiebe avatar njsmith avatar pearu avatar pierregm avatar pv avatar rgommers avatar rkern avatar seberg avatar shoyer avatar stefanv avatar teoliphant avatar xman avatar xoviat avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

numpy-posit's Issues

Consider making a module rather than a fork

Hello!

I am an occasional numpy core developer, and I have a couple of questions and suggestions that might help getting this work used in the numpy community.

First, do you need this to be a fork of numpy? I haven't reviewed all of your modifications, but it seems to me that you are mostly adding a new dtype for posits. numpy does have the facility for new dtypes to be added by third-party packages without having to modify numpy itself. The support isn't necessarily the greatest, but if you run into issues, we'd like to hear about them; we would like to fix them to make life easier for you. You can see the numpy-quaternion package as an example of providing a new dtype. We very much encourage this approach.

If you do need to modify numpy itself, do you intend to propose merging this work into upstream numpy? If so, I recommend following the git workflow outlined in the Numpy Developer's Guide. Specifically, in your Github fork, leave the master branch untouched and work in a separate branch. This will help you stay up to date with upstream development and facilitate comparisons with the mainline development through the Github interface. When you are ready, you can just make a PR to numpy.

The problem with maintaining a true fork of numpy is that users are going to have problems deploying packages that depend on numpy-posit and other packages that depend on numpy proper. pip and other package management tools don't necessarily work particularly well in such cases.

In any case, I wish you the best of luck! I look forward to experimenting with posits in the future! Thank you for your attention.

How should I use it?

I want to use posit as a kind of data type in deep learning, so I want to ask some questions.
(1) How many es-bits does the posit have? For example, is posit8 posit<8, 0>, posit<8, 1> or other types?
(2) How to enable or disable the FMA and Quire operation for posit?
(3) Does it support GPU acceleration?

np.load cannot properly interpret the dtype as posit8

After saving a numpy array of dtype 'posit8' using numpy.savez, I am having trouble loading it back up using numpy.load. I get the following error,

Traceback (most recent call last):
  File "/home/neo/src/numpyposit/numpy/lib/format.py", line 527, in _read_array_header
    dtype = numpy.dtype(d['descr'])
TypeError: data type "<f1" not understood

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/neo/src/numpyposit/numpy/lib/npyio.py", line 251, in __getitem__
    pickle_kwargs=self.pickle_kwargs)
  File "/home/neo/src/numpyposit/numpy/lib/format.py", line 642, in read_array
    shape, fortran_order, dtype = _read_array_header(fp, version)
  File "/home/neo/src/numpyposit/numpy/lib/format.py", line 530, in _read_array_header
    raise ValueError(msg % (d['descr'],))
ValueError: descr is not a valid dtype descriptor: '<f1'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.