Comments (6)
is it normal that it output exactly 0 more than 10% of the time?
(count (filter zero? (take 100000 (map noise1 (iterate (partial + (rand)) (rand 100000))))))
;;=> 10548
from math.
Investigating, thanks for letting me know....
from math.
Just for reference this code was ported from this OpenCL version here: https://github.com/terrybroad/Simplex_Noise_OpenCL/blob/master/Simplex_Noise.cl
from math.
Just updated (and optimized) these functions, but still not 100% sure where the scaling issue is coming from (actually might be already present in the original version this code is based on). Also have added some images and renamed the namespace to thi.ng.math.noise
(since I will add more noise gens, the current one is actually gradient noise, not the simplex noise, which is still waiting to be ported).
I removed the final normalization step from all fns, but noise1
now has a range of -1 .. +1. noise2
and noise3
seem to go from -1 .. +0.89....
https://github.com/thi-ng/math/blob/master/src/noise.org
from math.
great! I will take a look as soon as possible
from math.
let's maybe not close this just yet...
also, if you want to play around w/ it, use the [thi.ng/math "0.2.0-SNAPSHOT"]
from math.
Related Issues (3)
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 math.