Comments (6)
I am VERY interested in this! Amazing!
from fixedmath.net.
Glad to hear John! Let me know if you try Hastlayer!
from fixedmath.net.
Do you need any source code changes to achieve this? I'm not sure how I can help. The source code is under a permissive license so you can do whatever you please with it
from fixedmath.net.
I'm looking through the project. At them time the only issue I see is that Hastlayer doesn't yet support static fields. Nevertheless I started a PoC in this branch: https://github.com/Lombiq/Hastlayer-SDK/commits/issue/HAST-140, see the diff of the work done here: Lombiq/Hastlayer-SDK@dev...issue/HAST-140.
from fixedmath.net.
I added a PoC implementation after some necessary modifications. What's now transformable into hardware is this implementation: https://github.com/Lombiq/Hastlayer-SDK/blob/issue/HAST-140/Hast.Algorithms/Fix64.cs
The two most notable changes I made is that I got rid of the static fields (not supported by Hastlayer) and applied a workaround temporarily necessary for large hex literals.
Tested various operations and seems to be working alright. This sample that simply sums numbers needs about 106ms on my machine (Core i7, 8 logical cores) with an input of 10000000, 1300ms on a low-end FPGA, This is with purely sequential code (to make FPGAs feasibly the algorithm needs to be massively parallelizable), but still, the FPGA is only 13 times slower with a 32 times lower clock speed (100Mhz vs 3,2Ghz) and most possibly proportionally more power efficient.
With a parallelism of 10 degrees (i.e. 10 threads working in parallel) the same sample takes 264ms on the CPU and still 1300ms on the FPGA. As you can see as we increase the level of parallelism the CPU will get slower of course (if the level of parallelism exceeds the number of cores), the FPGA will stay the same. It's still slower, and this is because more threads won't fit on this low-end FPGA of ours (but we're working on supporting bigger ones).
And thus now FixedMath.Net is the included fixed-point library in Hastlayer.
from fixedmath.net.
Good to know this library was useful to you! I guess this issue can be closed now.
from fixedmath.net.
Related Issues (20)
- Thanks HOT 7
- Could you add Pow()? HOT 3
- Is this library correct in terms of Base10 calculations? HOT 1
- ReflectionTypeLoadException: The classes in the module cannot be loaded. HOT 2
- request for Fixed32 too HOT 4
- Function Pow bug report HOT 1
- how to transfer by network? HOT 2
- A bug when use Acos() to 2 normalized vector HOT 2
- Suggestion adding **Fixed Point** keyword in description HOT 1
- Is changing "Fractional_Places" supported? HOT 2
- Using Math. for Fix32 HOT 6
- Debugging Determinism? (discussion) HOT 6
- Converting float to Fix64 consistent across CPU architectures? HOT 5
- Determinism HOT 3
- Suggestion: need profiling.
- Problem: Sqrt() for Q48.15 format implementation HOT 1
- FixedMath.Net with Net 3.5 (Unity3D) HOT 6
- Any plans to make all conversions deterministic? HOT 15
- Conversions from float and double are unspecified in case of overflow
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fixedmath.net.