Comments (4)
Hey @TomDonoghue @maestapereira - sorry for misunderstanding the issue. I updated my branch and now get the same results as you.
from spiketools.
Hey @maestapereira , I just check the compute_spatial_bin_assignment
function with the exact example you provided above, and it works fine.
Here is the output I get when I print(x_bins, y_bins)
:
[1 2 3 4] [1 2 3 4]
I don't know why exactly you got a different output but my guess is that maybe you haven't fetched upstream with main
which has the changes we previously made to the compute_spatial_bin_assignment
function.
REPLACED:
x_bins = pd.cut(position[0, :], x_edges, labels=np.arange(len(x_edges) - 1))
y_bins = pd.cut(position[1, :], y_edges, labels=np.arange(len(y_edges) - 1))
WITH:
x_bins = np.digitize(position[0, :], x_edges, right=True)
y_bins = np.digitize(position[1, :], y_edges, right=True)
Hope this helps!
from spiketools.
Hey @claire98han - thanks for also checking into this! I also get the same results as Sandra (and I think I know what's going on). I think the difference is that your version is behind (I made changes to this file yesterday, and introduced this bug it seems).
Claire, can you update from main, and double check that you get the same answer as Sandra and I?
from spiketools.
Fixed in #39 39
from spiketools.
Related Issues (20)
- [ENH] - 1d and 2d function compatibility HOT 1
- Update approach / API for spatial information HOT 2
- Alignment between spatial representations HOT 1
- Shuffle Circular-Bins is broken HOT 5
- Module sweep - potential updates & refactors
- Tutorials & Documentation Updates
- Future developments / refactors
- Current Quirks with 0.1 HOT 2
- 0.1 code checks / fixes
- Orientation of position data HOT 1
- [BUG] - Computing & plotting continuous firing rates HOT 1
- Suggested improvements / typo fixes in tutorials HOT 1
- Documentation search bar doesn't work HOT 1
- [BUG] - Array orientation for 2d position with a single datapoint HOT 1
- [ENH] - Add randomness to `shuffle_poisson` HOT 1
- Potential updates for position related plots HOT 1
- Plot quirks HOT 1
- Extract & Epoch functions HOT 1
- Examples link in README is broken HOT 1
- Naming consistencies HOT 1
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 spiketools.