Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Announcements (http://www.chiefdelphi.com/forums/forumdisplay.php?f=59)
-   -   FRC-Spy (http://www.chiefdelphi.com/forums/showthread.php?t=75222)

Brandon Martus 25-02-2009 13:10

FRC-Spy
 
Similar to how CD-Spy shows a running list of forum activity .. FRC-Spy makes use of FIRST's new twitter feed and shows match results as they happen. Right now it lists all events .. by next week, I'll work in some event filtering. There are also some XML feeds (info at the bottom of FRC-Spy), if you want to use the data in your own application. A link to FRC-Spy is up top next to CD-Spy.

Let me know if you have any suggestions on how to improve this any.

Killraine 25-02-2009 13:17

Re: FRC-Spy
 
Looks good, Can't wait to see all of this in action!

R.C. 25-02-2009 13:22

Re: FRC-Spy
 
Interesting, looks very promising.

Tom Bottiglieri 25-02-2009 13:45

Re: FRC-Spy
 
Would it be possible to add a penalty column?

Brandon Martus 25-02-2009 13:53

Re: FRC-Spy
 
Quote:

Originally Posted by Tom Bottiglieri (Post 827838)
Would it be possible to add a penalty column?

Done (I think .. someone check my math, assuming the test data is valid)

JesseK 25-02-2009 13:54

Re: FRC-Spy
 
Looks good Brandon. You may well have just provided a way to automate Fantasy First :p

vhcook 25-02-2009 13:56

Re: FRC-Spy
 
Column headers for the blue moon rocks are a bit askew (E is over S rather than next to it). Windows XP, 1280x1024 (both fullscreen and smaller window sizes), IE 6.0

Other than that really minor quibble, this is wonderful.

Tom Line 25-02-2009 13:57

Re: FRC-Spy
 
I am not fluent in XML.

Would it be possible to simply make a text file (tab delimited or otherwise) that we can download to get all the current scores? Since most of us will be playing with the data in excel anyway, it would make a very convenient way to grab the data for us non-fluent-web folks.

An extra bonus would be to have ALL the scores up to the current time, including all the weeks, available in the text file or in different text files.

Again, I don't know how hard that is.

Brandon Martus 25-02-2009 14:00

Re: FRC-Spy
 
Quote:

Originally Posted by vhcook (Post 827845)
Column headers for the blue moon rocks are a bit askew (E is over S rather than next to it.

Other than that really minor quibble, this is wonderful.

What browser, resolution, and OS?

Tom Line 25-02-2009 14:05

Re: FRC-Spy
 
Perhaps I'm going to get a quick tutorial. I downloaded MS's XML viewer - but when I try to get to the xml, I get this error:

The XML page cannot be displayed
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.


--------------------------------------------------------------------------------

Only one top level element is allowed in an XML document. Error processing resource 'http://www.chiefdelphi.com/forums/frcs...

<match>
-^

FYI - columns look just fine in IE6.

Elgin Clock 25-02-2009 14:19

Re: FRC-Spy
 
Quote:

Originally Posted by vhcook (Post 827845)
Column headers for the blue moon rocks are a bit askew (E is over S rather than next to it). Windows XP, 1280x1024 (both fullscreen and smaller window sizes), IE 6.0
Other than that really minor quibble, this is wonderful.

Quote:

Originally Posted by Brandon Martus (Post 827847)
What browser, resolution, and OS?

Same issue here.

Windows XP Pro, IE 6.0.2900.2180_______, 1280x960 resolution with CD spread the whole width of my monitor.

artdutra04 25-02-2009 14:36

Re: FRC-Spy
 
I not sure if this is a browser issue or if this was a change to the formatting, but earlier today (when using Firefox), the losing alliance was a faded color. Now when checking again (using IE7), the losing alliance is not faded with the winning alliance outlined in a black line.

Maybe it's personal perference, but I prefer the faded colors of the losing alliance to the box around the winning alliance; it's easier to glance at the list to see which alliance won.

Brandon Martus 25-02-2009 14:39

Re: FRC-Spy
 
Quote:

Originally Posted by artdutra04 (Post 827862)
I not sure if this is a browser issue or if this was a change to the formatting, but earlier today (when using Firefox), the losing alliance was a faded color. Now when checking again (using IE7), the losing alliance is not faded with the winning alliance outlined in a black line.

Maybe it's personal perference, but I prefer the faded colors of the losing alliance to the box around the winning alliance; it's easier to glance at the list to see which alliance won.

Both the fade and outline are still there (fade is in Firefox only, at the moment). I've got to fix it to be compliant and work in non-FF.

Zach O 25-02-2009 14:47

Re: FRC-Spy
 
This will update automatically by the F.I.R.S.T. twitter? That's so cool :D

Tom Line 25-02-2009 14:54

Re: FRC-Spy
 
Ok. The XML is opening now rather than giving me an error. Perhaps I was was just too quick and the site hadn't updated yet.

When we download the XML, will it contain every match played so far, or just the last 50?

Brandon Martus 25-02-2009 14:59

Re: FRC-Spy
 
Quote:

Originally Posted by Tom Line (Post 827873)
Ok. The XML is opening now rather than giving me an error. Perhaps I was was just too quick and the site hadn't updated yet.

When we download the XML, will it contain every match played so far, or just the last 50?


http://www.chiefdelphi.com/forums/frcspy.php?xml=2 will give you everything

change the integer at the end to get the # you need. (must be > 2, for now)

http://www.chiefdelphi.com/forums/frcspy.php?xml=5 will give you the last 5

http://www.chiefdelphi.com/forums/frcspy.php?xml=25 will give you the last 25

etc.


Right now, this data will be approx. 30 seconds behind the twitter feed.

Greg Marra 25-02-2009 15:48

Re: FRC-Spy
 
Brandon,

Does it make sense to release this code so other people can look at it and offer suggestions?

Uberbots 25-02-2009 16:08

Re: FRC-Spy
 
im thinking TBA should link off of some of this data to get the real time score updates, too (: (though im pretty sure im not the first to think of this)

maybe even some charts of moonrocks/minute, total penalties, g14 infractions, etc

Brandon Martus 25-02-2009 16:23

Re: FRC-Spy
 
Quote:

Originally Posted by Greg Marra (Post 827889)
Brandon,

Does it make sense to release this code so other people can look at it and offer suggestions?

It's pretty ugly (did it real quick yesterday) .. I may release some of it, eventually.

Pulling the data from twitter is just using magpierss to grab the twitter rss feed for the account (http://twitter.com/statuses/user_timeline/20603824.rss) which seems to update as fast as any API call (based on my 1 quick 'test' .. that may need to be fixed if it gets too far behind). Once I grab the rss, I do a very crude parsing of the string and 'replace into' a database (keyed off an md5() of the 'pubDate' in the rss).

The front end just displays the last 50 rows .. and has an Ajax.PeriodicalUpdater w/decay that cycles that data to the user way more than it needs to. When I get free time, I'll work on a better way to only send down new data every request .. not all data.

Zach O 25-02-2009 16:56

Re: FRC-Spy
 
Can you please explain what colum means what? Also, is the moon rock score by just robot or robots and humans?

Edit: Also, how reliable is the data?

Vikesrock 25-02-2009 17:06

Re: FRC-Spy
 
Quote:

Originally Posted by Zach O (Post 827921)
Can you please explain what colum means what? Also, is the moon rock score by just robot or robots and humans?

Edit: Also, how reliable is the data?

Not sure what you mean by "colum"

The moon rocks columns show the number of moonrocks score by the alliance (humans + robots) under E and the number of Supercells scored under S.

The data is pulled off of a Twitter feed that is updated by the official scoring software so it should be accurate.

Zach O 25-02-2009 17:09

Re: FRC-Spy
 
Quote:

Originally Posted by Vikesrock (Post 827929)
Not sure what you mean by "colum"

The moon rocks columns show the number of moonrocks score by the alliance (humans + robots) under E and the number of Supercells scored under S.

The data is pulled off of a Twitter feed that is updated by the official scoring software so it should be accurate.

Sounds good. Thank you for the answer :)

ehochstein 25-02-2009 17:12

Re: FRC-Spy
 
Did you ever think of making the blue a little darker? It's kind of hard to see on some computers and hurts my eyes >.<

Just a suggestion, It looks great!!! :)

Doug Leppard 25-02-2009 17:20

Re: FRC-Spy
 
Look forward to using this.

ATannahill 25-02-2009 19:29

Re: FRC-Spy
 
I know it is a test, but why isn't there an E-18 or E-9?

Vikesrock 25-02-2009 20:03

Re: FRC-Spy
 
Quote:

Originally Posted by rtfgnow (Post 827984)
I know it is a test, but why isn't there an E-18 or E-9?

There is also no E-12

The "missing" matches are matches that are skipped because one alliance won the first two matches of the set.

Greg Marra 25-02-2009 22:18

Re: FRC-Spy
 
Quote:

Originally Posted by Uberbots (Post 827901)
im thinking TBA should link off of some of this data to get the real time score updates, too (: (though im pretty sure im not the first to think of this)

maybe even some charts of moonrocks/minute, total penalties, g14 infractions, etc

We scrape the official USFIRST score pages in real-time, so parsing the Twitter data would be just another way of getting at information we already know.

Also, I am not sure how to map "Elimination 20" to "Semifinal 1 Match 2". The Twitter data seems to use sequential numbers for Elims, which doesn't work as well as the Qual numbers do.

karlcswanson 25-02-2009 22:25

Re: FRC-Spy
 
I made an xsl stylesheet for the xml file, it displays the data from frc.xml pretty fast. It doesn't look that great, but it shows up on the ipod touch well. It loads faster than frc-spy. I really haven't done that much web/xml development, so I am sure there are many mistakes, but it works. Once event filtering is in, it should automatically apply to what is displayed using this stylesheet.

to use, make this the second line of frc.xml
Code:

<?xml-stylesheet href="format.xsl" type="text/xsl"?>
and save this to format.xsl
Code:

<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<html>
<head>
<title>FRC Scores</title>
<meta name="viewport" content="width=480; initial-scale=0.6666; maximum-scale=1.0; minimum-scale=0.6666" />
</head>
<body>
<table border="0">
<tr bgcolor="#9acd32">
<th>Event</th>
<th>Match</th>
<th bgcolor="red">Red Alliance</th>
<th bgcolor="blue">Blue Alliance</th>
<th bgcolor="red">Red Score</th>
<th bgcolor="blue">Blue Score</th>
</tr>
<xsl:for-each select="matches/match">
<tr>
<td><xsl:value-of select="event"/></td>
<td><xsl:value-of select="typ"/> - <xsl:value-of select="mch"/></td>
<td bgcolor="#ff9999"><xsl:value-of select="red1"/>-<xsl:value-of select="red2"/>-<xsl:value-of select="red3"/></td>
<td bgcolor="#9999ff"><xsl:value-of select="blue1"/>-<xsl:value-of select="blue2"/>-<xsl:value-of select="blue3"/></td>
<xsl:if test="number(bfin)>number(rfin)">
<td bgcolor="#ff9999"><xsl:value-of select="rfin"/></td>
<td bgcolor="blue"><xsl:value-of select="bfin"/></td>
</xsl:if>

<xsl:if test="number(rfin)>number(bfin)">
<td bgcolor="red"><xsl:value-of select="rfin"/></td>
<td bgcolor="#9999ff"><xsl:value-of select="bfin"/></td>
</xsl:if>

<xsl:if test="number(rfin)=number(bfin)">
<td bgcolor="red"><xsl:value-of select="rfin"/></td>
<td bgcolor="blue"><xsl:value-of select="bfin"/></td>
</xsl:if>

</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>


ZInventor 26-02-2009 03:03

Re: FRC-Spy
 
I know it's a stretch, but do you think you could get team filtering as well, since it'd be nice to be able to just see your matches.

-Z

Alex Dinsmoor 27-02-2009 12:24

Re: FRC-Spy
 
For some reason the Traverse City District Competition isn't being represented in FRC-spy. We have had about 25 minutes of events so far, but none of the results have been posted.

It may have something with TBA not updating the TCDC match listings though...

Q. Sheets 27-02-2009 15:48

Re: FRC-Spy
 
Quote:

Originally Posted by Alex Dinsmoor (Post 828505)
For some reason the Traverse City District Competition isn't being represented in FRC-spy. We have had about 25 minutes of events so far, but none of the results have been posted.

It may have something with TBA not updating the TCDC match listings though...

No, I don't think it has anything to do with TBA. The Twitter feed hasn't been reporting them either for some reason

Greg Marra 27-02-2009 15:59

Re: FRC-Spy
 
Quote:

Originally Posted by Q. Sheets (Post 828564)
No, I don't think it has anything to do with TBA. The Twitter feed hasn't been reporting them either for some reason

Sounds like there's no network connection at the event.

Alex Dinsmoor 27-02-2009 16:07

Re: FRC-Spy
 
Quote:

Originally Posted by Q. Sheets (Post 828564)
No, I don't think it has anything to do with TBA. The Twitter feed hasn't been reporting them either for some reason

I have seen some Traverse scores on the twitter, so it's reporting a few of them. And there may not be any network connection, but I'm not positive.

Q. Sheets 27-02-2009 16:36

Re: FRC-Spy
 
But http://www2.usfirst.org/2009comp/eve...chresults.html is completely updated

ATannahill 28-02-2009 10:45

Re: FRC-Spy
 
Brandon, I notice for ties, one alliance is still lit up more than the other, shouldn't they both be lit up?

Kyler 01-03-2009 00:34

Re: FRC-Spy
 
Brandon, I am unsure of why this is wrong but for me the score for the last midwest final is showing up as

Quote:

Midwest
E - 20
0:00 (C)
2338
2039
135
1675
1625
111

64
74

32
0

37
0

0
0
that 74 should be an 82 according to both TBA and myself who is from 1625. Unsure why its off but thought you should know.

EDIT: It is the twitter's fault now that I checked. But thats strange it would be off.

Elgin Clock 02-03-2009 03:17

Re: FRC-Spy
 
Quote:

Originally Posted by rtfgnow (Post 828841)
Brandon, I notice for ties, one alliance is still lit up more than the other, shouldn't they both be lit up?

In the test match that just got sent last night (Sunday) through Twitter to the feed, both are lit up with end scores of 0-0 on each alliance.
Looks like it's fixed!

Brandon Martus 02-03-2009 12:41

Re: FRC-Spy
 
Quote:

Originally Posted by Elgin Clock (Post 830091)
In the test match that just got sent last night (Sunday) through Twitter to the feed, both are lit up with end scores of 0-0 on each alliance.
Looks like it's fixed!

I didn't do anything ...... so maybe a tie with scores > 0 comes up weird. I'll look at the code.

Edit: I found an issue .. they both should be faded when there is a tie now.

Brandon Martus 03-03-2009 02:06

Re: FRC-Spy
 
Team and Event filtering is now available on FRC-Spy. Check it out, let me know of any weird quirks or additional features you need .. I've only tested this in Firefox on a Mac.

Aaaand, I should get some sleep.

Bongle 06-03-2009 10:38

Re: FRC-Spy
 
Quote:

Originally Posted by Brandon Martus (Post 830853)
Team and Event filtering is now available on FRC-Spy. Check it out, let me know of any weird quirks or additional features you need .. I've only tested this in Firefox on a Mac.

Aaaand, I should get some sleep.

This is great.

Two feature requests:
1) Highlighting of filtered teams. It is hard to pick out at a glance the teams I chose to filter. If they were bigger, bolder, a different colour, or something like that, that'd be great.
2) A mini-mode. This way, I could open a browser window, point it at FRC-spy, and have it only take up a little screen real estate. If I shrink the text with ctrl+scroll-wheel, the table stays about the same size.

Brandon Martus 06-03-2009 13:47

Re: FRC-Spy
 
Quote:

Originally Posted by Bongle (Post 832481)
This is great.

Two feature requests:
1) Highlighting of filtered teams. It is hard to pick out at a glance the teams I chose to filter. If they were bigger, bolder, a different colour, or something like that, that'd be great.
2) A mini-mode. This way, I could open a browser window, point it at FRC-spy, and have it only take up a little screen real estate. If I shrink the text with ctrl+scroll-wheel, the table stays about the same size.

Both good suggestions .. I'll see what I can do.

karlcswanson 06-03-2009 13:59

Re: FRC-Spy
 
Quote:

Originally Posted by Brandon Martus (Post 832534)
Both good suggestions .. I'll see what I can do.

As far as a mini-mode, for midwest i used a variant of that xml stylesheet I posted earlier and used google apps engine just to add the line of xml to read it. It works find on an iphone (which uses webkit), but I am not sure how widespread xml stylesheets are supported in other mobile browsers.

Q. Sheets 06-03-2009 19:52

Re: FRC-Spy
 
It looks like no Michigan events are being reported... Kettering is not being published on Twitter :eek:

But, like Traverse City, it does have a connection as its results page is being published in real-time.

JesseK 23-03-2009 14:16

Re: FRC-Spy
 
Brandon -- I'd just like to verify something ...

http://www.chiefdelphi.com/forums/frcspy.php?xml=2

This link has ALL regional data from this year that's available via the Twitter feed?

Brandon Martus 31-03-2009 23:05

Re: FRC-Spy
 
Quote:

Originally Posted by JesseK (Post 839918)
Brandon -- I'd just like to verify something ...

http://www.chiefdelphi.com/forums/frcspy.php?xml=2

This link has ALL regional data from this year that's available via the Twitter feed?

That is correct. Sorry for the way-late response.

Brandon Martus 03-03-2011 09:01

Re: FRC-Spy
 
FRC Spy has been updated for this season's game (correct me if I missed anything).

I have to fix the filters and put the regionals in their correct week -- but Week 1 should be good.

Brandon Martus 03-03-2011 16:38

Re: FRC-Spy
 
The weeks on the filters for this year should be up to date now.

Joe Ross 28-02-2013 15:24

Re: FRC-Spy
 
Will FRC-Spy be updated for this year?

Brandon Martus 28-02-2013 16:18

Re: FRC-Spy
 
Just got all this year's data in .. should be good now.

Joe Ross 28-02-2013 18:26

Re: FRC-Spy
 
thanks


All times are GMT -5. The time now is 08:45.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi