Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
GetDataFromStore
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dasharatha.vamshi
GetDataFromStore
Commits
39cab12a
Commit
39cab12a
authored
Mar 04, 2021
by
dasharatha.vamshi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
81b9130e
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
10036 deletions
+14
-10036
conf/configuration.yml
conf/configuration.yml
+1
-1
scripts/common/config_parser.py
scripts/common/config_parser.py
+13
-7
temp/mnt/ilens/ai-jobs/pipe1/run1/GetDataFromStore/param.json
.../mnt/ilens/ai-jobs/pipe1/run1/GetDataFromStore/param.json
+0
-3
temp/mnt/ilens/ai-jobs/pipe1/run1/PreprocessWeatherData/input/response.json
...jobs/pipe1/run1/PreprocessWeatherData/input/response.json
+0
-10022
temp/mnt/ilens/ai-jobs/pipe1/run_config.json
temp/mnt/ilens/ai-jobs/pipe1/run_config.json
+0
-3
No files found.
conf/configuration.yml
View file @
39cab12a
...
@@ -9,7 +9,7 @@ SERVICE_CONFIG:
...
@@ -9,7 +9,7 @@ SERVICE_CONFIG:
SYSTEM_CONFIG
:
SYSTEM_CONFIG
:
shared_mount_base_ai_job
:
/mnt/ilens/ai-jobs/
shared_mount_base_ai_job
:
/mnt/ilens/ai-jobs/
connection_string
:
DefaultEndpointsProtocol=https;AccountName=azrabsilensqa01;AccountKey=DN6q6kX98JM8yUwtuJh2bAaXUGFo1zRS5HJSsa/ZA+MlmctjC000eHP7bdXiQqkI/MVtADhS8c9E88LI5T4UHw==;EndpointSuffix=core.windows.net
connection_string
:
DefaultEndpointsProtocol=https;AccountName=azrabsilensqa01;AccountKey=DN6q6kX98JM8yUwtuJh2bAaXUGFo1zRS5HJSsa/ZA+MlmctjC000eHP7bdXiQqkI/MVtADhS8c9E88LI5T4UHw==;EndpointSuffix=core.windows.net
default_run_id
:
default_run_id
#----------------------If read conf from mongo------------#
#----------------------If read conf from mongo------------#
FOR_EACH_MONGO_CONFIG
:
FOR_EACH_MONGO_CONFIG
:
...
...
scripts/common/config_parser.py
View file @
39cab12a
...
@@ -17,10 +17,10 @@ else:
...
@@ -17,10 +17,10 @@ else:
sys
.
stderr
.
write
(
"Configuration not found..."
)
sys
.
stderr
.
write
(
"Configuration not found..."
)
sys
.
stderr
.
write
(
"Exiting...."
)
sys
.
stderr
.
write
(
"Exiting...."
)
sys
.
exit
(
1
)
sys
.
exit
(
1
)
# uncomment for Testing
# os.environ['pipeline_id'] = "pipe1"
# os.environ['pipeline_id'] = "pipe1"
# os.environ['artifact_base_path'] = "/data/model/tested/"
# os.environ['artifact_base_path'] = "/data/model/tested/"
# os.environ['artifact_name'] = 'response.json'
# ------------------------ Configurations -----------------------------------------------------------------------------
# ------------------------ Configurations -----------------------------------------------------------------------------
pipeline_id
=
os
.
environ
.
get
(
'PIPELINE_ID'
,
default
=
"pipeline_313"
)
pipeline_id
=
os
.
environ
.
get
(
'PIPELINE_ID'
,
default
=
"pipeline_313"
)
shared_mount_base_ai_job
=
os
.
environ
.
get
(
"shared_mount_base_ai_job"
,
shared_mount_base_ai_job
=
os
.
environ
.
get
(
"shared_mount_base_ai_job"
,
...
@@ -32,10 +32,11 @@ try:
...
@@ -32,10 +32,11 @@ try:
sys
.
stderr
.
write
(
"Checking for run id parameters at path "
+
run_id_path
+
"
\n
"
)
sys
.
stderr
.
write
(
"Checking for run id parameters at path "
+
run_id_path
+
"
\n
"
)
with
open
(
run_id_path
)
as
f
:
with
open
(
run_id_path
)
as
f
:
run_id_param
=
json
.
load
(
f
)
run_id_param
=
json
.
load
(
f
)
run_id
=
run_id_param
[
'run_id'
]
except
Exception
as
e
:
except
Exception
as
e
:
sys
.
stderr
.
write
(
"No run_config.json file is there so keeping run id as
pipeline_id_run
"
+
"
\n
"
)
sys
.
stderr
.
write
(
"No run_config.json file is there so keeping run id as
default_run_id
"
+
"
\n
"
)
run_id
=
pipeline_id
+
"_run"
run_id
=
_config
.
get
(
"SYSTEM_CONFIG"
,
{})
.
get
(
'default_run_id'
)
run_id
=
run_id_param
[
'run_id'
]
data_store
=
os
.
environ
.
get
(
'data_store'
,
default
=
"Azure"
)
data_store
=
os
.
environ
.
get
(
'data_store'
,
default
=
"Azure"
)
container_name
=
os
.
environ
.
get
(
'container_name'
,
default
=
GetDataFromStoreConstants
.
CONTAINER
)
container_name
=
os
.
environ
.
get
(
'container_name'
,
default
=
GetDataFromStoreConstants
.
CONTAINER
)
connection_string
=
os
.
environ
.
get
(
'connection_string'
,
_config
.
get
(
"SYSTEM_CONFIG"
,
{})
.
get
(
'connection_string'
))
connection_string
=
os
.
environ
.
get
(
'connection_string'
,
_config
.
get
(
"SYSTEM_CONFIG"
,
{})
.
get
(
'connection_string'
))
...
@@ -49,9 +50,14 @@ try:
...
@@ -49,9 +50,14 @@ try:
sys
.
stderr
.
write
(
"Checking for component parameters at path "
+
component_parameter_path
+
"
\n
"
)
sys
.
stderr
.
write
(
"Checking for component parameters at path "
+
component_parameter_path
+
"
\n
"
)
with
open
(
component_parameter_path
)
as
f
:
with
open
(
component_parameter_path
)
as
f
:
component_parameter
=
json
.
load
(
f
)
component_parameter
=
json
.
load
(
f
)
artifact_name
=
component_parameter
[
'artifact_name'
]
except
Exception
as
e
:
except
Exception
as
e
:
sys
.
stderr
.
write
(
"No param.json file so trying to take from env"
+
"
\n
"
)
try
:
artifact_name
=
os
.
environ
.
get
(
'artifact_name'
)
except
Exception
as
e
:
raise
Exception
(
e
)
raise
Exception
(
e
)
artifact_name
=
component_parameter
[
'artifact_name'
]
# $shared_mount_base_ai_job/$pipeline_id/$run_id/PreprocessWeatherData/input/$artifact_Name
# $shared_mount_base_ai_job/$pipeline_id/$run_id/PreprocessWeatherData/input/$artifact_Name
# component_output_dir = shared_mount_base_ai_job + "/" + pipeline_id + "/" + run_id + "/" + GetDataFromStoreConstants.NEXT_COMPONENT + "/input"
# component_output_dir = shared_mount_base_ai_job + "/" + pipeline_id + "/" + run_id + "/" + GetDataFromStoreConstants.NEXT_COMPONENT + "/input"
component_output_dir
=
os
.
path
.
join
(
shared_mount_base_ai_job
,
pipeline_id
,
run_id
,
component_output_dir
=
os
.
path
.
join
(
shared_mount_base_ai_job
,
pipeline_id
,
run_id
,
...
...
temp/mnt/ilens/ai-jobs/pipe1/run1/GetDataFromStore/param.json
deleted
100644 → 0
View file @
81b9130e
{
"artifact_name"
:
"response.json"
}
\ No newline at end of file
temp/mnt/ilens/ai-jobs/pipe1/run1/PreprocessWeatherData/input/response.json
deleted
100644 → 0
View file @
81b9130e
This source diff could not be displayed because it is too large. You can
view the blob
instead.
temp/mnt/ilens/ai-jobs/pipe1/run_config.json
deleted
100644 → 0
View file @
81b9130e
{
"run_id"
:
"run1"
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment