add stats

This commit is contained in:
Alicja Szulecka 2024-04-02 22:35:43 +02:00
parent 8ffd8c04bb
commit ebef6c12cc
2 changed files with 25 additions and 2 deletions

19
get_stats.py Normal file
View File

@ -0,0 +1,19 @@
import pandas as pd
meteorite_train = pd.read_csv('meteorite_train.csv')
meteorite_test = pd.read_csv('meteorite_test.csv')
meteorite_val = pd.read_csv('meteorite_val.csv')
with open('stats.txt', 'w') as f:
f.write(f"Wielkość treningowego zbioru:\n {meteorite_train.shape}\n")
f.write(f"Wielkość testowego zbioru:\n {meteorite_test.shape}\n")
f.write(f"Wielkość walidacyjnego zbioru:\n {meteorite_val.shape}\n")
f.write(f"\nZbiór Treningowy:\n")
f.write(f"{meteorite_train.describe()}\n")
f.write(f"\nZbiór Testowy:\n")
f.write(f"{meteorite_test.describe()}\n")
f.write(f"\nZbiór walidacyjny:\n")
f.write(f"{meteorite_val.describe()}\n")

8
stats/Jenkinsfile vendored
View File

@ -1,5 +1,9 @@
pipeline { pipeline {
agent any agent {
docker {
image 'aliszu1/ium:1.0'
}
}
parameters { parameters {
buildSelector ( buildSelector (
defaultSelector: lastSuccessful(), defaultSelector: lastSuccessful(),
@ -15,7 +19,7 @@ pipeline {
} }
stage('Build') { stage('Build') {
steps { steps {
sh "bash ./stats/stats_dataset.sh" sh "python ./get_stats.py"
archiveArtifacts artifacts: 'artifacts/*', onlyIfSuccessful: true archiveArtifacts artifacts: 'artifacts/*', onlyIfSuccessful: true
} }
} }