Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
wangsen
MinerU
Commits
aedaeb00
"server/text_generation_server/models/gpt_neox.py" did not exist on "f830706b215a94e1cdedeb89766b2822d8ceac24"
Commit
aedaeb00
authored
Apr 08, 2024
by
赵小蒙
Browse files
一些变量命名更新
parent
7e59b4b6
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
9 deletions
+9
-9
magic_pdf/libs/config_reader.py
magic_pdf/libs/config_reader.py
+6
-6
magic_pdf/spark/config_init_to_json.py
magic_pdf/spark/config_init_to_json.py
+3
-3
No files found.
magic_pdf/libs/config_reader.py
View file @
aedaeb00
...
...
@@ -30,16 +30,16 @@ def get_s3_config(bucket_name: str):
if
bucket_name
not
in
config
:
raise
Exception
(
"bucket_name not found in magic_pdf_config.json"
)
a
k
=
config
[
bucket_name
].
get
(
"ak"
)
s
k
=
config
[
bucket_name
].
get
(
"sk"
)
endpoint
=
config
[
bucket_name
].
get
(
"endpoint"
)
a
ccess_key
=
config
[
bucket_name
].
get
(
"ak"
)
s
ecret_key
=
config
[
bucket_name
].
get
(
"sk"
)
storage_
endpoint
=
config
[
bucket_name
].
get
(
"endpoint"
)
if
a
k
is
None
or
s
k
is
None
or
endpoint
is
None
:
if
a
ccess_key
is
None
or
s
ecret_key
is
None
or
storage_
endpoint
is
None
:
raise
Exception
(
"ak, sk or endpoint not found in magic_pdf_config.json"
)
# logger.info(f"get_s3_config: ak={a
k}, sk={sk
}, endpoint={endpoint}")
# logger.info(f"get_s3_config: ak={a
ccess_key}, sk={secret_key
}, endpoint={
storage_
endpoint}")
return
a
k
,
sk
,
endpoint
return
a
ccess_key
,
secret_key
,
storage_
endpoint
if
__name__
==
'__main__'
:
...
...
magic_pdf/spark/config_init_to_json.py
View file @
aedaeb00
...
...
@@ -52,6 +52,6 @@ def write_json_to_home(my_dict):
if
__name__
==
'__main__'
:
bucket_configs
=
get_bucket_configs_dict
(
s3_buckets
,
s3_clusters
,
s3_users
)
logger
.
info
(
bucket_configs
)
write_json_to_home
(
bucket_configs
)
bucket_configs
_dict
=
get_bucket_configs_dict
(
s3_buckets
,
s3_clusters
,
s3_users
)
logger
.
info
(
bucket_configs
_dict
)
write_json_to_home
(
bucket_configs
_dict
)
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