未验证 提交 730495a7 编写于 作者: W wuzhihua 提交者: GitHub

Merge pull request #29 from yaoxuefeng6/add_lr

fix data preprocess bugs
...@@ -59,7 +59,7 @@ class TrainReader(dg.MultiSlotDataGenerator): ...@@ -59,7 +59,7 @@ class TrainReader(dg.MultiSlotDataGenerator):
self.cat_feat_idx_dict_list = [{} for _ in range(26)] self.cat_feat_idx_dict_list = [{} for _ in range(26)]
# TODO: set vocabulary dictionary # TODO: set vocabulary dictionary
vocab_dir = "./vocab/" vocab_dir = "./sample_data/vocab/"
for i in range(26): for i in range(26):
lookup_idx = 1 # remain 0 for default value lookup_idx = 1 # remain 0 for default value
for line in open( for line in open(
......
...@@ -11,7 +11,8 @@ ...@@ -11,7 +11,8 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import yaml import yaml, os
from paddlerec.core.reader import Reader from paddlerec.core.reader import Reader
from paddlerec.core.utils import envs from paddlerec.core.utils import envs
try: try:
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import yaml import yaml, os
from paddlerec.core.reader import Reader from paddlerec.core.reader import Reader
from paddlerec.core.utils import envs from paddlerec.core.utils import envs
try: try:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册