Moving analysis from frc971 to aos, cleanup

bazel run -c opt //aos/analysis:in_process_plotter_demo
now works.

Signed-off-by: Stephan Pleines <pleines.stephan@gmail.com>
Change-Id: Icbe7255ea3988b8fe575253f99b30310a6720bd8
diff --git a/aos/analysis/in_process_plotter.cc b/aos/analysis/in_process_plotter.cc
index a2ed68c..88591b3 100644
--- a/aos/analysis/in_process_plotter.cc
+++ b/aos/analysis/in_process_plotter.cc
@@ -2,11 +2,11 @@
 
 #include "aos/configuration.h"
 
-namespace frc971::analysis {
+namespace aos::analysis {
 
 namespace {
-const char *kDataPath = "frc971/analysis/cpp_plot";
-const char *kConfigPath = "frc971/analysis/plotter.json";
+const char *kDataPath = "aos/analysis/cpp_plot";
+const char *kConfigPath = "aos/analysis/plotter.json";
 }  // namespace
 
 Plotter::Plotter()
@@ -167,4 +167,4 @@
   next_top_ = 0;
 }
 
-}  // namespace frc971::analysis
+}  // namespace aos::analysis
diff --git a/aos/analysis/in_process_plotter.h b/aos/analysis/in_process_plotter.h
index fdfde8c..0d00deb 100644
--- a/aos/analysis/in_process_plotter.h
+++ b/aos/analysis/in_process_plotter.h
@@ -1,5 +1,5 @@
-#ifndef FRC971_ANALYSIS_IN_PROCESS_PLOTTER_H_
-#define FRC971_ANALYSIS_IN_PROCESS_PLOTTER_H_
+#ifndef AOS_ANALYSIS_IN_PROCESS_PLOTTER_H_
+#define AOS_ANALYSIS_IN_PROCESS_PLOTTER_H_
 
 #include <vector>
 
@@ -7,7 +7,7 @@
 #include "aos/events/simulated_event_loop.h"
 #include "aos/network/web_proxy.h"
 
-namespace frc971::analysis {
+namespace aos::analysis {
 
 // This class wraps the WebProxy class to provide a convenient C++ interface to
 // dynamically generate plots.
@@ -95,5 +95,5 @@
   std::vector<ColorWheelColor> color_wheel_;
 };
 
-}  // namespace frc971::analysis
-#endif  // FRC971_ANALYSIS_IN_PROCESS_PLOTTER_H_
+}  // namespace aos::analysis
+#endif  // AOS_ANALYSIS_IN_PROCESS_PLOTTER_H_
diff --git a/aos/analysis/in_process_plotter_demo.cc b/aos/analysis/in_process_plotter_demo.cc
index a02451a..6141d6a 100644
--- a/aos/analysis/in_process_plotter_demo.cc
+++ b/aos/analysis/in_process_plotter_demo.cc
@@ -8,7 +8,7 @@
 // each plot.
 int main(int argc, char *argv[]) {
   aos::InitGoogle(&argc, &argv);
-  frc971::analysis::Plotter plotter;
+  aos::analysis::Plotter plotter;
   plotter.Title("TITLE!");
   plotter.AddFigure("Fig Foo");
   plotter.ShareXAxis(true);
diff --git a/aos/analysis/plot_data.fbs b/aos/analysis/plot_data.fbs
index 641cd6e..20689c5 100644
--- a/aos/analysis/plot_data.fbs
+++ b/aos/analysis/plot_data.fbs
@@ -3,7 +3,7 @@
 // the data to plot is all packaged within a single Plot message. Each Plot
 // message will correspond to a single view/tab on the web-page, and can have
 // multiple figures, each of which can have multiple lines.
-namespace frc971.analysis;
+namespace aos.analysis;
 
 // Position within the web-page to plot a figure at. [0, 0] will be the upper
 // left corner of the allowable places where plots can be put, and should
diff --git a/aos/analysis/plot_data_utils.ts b/aos/analysis/plot_data_utils.ts
index 25131fb..0153cdb 100644
--- a/aos/analysis/plot_data_utils.ts
+++ b/aos/analysis/plot_data_utils.ts
@@ -1,5 +1,5 @@
 // Provides a plot which handles plotting the plot defined by a
-// frc971.analysis.Plot message.
+// aos.analysis.Plot message.
 import {Plot as PlotFb} from './plot_data_generated';
 import {MessageHandler, TimestampedMessage} from '../../aos/network/www/aos_plotter';
 import {ByteBuffer} from 'flatbuffers';
@@ -28,7 +28,7 @@
   parentDiv.appendChild(plotDiv);
 
   conn.addReliableHandler(
-      '/analysis', 'frc971.analysis.Plot', (data: Uint8Array, time: number) => {
+      '/analysis', 'aos.analysis.Plot', (data: Uint8Array, time: number) => {
         const plotFb = PlotFb.getRootAsPlot(new ByteBuffer(data));
         const name = (!plotFb.title()) ? 'Plot ' + plots.size : plotFb.title();
         const div = document.createElement('div');
diff --git a/aos/analysis/plotter_config.json b/aos/analysis/plotter_config.json
index fef4a50..2ebde74 100644
--- a/aos/analysis/plotter_config.json
+++ b/aos/analysis/plotter_config.json
@@ -2,7 +2,7 @@
   "channels": [
     {
       "name": "/analysis",
-      "type": "frc971.analysis.Plot",
+      "type": "aos.analysis.Plot",
       "max_size": 1000000000
     }
   ],
diff --git a/aos/analysis/py_log_reader.cc b/aos/analysis/py_log_reader.cc
index 57d57d0..4a97a0f 100644
--- a/aos/analysis/py_log_reader.cc
+++ b/aos/analysis/py_log_reader.cc
@@ -27,7 +27,7 @@
 #include "aos/init.h"
 #include "aos/json_to_flatbuffer.h"
 
-namespace frc971::analysis {
+namespace aos::analysis {
 namespace {
 
 // All the data corresponding to a single message.
@@ -299,8 +299,8 @@
 }
 
 }  // namespace
-}  // namespace frc971::analysis
+}  // namespace aos::analysis
 
 PyMODINIT_FUNC PyInit_py_log_reader(void) {
-  return frc971::analysis::InitModule();
+  return aos::analysis::InitModule();
 }