topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Thursday December 4, 2025, 4:32 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Recent Posts

Pages: prev1 ... 191 192 193 194 195 [196] 197 198 199 200 201 ... 1514next
4876
Living Room / Re: Any Opinions or Thoughts on Infinity 60% Keyboard Kit
« Last post by mouser on February 25, 2016, 08:50 PM »
I don't get the appeal of a 60% size keyboard.
4877
Clipboard Help+Spell / Re: Errors
« Last post by mouser on February 25, 2016, 08:20 PM »
firs things first, go to options then Backup/Maintenance tab and click on the button 1-down from the top right labeleld "Verify, Repair, Optimize" database.

See if that fixes the problem.

This kind of error has been known to happen when an antivirus or similar tool blocks CHS from writing it's database files.

One way you can try to fix that is by going into the Tweaks tab and changing the Temporary DB file location.
4878
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 03:40 PM »
If it rolls a 19, is that a 19 on the chart?
yes, after the system creates its clusters automatically, i rename the clusters according to their die faces.

And finally, how do you eliminate the possibility that it's your rolling mechanism which is unfair?

This is somewhat of a philosophical question.

The only thing you can really say from these results is that the die rolling outcome results are biased.

However, what we can say is that there doesn't appear to be any clear pattern in terms of transitions in the heat map that would suggest that the die roller is doing weird things like flipping the die between alternate faces.
To help validate that the rolling procedure was as fair as possible you could try comparing results to different rolling mechanisms, or more practically, i could extend the rolling times to see if that made much of a difference.  Finding some high quality trusted fair dice that evaluated to fair using the system would give more confidence.

But to see why this has to be approached somewhat philosophically, just consider how physically the die might be biased -- it could be because of uneven weighting, or assymetric shape, or rounded vs sharp corners, etc.  And these will effect different "rolling" procedures differently.  So the way the bias will show up is dependent on the way in which the dice are "rolled" (randomized).  The best we can say is that when the die is rolled in this fashion, they exhibit this bias.  If you asked a human to roll the dice to test for bias, you would have the same problem -- the bias may show up differently based on whether the user "shakes" the dice in their hand and drops them to the table, or rolls them a far distance against a wall, etc.

If you really wanted to be more specific about bias of dice for human use, you could try to ascertain whether the biases found by one rolling machine matched the biases found by a certain human method of rolling dice.
4879
Site/Forum Features / Re: Sent Messages?
« Last post by mouser on February 25, 2016, 02:13 PM »
It's a little weird but after you click on My Messages, the FAR LEFT item that says "MESSAGES" is a menu with "Sent Items" as a submenu -- that's what you want.
4880
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 09:42 AM »
I wanted to check if the initial biased results above indicating that some die faces are significantly less likely to be rolled, still hold up if the experiment is repeated -- or were just random spikes in the data.
As a nice demonstration of the power of statistics, here's a completely INDEPENDENT run of another 5900 rolls of this same die:

Screenshot - 2_25_2016 , 9_38_40 AM.png

Notice the same basic pattern as the first chart in terms of which die faces are more and less likely to come up.  Pretty darn cool.  :up: :up: :up:
4881
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 03:58 AM »
ps. not enough data to make this useful but if you like pretty charts, here's the heatmap showing the die face transitions for those 5000 rolls:
Screenshot - 2_25_2016 , 3_57_40 AM.png
4882
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 03:46 AM »
5000+ Rolls of a D20:

Screenshot - 2_25_2016 , 3_45_37 AM.png

Looks like these discount bags-o-dice i bought leave something to be desired in terms of fairness!
4883
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 01:45 AM »
As educational as this project was, it seems to me that my intention of building a standalone Raspberry Pi powered ART PROJECT may not come to fruition, just because of the sheer amount of additional work it would take to make a nice user-friendly GUI interface and how hard it would be to make the code truly reliable enough that you could drop in any die and have it analyzed, and due to the slow speed of the RPI version of the code.

So it may be that I need to find another RPI art project idea..
4884
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 01:40 AM »
Why didn't you use that motor control hat to turn on the dice-roller? Or doesn't it have a relay for switching something external? (probably depends on the model, but a separate relay-hat isn't that expensive) Your python code on the RPi can then directly control the dice-roller without further external devices.

Excellent question.

My original plan was to run the dicer software on the standalone Raspberry Pi as planned, and have the motor hat on the Raspberry Pi directly drive the motor in the dicer roller (or indeed a better replacement motor).

There were three reasons I did not go forward with this plan:
  • The first was that the Raspberry Pi is 30x slower than my PC, and my recognition code is quite slow (I need to find ways to be more clever and take a less brute force approach to image rotation alignment).  Because of this I wanted to go back to doing most of my development at least on my desktop PC.
  • The second was that the camera on the Raspberry Pi, while high resolution, has absolutely no focus control and would not focus well on anything shorter than about 24 inches from it.  This caused real trouble and I tried a bunch of kludges to fix this including misc. lens and even reading glass lenses, etc.  But I just couldnt get something working reliably.  It's really a shame the RPi camera doesnt have a focus ring.  Trying to use a standard webcam on Rpi was untsable/unsatisfactory.
  • The third was that I wanted to do minimal surgery on the $10 die roller that was made in China but shipped from Germany, because if I messed it up, it would be another month before I got a replacement.  And I wanted to still be able to engage it manually.

So right now I'm actually controlling the Arduino from my DESKTOP (windows) python code.  The Raspberry Pi version of the software can also control it (Raspberry Pi controlling an Arduino is kind of like a Turducken, but it does work).
4885
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 25, 2016, 12:57 AM »
For those who might be curious, here is how i wired up the Arduino and Dice Roller:

First, as I posted here, I ordered a $10 battery (2xAA) powered dice spinner from Amazon.  You push a button and the base spins for a second or so, throwing the dice out to the edge where it tumbles against a sloped incline; the friction of the base and the angle of the edge seems to do quite a good job of randomly spinning dice of various shapes.

Next, I got an Arduino (R3) and a Sainsmart single channel Relay. A relay is a switch that allows an external source of power through it when it is closed.
I soldered an additional (parallel) connection from battery to motor through the relay -- basically acting as a parallel way to complete the circuit that the existing button on the device provides.  Now you can push the button to spin the dice, OR activate the relay.

Next a tiny script(sketch) was written for the Arduino, which just loops and listens to serial (usb) connection for a simple signal telling it to spin the die for a certain amount of time.  When the signal arrives, it turns on the relay (a simple command to the pin on the Arduino that drives the relay) briefly, and then turns it off.

Next, my python dice control code uses the PySerial library to send the signal to the Arduino when it wants the dice rolled.  The script already has code that notices when the dice are moving, and waits until they settle before performing another cycle of processing, so everything proceeds automatically once they die settles.

It can perform a roll and visual processing of a die about once every 1.5 seconds.

Complications:
The only real complication I've had is that the Arduino seems to sometimes loose connection with the serial communication. So my code has to check that the Arduino confirms it has received the command, and if not, occasionally disconnect and reconnect.  This works most of the time but occasionally the Arduino just won't wake up and requires a hardware reset.  This would not be acceptable for a setup that required a high-level of uptime, but for this project it's not a show stopper.
4886
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 24, 2016, 11:27 PM »
Here's something cool.. I ran the autoclusterer function on a D20, and was unpleasantly surprised to see it was mistakenly creating two clusters of the 19 face..
Then i studied the die images closer and realized that the "18" label is worn off to make it look like a "19", and in fact the clusterer HAD successfully distinguished the two very similar looking sides:

The topmost cluster is the worn-out "18" side:
Screenshot - 2_24_2016 , 11_27_05 PM.png

You can see how it looks on the die here:
Screenshot - 2_24_2016 , 11_22_57 PM_ver001.png

Pretty cool!
4887
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 24, 2016, 08:28 PM »
After 2000+ rolls looks like we can be pretty confident that this D6 die i've been testing with has a real bias, and shouldn't be used in any tournaments*:
Screenshot - 2_24_2016 , 8_27_12 PM.png



* Technically speaking, the bias could be caused either by an unfair die or an insufficiently randomizing rolling machine.
4888
Neat!

After using raspberry pi and arduino, and with some suggestions from dc member Edvard, i finally have a better understanding myself of Raspberry Pi vs Arduino use -- at least for the kinds of projects I'm interested in.

At least in my case, the Raspberry Pi is just a small but fully capable linux pc with some input-output abilities.  Good for when you want to be able to do full normal development coding for a small standalone device.

The Arduino, for MY purposes, is much more suited as a little helper device that can be coded with small programs and is well suited for working in tandem communication with a full pc.

So for example, in my dicer project, the Raspberry Pi was a reasonable (although slow running) fully standalone computer that could do everything for the project -- run the software and drive the hardware.

But the Arduino turned out to be more useful to me, at least during development, as a helper device so that my Desktop pc could run the software at full speed, and communicate with the Arduino to do the hardware control.
4889
Screenshot Captor / Re: Pop-Up Dialog and To clipboard option
« Last post by mouser on February 24, 2016, 12:07 PM »
Hi JT.

Can you elaborate a little bit about what you are talking about?
4890
T-Clock / Re: T-Clock 2010 (download)
« Last post by mouser on February 24, 2016, 12:03 AM »
Welcome xzeldax3  :Thmbsup:

It's the perfect place for it.

I'm not one of the coder's of tclock but I can tell you that posts like yours really mean quite a bit to a coder.  Hearing that someone appreciates the work we do can make all the difference and can make us feel good about what we do.  So, thanks for taking the time to post :Thmbsup:
4891
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 23, 2016, 07:55 PM »
Just a note that after some playing with raspberry pi i decided also to experiment with Arduino, and wired up the die roller to a relay and an arduino and now have the pc talking with the arduino and automatically engaging the die roller.  :up:
I try to stay away from hardware because i get too frustrated too quickly, but i must admit it's fun to manipulate physical mechanisms through code.
4892
Screenshot Captor / Re: Arrow art
« Last post by mouser on February 23, 2016, 12:41 PM »
let me think about it; im currently a bit behind adding and fixing a few things in sc, so it's not something i'd get to anytime soon.
4893
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 06:41 PM »
Another kind of statistic you might want to look at when analyzing a die is whether there are patterns between two successive rolls (e.g. do 6's always follow 1s?).
For that we can use the same statistics as shown above when counting frequencies, but looking at a separate histogram for each die face, counting the subsequent die face frequencies.
And for pure visuals, a heatmap can help show unusually high/low frequencies of certain previous-subsequent die roll pairings:
filelabel_report_dnew_pairheatmap_histogram.png

Note: This chart has too little data to be truly informative-- it's just meant for illustrative purposes.
4894
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 05:11 PM »
So one aspect of the statistics im very wobbly on is the relation between the chisquared statistic and the confidence intervals for the histogram bars.

The chi-squared is evaluating how likely the complete set of results came from a fair die.  For a fair die, the frequency counts from all bins (die faces) should be roughly equal.

The histogram confidence intervals are evaluating each bin independently according to how likely the counts would be in that range.

Im not sure how to talk about how these statistics differ in their estimates..

The chi-squared suggests that this distribution wouldn't be surprising to see from a fair die, while the histogram confidence intervals seem to suggest that it would be..  I don't know if that means I'm calculating something wrong or misusing some statistic..
4895
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 05:04 PM »
So, this die is possibly fair?

I'm writing a little paper on this project and i will discuss the nature of these statistics a little bit.  These probabilistic things can be tricky to wrap your head around.

No matter what experiment you do, its ALWAYS going to be possible that the results came from a fair (or unfair) die.  The best you can do is say how unlikely it would be to get results like these if the die was fair.
4896
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 05:00 PM »
In the image, what exactly does 'red is 0.95 confidence int. for fair die' mean

What is means is that if you repeated this experiment over and over with a perfectly fair die, rolling this many times, you would expect the counts to fall within those red bars, 95 times you ran the experiment out of 100.
4897
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 03:14 PM »
A real report from real rolls:
Screenshot - 2_20_2016 , 3_14_56 PM.png

This die looks like 5s come up more than they should (and 1s less)..
4898
Developer's Corner / Re: Dice analyzer machine project
« Last post by mouser on February 20, 2016, 12:22 AM »
Sample graph from the program.

NOTE: This data is not real, i don't have automated roller working yet.  I hope to have automated rolling working in next 10 days.

filelabel_report_dnew_histogram.png

The red lines you see show where the data for a fair die should lie with 95% confidence.

If these were real results, this die could be confidently labeled as NOT fair.
4899
Living Room / Re: Recommend some music videos to me!
« Last post by mouser on February 19, 2016, 10:27 AM »
One of the greatest songs, Hang on Sloopy, by the McCoys:


Song was originally by the Vibrations:


And a really slow version by Little Caesar and the Consuls:
4900
DesktopCoral / Re: Hi, Why can't i drag anything to the spllited area?
« Last post by mouser on February 19, 2016, 12:32 AM »
That's weird that it works on windows 10 -- it must be something they changed about windows 10 that let's it work.  Could we have a screenshot?
Pages: prev1 ... 191 192 193 194 195 [196] 197 198 199 200 201 ... 1514next