ccm commited on
Commit
dc5ba7f
·
1 Parent(s): 4c6aa05

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -8
app.py CHANGED
@@ -17,25 +17,26 @@ def load_data():
17
 
18
  from datasets import load_dataset
19
 
 
 
 
 
 
20
 
21
  data = load_dataset("cmudrc/wave-energy", data_files=["data.zip"], split='train')
22
- curvey_curves = [numpy.array(x)/1000000 for x in data['curves']]
23
  # round_geometry = [numpy.array(x) for x in data['geometry']]
24
  # round_geometry = numpy.array(data['geometry'])
 
25
  round_geometry = None
26
- geometry = numpy.reshape(data['geometry'], (5000, 32*32*32))
27
- curves = numpy.reshape(data['curves'], (5000, 3*64))/1000000
28
  # curves = load_dataset("cmudrc/wave-energy", data_files="curves.zip", split='train').to_pandas().drop(labels="index", axis=1)
29
  # geometry = load_dataset("cmudrc/wave-energy", data_files="geometry.zip", split='train').to_pandas().drop(labels="index", axis=1)
30
 
31
  # Open all the files we downloaded at the beginning and take out hte good bits
32
  # curves = data.iloc[:, [i for i in range(1, 3*64+1)]]
33
  # geometry = data.iloc[:, [i for i in range(1 + 3*64, 1 + 3*64 + 32**3)]]
34
- S = 5
35
- N = 1000
36
- D = 3
37
- F = 64
38
- G = 32
39
 
40
  # flattened_curves = curves.values / 1000000
41
  # curvey_curves = [c.reshape([D, F])/1000000 for c in curves.values]
 
17
 
18
  from datasets import load_dataset
19
 
20
+ S = 5
21
+ N = 1000
22
+ D = 3
23
+ F = 64
24
+ G = 32
25
 
26
  data = load_dataset("cmudrc/wave-energy", data_files=["data.zip"], split='train')
27
+ # curvey_curves = [numpy.array(x)/1000000 for x in data['curves']]
28
  # round_geometry = [numpy.array(x) for x in data['geometry']]
29
  # round_geometry = numpy.array(data['geometry'])
30
+ curvey_curves = None
31
  round_geometry = None
32
+ geometry = numpy.reshape(data['geometry'], (S*N, G*G*G))
33
+ curves = numpy.reshape(data['curves'], (S*N, D*F))/1000000
34
  # curves = load_dataset("cmudrc/wave-energy", data_files="curves.zip", split='train').to_pandas().drop(labels="index", axis=1)
35
  # geometry = load_dataset("cmudrc/wave-energy", data_files="geometry.zip", split='train').to_pandas().drop(labels="index", axis=1)
36
 
37
  # Open all the files we downloaded at the beginning and take out hte good bits
38
  # curves = data.iloc[:, [i for i in range(1, 3*64+1)]]
39
  # geometry = data.iloc[:, [i for i in range(1 + 3*64, 1 + 3*64 + 32**3)]]
 
 
 
 
 
40
 
41
  # flattened_curves = curves.values / 1000000
42
  # curvey_curves = [c.reshape([D, F])/1000000 for c in curves.values]